Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
COM object cannot find my data
Message
From
11/08/2000 11:18:59
 
 
To
11/08/2000 10:42:10
Jay Shepherd
Construction DataFax, Inc.
Montevallo, Alabama, United States
General information
Forum:
Visual FoxPro
Category:
Internet applications
Miscellaneous
Thread ID:
00401883
Message ID:
00403952
Views:
18
>>>>>>make an explicit connection to the UNC using WNetAddConnection2() or >WNetAddConnection3(), which allow you to specify a userid and password for the >connection - it's unlikely that the IUSR_machinename account has privileges on >another machine or in a domain unless you've explicitly taken steps to >establish such accounts. IUSR_machinename is a local account, not a domain >account, and won't have domain privileges or corresponding accounts on other >peer stations.
>>>
>>>Here is an article I found on this:
>>>
>>>http://support.microsoft.com/support/kb/articles/Q138/6/78.asp
>>>
>>>Why do you recommend using WNetAddConnection2 or 3?
>>
>>Because unlike WNetAddConnection, they permit you to specify a domain context, user name and password.
>
>You or someone out there wouldn't have some sample code for this would you? I've tried some various things and I end up crashing my system. The NETRESOURCE structure is throwing me off somewhere and I can't quite duplicate it properly with a character string.
>

My NETRESOURCE class (relies on CLSHEAP, also downloadable from here on UT) includes sample code for implementing WNetAddConnection3(). Without a mechanism to implement static memory allocation and addressing, you'll never get the NETRESOURCE structure implemented, since it includes embedded pointers to strings, and with VFP shifting things around in memory at will, it is not feasible to just put stuff into a VFP string - either NETRESOURCE/CLSHEAP will be needed, or Christof's STRUCT to allocate and decode the needed structures. Like I said, NETRESOURCE includes an example that implements WNetAddConnection3(); with STRUCT, you'll have to implement it on your own.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform