Background:We have a DCR that has to generate 3 different HTML files. We will use the data in DCR to name the html pages and we know the directory path where each of these 3 files will be generated. To sum up we have the data, file paths and file names all in the DCR.Issue:If we click on generate button it asks for a single file name to be generated. We dont want users to provide filename as the structure of our site and naming convention is set.Can someone help us to understand how can we click generate button and do not pop up a window to ask for filename -- instead on click of generate button we just use the data (as explained in background) and generate the pages?Regards,ASHARMA
First thing, you would need to have 3 different TPLs for the Data Type in question. I guess you have that set already.Coming to your problem, the best solution is to have one generic TPL which would in turn generate all the three pages. To achieve this you would need to use the CLT iwgen. It takes the TPL path, DCR Path and the generated file path as parameters.Check the help of iwgen for more information.
Background:We have a DCR that has to generate 3 different HTML files. We will use the data in DCR to name the html pages and we know the directory path where each of these 3 files will be generated. To sum up we have the data, file paths and file names all in the DCR.Issue:If we click on generate button it asks for a single file name to be generated. We dont want users to provide filename as the structure of our site and naming convention is set.Can someone help us to understand how can we click generate button and do not pop up a window to ask for filename -- instead on click of generate button we just use the data (as explained in background) and generate the pages?
An interesting answer? You say one thing, then say the opposite, then throw in partial information about available CLTs - none of which actually answers the question. You need to override the Generate button (and menu option) to call your own script that will parse the DCR to get all three of the names to be generated and then (as initially suggested by chetansethi) use one of the CLTs (iwgen or iwpt_compile.ipl), three times, to generate the output for each name; or (as subsequently suggested by chetansethi) you extract the primary name from the DCR and run the page generation process once, where the PT in question knows how to derive the second and third names from the initial name and does so using either iw_ostream tags or basic Perl I/O [indent]Note: In you use iwpt_compile.ipl, or if you use iw_ostream or Perl I/O - you will need to explicitly set the extended attributes on the generated files to associate them with the DCR and PT[/indent]Alternatively, somewhat, you use a workflow-driven process and remove the Generate button completely from the UI and let the workflow perform the process of generating the 3 files - pretty much as described above.
Interesting Answer!!! yeah sure as it is simple..You dont need to overwrite the generate button or do it through workflow.Clicking on generate button shows the list of all TPLs available to that data category and the user chooses the generic TPL which subseqeuently calls iwgen with the other TPLs to generate multiple files..
just remove the generate button and run thru the workflow... my $.01
Greg,Just curious as how to remove those specific buttons from the DCT?
For 6.5 (perhaps 6.x) there is a viewoptions directive in the templating.cfg file (read the FormsPublisher Developers' Guide for more info) that allows you to determine what buttons appear in the upper-right portion of the Edit DCR window.
It is there in 6.1 as well...~Jeff