Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Urgent:How to find other computer names in local domain
Message
De
21/10/1998 05:35:46
 
 
À
20/10/1998 08:53:11
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00147487
Message ID:
00148797
Vues:
42
>>>But as per the msdn library documentation you cannot use that function on the Windows 95 . Alternatively you can use "mpr.dll" with functions WNetEnumResource() and wnetopenenum()
>>
>>You're right. Sorry...
>>
>>>, but it has some complications. like sending a NETRESOURCE structure by reference. Is it possible in VFP sending structures like that ?
>>
>>Yes. You can simulate almost any structure using a string. To send it by reference, just send the corresponding string by reference. The problem is that this structure contains pointers and, in order to get the strings pointed by those pointers, you'll need something like my Pointers class.
>>
>>> How can I use C code directly from Foxpro . If you have any example pl. send it. and also tell the additional files that I should have to do that.
>>
>>You cannot use C code directly. But you can build a DLL wrapper in C/C++. It is must easier to deal with these functions form C/C++ than from VFP.
>>
>>I played with these functions about 6 months ago. I will dig on my computer at work and if I still have that test program, I will send it to you. It's in C++.
>
>He's definitely going to need either your pointers class or a wrapper - there are several embedded pointers used in a NETRESOURCE structure.

Well. I don't think I need any pointers class. There are some functions in Kernel32. which provide me necessary memory copy and pointer to string conversions.

And Thanks to all of you. I was able to get the all computer list in my network
with all the domains and their servers and all connectable resources.

I did it in VB 6 . But soon will be converting that to VFP . It is not difficult and no need of any additional clases.

Even the NETRESOURCE is having strings and numbers in it, it is not difficult to do. Any way I was able to get it with the help of Cetin and George.
Thanks for your suggestion Paul. The trick of pointers, converting to strings was useful.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform