SaveTextProject
This procedure will export a Project to the .ostxt format in the same way as the Studio GUI:

Example
Begin SaveTextProject; Project "ProjectABC"; File "/tmp/ProjectABCexport.ostxt"; Options /WriteAnnotation=True; End;
If the Project statement is omitted, the active project will be exported (e.g. in a pipeline OScript).
WARNING: File must be a physical path on the relative host.
Output
An OSTXT file will be generated for all tabular data in the project. Each object is identified by bracketed labels, with the table contents below.
The following is an example project exported to OSTXT, with the top three lines printed.
<ProjectInfo> ActiveDataName=BalancedGroup2.DESeq2RContrastTest; Name=DEseq2_SKCM_Balance; -- <AuditTrail> 3619000000000000086F636F72656C6962184F6D6963736F66742E446174612E4175646974547261696C00090A0000000D08 31312E372E312E310D0850656172736F6E4A044CA79E06C932DA080D0A4E657750726F6A6563740D8A01426567696E204E65 -- <LargeMicroArray, Name=SKCM_ERBB2.RnaSeq_Transcript.Genes> ID TCGA-3N-A9WB-06A TCGA-3N-A9WC-06A TCGA-3N-A9WD-06A TCGA-BF-A1PU-01A TCGA-BF-A1PV-01A TCGA-BF-A1PX-01A TCGA-BF-A1PZ-01A TCGA-BF-A1Q0-01A TCGA-BF-A3DJ-01A TCGA-BF-A3DL-01A TCGA-BF-A3DM-01A TCGA-BF-A3DN-01A TCGA-BF-A5EO-01A TCGA-BF-A5EP-01A TCGA-BF-A5EQ-01A TCGA-BF-A5ER-01A TCGA-BF-A5ES-01A TCGA-BF-A9VF-01A TCGA-BF-AAOU-01A TCGA-BF-AAOX-01A ....
<DataInfo, Data=SKCM_ERBB2.RnaSeq_Transcript.Genes> Category=Data; ClientInfo=; -- <Design, Name=SKCM_ERBB2.RnaSeq_Transcript.Genes\Design> ID Tumor Type SubjectID Sample Type ComparisonCaseMembership Comparison Control Membership Comparison Membership Selected TCGA-3N-A9WB-06A SKCM TCGA-3N-A9WB Metastatic NA TCGA_SKCM.GPLna.DESeq2R.test115 TCGA_SKCM.GPLna.DESeq2R.test115 Yes -- <DataColumn, Data=SKCM_ERBB2.RnaSeq_Transcript.Genes\Design> Column Type Alias Category Color.Additional Metastatic Color.Additional New Primary Color.Blood Derived Normal Color.Bone Marrow Normal Color.Buccal Cell Normal Color.Metastatic Color.Primary Blood Derived Cancer - Peripheral Blood Color.Primary Tumor Color.Recurrent Tumor Color.Solid Tissue Normal ColumnType ColumnWidth DataMode Description Mode SubMode TableSource ToolTipText UseFixedColor Tumor Type Factor 80 NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA NA -- <DataView, Data=SKCM_ERBB2.RnaSeq_Transcript.Genes\Design, Name=Table> ColumnHeaderHeight=0; Opened=True; -- <Annotation, Name=SKCM_ERBB2.RnaSeq_Transcript.Genes\Annotation> ID ENSG00000223972.5 -- <DataColumn, Data=SKCM_ERBB2.RnaSeq_Transcript.Genes\Annotation> Column Type
<DataView, Data=SKCM_ERBB2.RnaSeq_Transcript.Genes\Annotation, Name=Table> ViewType=TableView
-- <DataView, Data=SKCM_ERBB2.RnaSeq_Transcript.Genes, Name=Table> ColumnHeaderHeight=0; Opened=True; -- <Table, Name=Balanced.DispersionTable> Column RowMeans Dispersion Disp Gene Est Disp Fit ENSG00000223972.5 2.9542376001293 5.22290250394732 5.67657499813982 2.74643587508985 -- <DataColumn, Data=Balanced.DispersionTable> Column Type RowMeans Double