Question
· Nov 20, 2016

How to export class package in xml

Hi!

Is there any way to export a class package to xml  file programmatically which will include all the classes of the package?

Discussion (12)3
Log in or sign up to continue
SAMPLES>do $system.OBJ.ExportPackage("Sample","samples.xml")

Exporting class: Sample.Address
Exporting class: Sample.Company
Exporting class: Sample.CustomResultSet
Exporting class: Sample.Customer
Exporting class: Sample.Employee
Exporting class: Sample.Installer
Exporting class: Sample.ListOfPersonIdentification
Exporting class: Sample.MyException
Exporting class: Sample.Person
Exporting class: Sample.PersonIdentification
Exporting class: Sample.ResultSets
Exporting class: Sample.Task
Exporting class: Sample.TaskExample1
Exporting class: Sample.TaskExample2
Exporting class: Sample.TaskExample3
Exporting class: Sample.USZipCode
Exporting class: Sample.Utils
Exporting class: Sample.Vendor

How about this?

SAMPLES>s sc=$system.OBJ.Export("/csp/samples/*.csp","c:\s\junk.xml","/recursive=1")
 
Exporting to XML started on 10/29/2018 09:36:31
Exporting CSP/CSR or file: /csp/samples/basic.csp
Exporting CSP/CSR or file: /csp/samples/cinema/Cinema.csp
Exporting CSP/CSR or file: /csp/samples/cinema/Film.csp
Exporting CSP/CSR or file: /csp/samples/cinema/LoadData.csp
Exporting CSP/CSR or file: /csp/samples/cinema/Order.csp
Exporting CSP/CSR or file: /csp/samples/cinema/Search.csp
Exporting CSP/CSR or file: /csp/samples/cinema/SearchResults.csp
Exporting CSP/CSR or file: /csp/samples/cinema/ShowTimes.csp
Exporting CSP/CSR or file: /csp/samples/cinema/TopPicks.csp
Exporting CSP/CSR or file: /csp/samples/context.csp
Exporting CSP/CSR or file: /csp/samples/cookie.csp
Exporting CSP/CSR or file: /csp/samples/custom.csp
Exporting CSP/CSR or file: /csp/samples/error.csp
Exporting CSP/CSR or file: /csp/samples/expires.csp
Exporting CSP/CSR or file: /csp/samples/form.csp
Exporting CSP/CSR or file: /csp/samples/formsubmit.csp
Exporting CSP/CSR or file: /csp/samples/include.csp
Exporting CSP/CSR or file: /csp/samples/includedpage.csp
Exporting CSP/CSR or file: /csp/samples/inspector.csp
Exporting CSP/CSR or file: /csp/samples/iterate.csp
Exporting CSP/CSR or file: /csp/samples/language.csp
Exporting CSP/CSR or file: /csp/samples/logerror.csp
Exporting CSP/CSR or file: /csp/samples/loop.csp
Exporting CSP/CSR or file: /csp/samples/lottery.csp
Exporting CSP/CSR or file: /csp/samples/lotteryend.csp
Exporting CSP/CSR or file: /csp/samples/lotteryhistory.csp
Exporting CSP/CSR or file: /csp/samples/lotteryjoin.csp
Exporting CSP/CSR or file: /csp/samples/lotterymain.csp
Exporting CSP/CSR or file: /csp/samples/lotterymenu.csp
Exporting CSP/CSR or file: /csp/samples/menu.csp
Exporting CSP/CSR or file: /csp/samples/object.csp
Exporting CSP/CSR or file: /csp/samples/popform.csp
Exporting CSP/CSR or file: /csp/samples/private.csp
Exporting CSP/CSR or file: /csp/samples/protected.csp
Exporting CSP/CSR or file: /csp/samples/protectedentry.csp
Exporting CSP/CSR or file: /csp/samples/query.csp
Exporting CSP/CSR or file: /csp/samples/redirect.csp
Exporting CSP/CSR or file: /csp/samples/rulemgr.csp
Exporting CSP/CSR or file: /csp/samples/serversideredirect.csp
Exporting CSP/CSR or file: /csp/samples/sessionevents.csp
Exporting CSP/CSR or file: /csp/samples/showsource.csp
Exporting CSP/CSR or file: /csp/samples/soapdemo.csp
Exporting CSP/CSR or file: /csp/samples/staticsql.csp
Exporting CSP/CSR or file: /csp/samples/streamserve.csp
Exporting CSP/CSR or file: /csp/samples/submit.csp
Exporting CSP/CSR or file: /csp/samples/svgdemo.csp
Exporting CSP/CSR or file: /csp/samples/testerror.csp
Exporting CSP/CSR or file: /csp/samples/textinclude.csp
Exporting CSP/CSR or file: /csp/samples/upload.csp
Exporting CSP/CSR or file: /csp/samples/wapzipcode.csp
Exporting CSP/CSR or file: /csp/samples/while.csp
Exporting CSP/CSR or file: /csp/samples/xmlclasses.csp
Exporting CSP/CSR or file: /csp/samples/xmlclasseserror.csp
Exporting CSP/CSR or file: /csp/samples/xmlclassesresult.csp
Exporting CSP/CSR or file: /csp/samples/xmlimport.csp
Exporting CSP/CSR or file: /csp/samples/xmlquery.csp
Exporting CSP/CSR or file: /csp/samples/xmlqueryresult.csp
Exporting CSP/CSR or file: /csp/samples/zipcode.csp
Export finished successfully.
 
SAMPLES>