Printing many individual diagrams through WorkBench can be slow and time consuming. Using the option -printdiag in c_io.exe, a user can then print many diagrams at once. Once the first command line has been set up, it can be copied, pasted. The file name and the identity can be altered for each diagram that the user requires printing.
The options to do this are:
Required Options
-printdiag allows a user to set the type of output for the diagram. The types currently used for this are:
- hpgl – Hewlett-Packard Graphics Language
- ps – PostScript
- rtf – Rich Text Format
- svg – Scalable Vector Graphics
Elective Options
-onlydiag will output the diagram without a surrounding frame and the details which the frame contains.
-catcode will print the category value in the diagrams border.
-portrait will cause the diagrams to be output into a portrait orientation rather than the default of landscape. This option is only used in conjunction with -printdiag, it will not work with any other c_io.exe options.
-file sets the name and location of the file to be output.
-query set the query to being used and as before -qloc sets the location
-identity overrides any identity set within the used query
-printdiag Batch File Examples
"%CRADLEHOME%\bin\exe\windows\c_io.exe" -login admin,ADMIN,demo -printdiag svg -file "C:\Temp\DFD_C.svg" -query "Diagram - Ess DFD" -qloc project -identity "C" "%CRADLEHOME%\bin\exe\windows\c_io.exe" -login admin,ADMIN,demo -printdiag rtf -file "C:\Temp\eFFBD_133.rtf" -query "Diagram - Ess eFFBD" -qloc project -portrait -identity "1.3.3" -onlydiag
Helpful other c_io options
There are several helpful options especially when using in a batch file.
-log allows a user to specify a name for a log. This is the log that will have the details of the actions performed during the import.
-noldap allows users to bypass using LDAP when running a command line or batch file.
-errorstack option is for logging any issues with the import
"%CRADLEHOME%\bin\exe\windows\c_io.exe" -login admin,ADMIN,demo -export "C:\Temp\all3.exp" -type all -noldap -errorstack -log "C:\Temp\all4_log.log" "%CRADLEHOME%\bin\exe\windows\c_io.exe" -login admin,ADMIN,demo -export "C:\Temp\pdb3.exp" -type pdb -noldap -errorstack -log "C:\Temp\pdb3_log.log"
Options not used within a batch file
There are a couple of options that are not used in a batch file. The reason is that they are only useful in a command line, in a command prompt as they show pop ups with information on them.
-ver lets the user see what the version number, date and time of the build they are using.
-help option allows a user to see the command line options.
Related Posts
Read Exporting using c_io in a batch file article for information on how to create data transfer files from Cradle.