Querying Network Settings in Connection Manager for Portable Navigation Devices

Windows CE 5.0 Not SupportedWindows Embedded NavReady 2009 Supported

10/16/2008

Applies to Windows Embedded NavReady

You can use the DMProcessConfigXML function to query any of the network settings.

For example, to retrieve the GUID of a PPP connection, you can query for the value attribute of the DestId parameter of a PPP connection defined inside the CM_PPPEntries configuration service provider.

To do this, pass the following XML string to the pszWXMLin parameter of DMProcessConfigXml:

<characteristic type="CM_PPPEntries">
    <characteristic type="BTPhoneNetPPP">
      <parm-query name="DestId" />
    </characteristic>
</characteristic>

DMProcessConfigXml responds by returning the following XML string in ppszwXMLout:

<characteristic type="CM_PPPEntries">
    <characteristic type="BTPhoneNetPPP">
      <parm name="DestId" value="{A1182988-0D73-439e-87AD-2A5B369F808B}" />
    </characteristic>
</characteristic>

To query a GUID for a specific connection

  1. In your application code, call DMProcessConfigXML and pass in the XML string for a Configuration Service Provider. The XML string must contains a tag called <parm-query>. As illustrated above.

  2. When DMProcessConfigXML returns, the returned XML string in the ppszwXMLout buffer contains the GUID in the value attribute of the <parm> tag. Extract the GUID from the returned XML string.

  3. Put the GUID into the CONNMGR_CONNECTIONINFO structure that you create, and then pass that structure into a call to ConnMgrEstablishConnection or ConnMgrEstablishConnectionSync.

See Also

Tasks

Establishing a Connection to a Bluetooth Network

Other Resources

Connection Manager Application Development for Portable Navigation Devices