Appearance
Flo_LoadWebDef
Declaration
C# public static extern bool Flo_LoadWebDef(string aFID, out string aXML, out string aXML2);
Delphi function Flo_LoadWebDef(aFID : PChar; out aXML, aXML2 : PChar) : Boolean; stdcall;
Example
csharp
try
{
string XML
string XML2;
Boolean result = FlowAPI.Flo_LoadWebDef("00000000-0000-0000-0000-000000000000", XML, XML2);
if (result)
{
TFloWebSource WebSource= new TFloWebSource();
WebSource= (TFloWebSource)XMLToObject(XML,WebSource.GetType());
MessageBox.Show("Successfully loaded Web Definition - " + WebSource.ModuleName);
}
else MessageBox.Show("Error loading Web Definition");
}
catch (Exception ex)
{
MessageBox.Show("Exception loading Web Definition - " + ex.Message);
}pascal
Delphi
var XML, XML2: string
var oXML : DomDocument60;
try
Result := Flo_LoadWebDef('00000000-0000-0000-0000-000000000000', XML, XML2);
if Result then
begin
oXML:= CoDOMDocument60.Create;
oXML.LoadXML(XML);
showmessage('Successfully loaded Web Definition - ' + VarToStr(oXML.DocumentElement.selectSingleNode('ModuleName').nodeValue))
end else
showmessage('Error loading Web Definition');
except
on e : exception do
showmessage('Exception loading Web Definition - ' + e.Message);
end;Description
This function loads the Web Definition specified by aFID and returns it as aXML and aXML2.
aXML contains the basic settings of the Web Definition as found on its front screen editor, aXML2 contains the design of the Web Definition.
If using C# you can easily work with the XML string by serializing it to an instance of a class