Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
List of Dial-Up Connections
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Title:
List of Dial-Up Connections
Miscellaneous
Thread ID:
00146361
Message ID:
00146361
Views:
50
Hi all,

I am trying to create a routine that will gather the list of dial-up connections. The only way that I think this can be done is through API calls. I found two functions in ADVAPI32.DLL that should do the trick, but I haven't been able to get them to work.

Here is my current code. If anyone can point out any problems or another way to do this, I would appreciate it.

DECLARE RegOpenKeyEx IN ADVAPI32.DLL INTEGER, STRING, INTEGER, ;
INTEGER nAccess, INTEGER @nKeyHandle
DECLARE RegEnumKeyEx IN ADVAPI32.DLL INTEGER nKeyHandle, ;
INTEGER iValue, STRING @lpszName, INTEGER @lpcchName, INTEGER, ;
STRING @lpszClass, STRING @lpcchClass, INTEGER @lpftLastWrite

nKeyHandle = 0
RegOpenKeyEx(2147483649,"RemoteAccess\Profile",0,8,@nKeyHandle)

iValue = 0
STORE SPACE(255) TO lpszName, lpszClass, lpcchClass
STORE 255 TO lpcchName, lpftLastWrite
RegEnumKeyEx(nKeyHandle,iValue,@lpszName,@lpcchName,0,@lpszClass,@lpcchClass,@lpftLastWrite)
Brien R. Givens

Brampwood Systems
Next
Reply
Map
View

Click here to load this message in the networking platform