WireLess Studio Widgets Developer's Guide
WSWDG ContentsWStFactory class reference

LoadFormsFromFile

This method allows to load the layout of the forms used by an application from a xml file.

Ole declaration

VARIANT_BOOL LoadFormsFromFile(LPCTSTR sFilePath);

Parameters
sFilePath
The full path (relative or absolute) of the xml file.
Return Value

On success, LoadFormsFromFile returns TRUE, FALSE otherwise. To get extended information, call WStError::GetLastErrorCode.

Remarks

The resources used by the forms specified in the xml are loaded/transferred once the forms and their widgets are created.

The tags and attributes used by the forms and resources in the xml file are detailed here.

Example
C# (See PickingDemoXml for a full example)
using WirelessStudioOleWidgets;
WStFactory oFactory = new WStFactory();
if (!oFactory.LoadFormsFromFile(@"..\SamplesWidgets\PickingDemoXml\pickingDemoXmlLayout.xml")){
	return;
}
See also

CreateForm | CreateWidget | LoadExternalIcon | CreateCustomFont

WStWiget class reference | WStForm class reference | WStFactory class reference | WStError class reference