WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

s... Socket Functions

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

sConnect(...) starting Dialup Networking

Keywords:     sConnect dial up networking

Question:

Is there anyway to prevent the following code from bringing up the "Connect to" dial-up networking control box in Win95 when it executes the sConnect(...) command. If I choose for the connection, the script continues and properly connects to UX8 (our DNS). It works properly on systems that do not have a dial-up adaptor.
        socket=sOpen()
        sConnect(socket, "ux8", 7)
        ipaddress=wxGetInfo(1,socket)
        sClose(socket)
I have checked the settings under Dial-Up connection and unchecked the "Prompt for dial-up connection" option.

I don't want dial-up networking to even be started. We have a TCP/IP network, and when a user with dial-up networking enabled runs this part of the script, the socket function tries to invoke dial-up networking instead of using the network TCP/IP.

If you choose cancel when the "Connect To" box appears, the script continues properly, creating the socket connection over the LAN.

PC's without a dialup adaptor work fine.

Is there a binding order or priority in which the socket functions work? Can I force it to use the NIC verus the Modem?

Could it have anything to do with the fact that this is part of the login script? Is the TCP stack not fully initialized yet?

Answer:

I had the same problem and solved it by disabling the autodial from the registry. It seems that no matter whether you have a local network with TCP/IP or not, the dial-up connection is always tried first if present; it does look like a network provider priority but unlike NT I couldn't find the registry key that controls the order.

Disabling autodial in:

CURRENT USER\Software\microsoft\windows\currentcontrolset\internetsettings[EnableAutoDial]
works fine for me. I disable it when I'm sure I'm on the network, and enable it otherwise.

Another user reported: The latest version of DUN ( version 1.2 I believe) fixes the dialog appearing. I recently downloaded it from Microsoft and the Dialog does NOT appear any more.

In the older version you can check the appropriate boxes, but it still pops up.

The login script might be part of the problem. Maybe add a Delay(20) before you do the network stuff. Or do it in the startup scripts.


Article ID:   W12670
Filename:   sConnect starting up Dial-up Networking.txt
File Created: 1999:04:15:16:48:50
Last Updated: 1999:04:15:16:48:50