Results 1 to 3 of 3

Thread: Access (or Excel) VBA StrPtr Type mismatch (64bit)

  1. #1

    Thread Starter
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Access (or Excel) VBA StrPtr Type mismatch (64bit)

    basically this is my issue:
    http://support.microsoft.com/kb/9832...rss&spid=14019

    i have an FTP class module that works fine in 32 bit machines... but not in 64 bit Office/Win7


    Code:
    Private Function StripZ(ByVal s As String) As String
    'Return all of s before the zero-terminator (if any).
        StripZ = Left$(s, lstrlen(StrPtr(s)))
    End Function
    highlights StrPtr and says type mismatch.

    I tried the hotfix (from another location since its gone from MS) and it said it doesnt apply to my machine.. I have SP1 installed.

    I tired to look at the StrPtr Definition and it says its hidden? (in the object browser)


    What is StrPtr and how do i replace/fix it!
    HELP!

    Thanks
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

  2. #2

    Thread Starter
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Re: Access (or Excel) VBA StrPtr Type mismatch (64bit)

    well i fixed it with a few clng s lol

    but now access crashes trying to open the 240mb csv lol great..... i need to download / open / check the row count on 100 files 200mb or larger

    this should be fun
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

  3. #3
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    9,017

    Re: Access (or Excel) VBA StrPtr Type mismatch (64bit)

    Bear in mind that all pointers are 64 bits wide in any 64 bit version of Windows.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width