Wrox Home  
Search P2P Archive for: Go

  Return to Index  

pro_vb thread: CreateProcessWithLogonW API call. HELP!!! PLEASE!!!


Message #1 by Paul Rivers <RiversPA@e...> on Fri, 19 Oct 2001 11:44:43 -0400
Paul,

first of all, never use GetLastError in VB because VB calls a lot
of API's in the background, thus the returned error can be completely
wrong. Always use err.LastDllError, which is correct.

I downloaded the example from the allapi web site, and it works great in my
pc:

http://www.allapi.net/apilist/example.php?example=CreateProcessWithLogon

Check it out. I just changed my logon, domain and password and it
was fine. I tried also to mispell some of the parameters, and I always 
got back the right error code.

m.



-----Original Message-----
From: Paul Rivers [mailto:RiversPA@e...]
Sent: Friday, October 19, 2001 8:45 AM
To: professional vb
Subject: [pro_vb] CreateProcessWithLogonW API call. HELP!!! PLEASE!!!



I'm REALLY beginning to hate this API call.  I finally get all the bugs
worked out of the type mismatches and ByRef calls, and now, it just
doesn't do anything.  It goes to call the process and gives me back a 0
RC and a 0 on GetLastMessage.  What could I be doing wrong?

Please help!  I'm at the end of my rope.  Don't want to have to try to
write this doggone thing in C++.


  Return to Index