Loads a fly file or terrain database into TerraExplorer.
LoadEx passes the user name and password for the Terrain Database opened. In addition, LoadEx can work in synchronous or asynchronous mode. In synchronous mode the method returns after the file is loaded. In synchronous mode, the method returns immediately. You can then use ITerraExplorerEvents4::OnLoadFinished() to be notified when the file is loaded .
HRESULT LoadEx(
[in] BSTR URL,
[in] BSTR User,
[in] BSTR Password,
[in, defaultvalue(0)] long Asynchronous)
Parameters:
URL – A full pathname or a URL of a FLY file to be loaded by TerraExplorer. You can also load a local terrain database file by using a full pathname to an MPT file, or a terrain database from TerraGate by following the format: “TerrainDatabse.Type@TerraGateAddress:PortNumber” (e.g., washington-dc.mpt@tgate.skylinesoft.com).
User – Terrain security user name. If the MPT file is not secure, the user name is ignored.
Password – Terrain security password for the specified user. If the MPT file is not secure, the password is ignored.
Asynchronous – When set to TRUE, the method executes asynchronously, meaning returns immediately. When set to FALSE, the method executes synchronously.
Return Values:
S_OK if the method call succeeded.