Developers guide
Chapter 22: Wireless Wide-Area Networking
Windows CE 5.0 Connection
208 Psion Teklogix Mobile Devices SDK Developers Guide
The following example uses the RAS namespace for the Mobile Devices SDK to make the Inter-
net connection. See Chapter 12: “RAS (Remote Access Service)”
for more information.
if (hRasComm != NULL)
{
RasHangUp(hRasComm);
hRasComm = NULL;
}
return FALSE;
}
return TRUE;
}
//
// Window's Message handler (WndProc)
//
case WM_RASDIALEVENT:
{
RASCONNSTATE rasconnstate = (RASCONNSTATE) wParam;
DWORD dwError = (DWORD) lParam;
}
return TRUE;
Example 22.6 Windows CE 5.0 Internet Connection in C#
using PsionTeklogix.WWAN;
using PsionTeklogix.RAS;
bool returnValue = true;
// see ealier section on WWAN Initialization
if (InitWWANandWait())
{
private Entry wwanEntry = new Entry("Wireless WAN");
wwanEntry.UserName = "ISP@CINGULARGPRS.COM";
wwanEntry.Password = "CINGULAR1";
try
{
if (!wwanEntry.Dial(false))
{
returnValue = false;
}
}
catch (Exception ex)
{
MessageBox.Show("FAIL: \r\n" + ex.Message, "RAS Dial");
returnValue = false;
}
}
return returnValue;
Example 22.5 Windows CE 5.0 Internet Connection in C++ (Continued)