|
-
Dec 14th, 2001, 06:14 AM
#1
Thread Starter
Member
RAS Dial Up problems in Win2K - URGENT!
Hello there,
I'm writing, actually completing, an application that sends
strings over sockets to a server over PPP.
In order to use PPP|TCP/IP I need to use a RAS Dial Up
entry.
This is the code I use to start dialing the connection:
'*******************************************
'FUNCTION NAME : UseDialUpConnection
'
'EXPLANATION : Use an existing Dial Up connection
'
'PARAMETERS I/O : I strConnection : Connection Name
' I strUserName : Username
' I strPassword : Password
' O Boolean : DialUp succesfull?
'********************************************
Public Function UseDialUpConnection(
ByVal strConnection As String, _
ByVal strUserName As String, _
ByVal strPassword As String) As Boolean
Dim RasDialer As RASDIALPARAMS
Dim lngHandle As Long
Dim lngResponse As Long
RasDialer.dwSize = Len(RasDialer) + 6
ChangeBytes strConnection, RasDialer.szEntryName
ChangeBytes "C:\WINNT\SYSTEM32\RAS\rasphone.pbk", RasDialer.szPhoneNumber 'Phone number stored for the connection
ChangeBytes "*", RasDialer.szCallbackNumber 'Callback number stored for the connection
ChangeBytes strUserName, RasDialer.szUserName
ChangeBytes strPassword, RasDialer.szPassword
ChangeBytes "*", RasDialer.szDomain 'Domain stored for the connection
...
Under win98 it works fine!
But when I try to run this code under Win 2000 it crashes and returns the error :
[ 621 - The system can't open the phonebook(file) ]
I already tried to specify an exact path for the RasDialer.szPhoneNumber,
as you can see... but the problem remains 
Please help me if you know the answer to this problem...
I MUST hand this application over to my customer today...
Thanks for all your help!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|