Function Function Run1LPFCommand( sInput$ ) As Long
Purpose: Run OneLiner command: File | Export network data command.
Works in: OneLiner.
Parameters:
sInput [in] XML string, or full path name to XML file, containing XML node as described in Remarks section below.
Return value:
1 Success
0 Failure
Remarks: sInput must include XML node EXPORTNETWORKwith attributes in the list below (* denotes required entries, [] denotes default value).
FORMAT Output format: [DXT]-ASPEN DXT; PSSE-PSS/E Raw and Seq
SCOPE Export scope: [0]-Entire network; 1-Area number; 2- Zone number
AREANO Export area number
ZONENO Export zone number
INCLUDETIES Include ties: [0]-False; 1-True
====DXT export only:
DXTPATHNAME (*) full valid pathname of ouput DXT file
====PSSE export only:
RAWPATHNAME (*) full valid pathname of ouput RAW file
SEQPATHNAME (*) full valid pathname of ouput SEQ file
PSSEVER [33] PSS/E version
X3MIDBUSNO [18000] First fictitious bus number for 3-w transformer mid point
NEWBUSNO [15000] First bus number for buses with no bus number
Example:
Sub main
sExportFile$ = GetOlrFileName() & ".raw"
sExportFileSEQ$ = GetOlrFileName() & ".seq"
sInput$ = "<EXPORTNETWORK " & _
"FORMAT=""PSSE"" " & _
"RAWPATHNAME=""" & sExportFile & """ " & _
"SEQPATHNAME=""" & sExportFileSEQ & """ " & _
"PSSEVER= ""32"" X3MIDBUSNO=""21000"" NEWBUSNO=""31000"" " & _
"SCOPE= ""1"" AREANO=""1"" INCLUDETIES=""1"" " & _
" />"
Print sInput
If Run1LPFCommand( sInput ) Then
Print "Success: output in " & sExportFile
Else
Print "Error: " & ErrorString()
End If
End Sub