home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / os / mswindo / programm / tools / 754 < prev    next >
Encoding:
Text File  |  1992-08-21  |  1.2 KB  |  32 lines

  1. Newsgroups: comp.os.ms-windows.programmer.tools
  2. Path: sparky!uunet!microsoft!hexnut!joero
  3. From: joero@microsoft.com (Joe Robison)
  4. Subject: Re: unsigned long for VBASIC
  5. Message-ID: <1992Aug22.004022.11241@microsoft.com>
  6. Date: 22 Aug 92 00:40:22 GMT
  7. Organization: Microsoft Corp.
  8. References: <9208202215.AA06261@top.magnus.acs.ohio-state.edu> 
  9. Lines: 21
  10.  
  11. In article <9208202215.AA06261@top.magnus.acs.ohio-state.edu> John wrote:
  12. > How can one handle the problem of not having an the "unsigned integer"
  13. > type in visual basic?  I am calling a functions in a DLL which returns
  14. > a unsigned long value.  I need to store this value in a structure and
  15. > pass the structure as a parameter in another DLL function call.
  16. > my failure to this is because Visual Basic doesn't support the unsigned
  17. > type.  Is there a way around this problem?
  18.  
  19. Just use a Long.  Yes, it's signed, but 32 bits is 32 bits.  If the high
  20. bit is set, then it will look negative in VB, but that doesn't change
  21. the bit pattern (unless you perform math on it).  It's just a matter of
  22. interpretation.  You can pass it on to another function that expects an
  23. unsigned long and it should work fine.
  24.  
  25. Hope this helps.
  26.  
  27. Joe Robison
  28. joero@microsoft.com
  29. NAMS (Not A Microsoft Spokeshuman)
  30.