Establish temporary network connectivity
Telecommunication applications cannot initiate long-term connections. However, if you need temporary connectivity to a specific network, you can use the Mobile Broadband API as follows:
Create an instance of IMbnConnectionManager.
Register to the IMbnConnectionEvents connection point.
Create an instance of IMbnInterfaceManager.
Obtain an IMbnConnection interface for the device by calling IMbnConnectionManager::GetConnection.
Establish a connection by calling IMbnConnection::Connect. The connectionMode parameter must be set to MBN_CONNECTION_MODE_TMP_PROFILE, and the strProfile parameter must be a mobile broadband profile description.
The results of the connect attempt are returned by using the IMbnConnectionEvents::OnConnectComplete method. To disconnect when you are finished, invoke the IMbnConnection::Disconnect method. Status is returned by using IMbnConnectionEvents::OnDisconnectComplete.