Click here to Skip to main content
15,899,825 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Windows Message Queue Pin
Jim Taylor13-May-03 22:47
Jim Taylor13-May-03 22:47 
GeneralI am lost Pin
Anonymous10-May-03 18:23
Anonymous10-May-03 18:23 
GeneralRe: I am lost Pin
Nick Parker11-May-03 3:12
protectorNick Parker11-May-03 3:12 
GeneralRe: I am lost Pin
John Kuhn14-May-03 8:06
John Kuhn14-May-03 8:06 
GeneralVBA and Business Objects Pin
nicholas.gionfriddo9-May-03 4:41
nicholas.gionfriddo9-May-03 4:41 
GeneralHorizontal bar disappearance and text being wrapped in html/codeview Pin
artikworld8-May-03 23:41
artikworld8-May-03 23:41 
GeneralCalling API function from VB Pin
Miszou8-May-03 11:05
Miszou8-May-03 11:05 
GeneralRe: Calling API function from VB Pin
J. Dunlap8-May-03 11:23
J. Dunlap8-May-03 11:23 
What do you mean by "it doesn't work"? What happens?

Also, you are declaring nUserLen as Long and the variable nSize as Integer. They should both be the same type as each other (either type is fine, but you don't really need it to be as big as a Long).

You might consider making the buffer be bigger than 32 characters, because if the UserName happens to be longer than this (but it generally isn't) the function will fail.

When you are done calling this function you should do:
strUserName=Left(strUserName, nUserLen)

This will cut off the unnecessary bytes.


"Do unto others as you would have them do unto you." - Jesus

"An eye for an eye only makes the whole world blind." - Mahatma Gandhi







GeneralRe: Calling API function from VB Pin
Miszou8-May-03 11:58
Miszou8-May-03 11:58 
GeneralI think I've got it! Pin
J. Dunlap8-May-03 13:37
J. Dunlap8-May-03 13:37 
GeneralRe: I think I've got it! Pin
Miszou9-May-03 5:22
Miszou9-May-03 5:22 
GeneralUser Authentication Pin
GrindAZ8-May-03 8:28
GrindAZ8-May-03 8:28 
GeneralRe: User Authentication Pin
Nick Parker10-May-03 11:41
protectorNick Parker10-May-03 11:41 
GeneralRe: User Authentication Pin
GrindAZ12-May-03 5:28
GrindAZ12-May-03 5:28 
GeneralRe: User Authentication Pin
Ray Cassick12-May-03 5:57
Ray Cassick12-May-03 5:57 
GeneralRe: User Authentication Pin
GrindAZ12-May-03 7:17
GrindAZ12-May-03 7:17 
Generallist boxes Pin
lister7-May-03 13:03
lister7-May-03 13:03 
GeneralRe: list boxes Pin
ScaleOvenStove7-May-03 16:38
ScaleOvenStove7-May-03 16:38 
GeneralRe: list boxes Pin
lister7-May-03 23:35
lister7-May-03 23:35 
Generalbit array (BSTR) Pin
Pombo7-May-03 12:21
Pombo7-May-03 12:21 
GeneralRe: bit array (BSTR) Pin
Dave Kreskowiak8-May-03 6:17
mveDave Kreskowiak8-May-03 6:17 
GeneralRe: bit array (BSTR) Pin
Anonymous8-May-03 8:25
Anonymous8-May-03 8:25 
GeneralRe: bit array (BSTR) Pin
Dave Kreskowiak12-May-03 7:00
mveDave Kreskowiak12-May-03 7:00 
GeneralRe: bit array (BSTR) Pin
Nick Parker12-May-03 17:32
protectorNick Parker12-May-03 17:32 
GeneralOpening a form - easy question Pin
nboothe7-May-03 9:02
nboothe7-May-03 9:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.