API support to print comprehensive Test Plan PDF file?
3 answers
As I know, we can print comprehensive PDF file for a Test Plan in the "View Test Plans" view.
I'd like to know is there an API(REST stye, maybe) existing to allow user to provide a test plan ID and get a printed PDF file?
The simple answer is "no". That's not really a feature that we have been asked for yet, so I'd be interested to hear more about your use case.
The long answer is that the Print feature does use a HTTP GET from the Web UI to kick off the print job. This means that if you know exactly how to form the URL, you could probably do the same from your own code. The one problem would be that the PDF would still be stored in RQM's repository when it completes, not returned to your application.
If that limitation is not a problem for you, I can play around with manually creating URLs to kick off print jobs. If I have any success, I can share the URL format with you so you can do the same.
As I know, we can print comprehensive PDF file for a Test Plan in the "View Test Plans" view.
I'd like to know is there an API(REST stye, maybe) existing to allow user to provide a test plan ID and get a printed PDF file?
The simple answer is "no". That's not really a feature that we have been asked for yet, so I'd be interested to hear more about your use case.
The long answer is that the Print feature does use a HTTP GET from the Web UI to kick off the print job. This means that if you know exactly how to form the URL, you could probably do the same from your own code. The one problem would be that the PDF would still be stored in RQM's repository when it completes, not returned to your application.
If that limitation is not a problem for you, I can play around with manually creating URLs to kick off print jobs. If I have any success, I can share the URL format with you so you can do the same.
Hi Mike,
Thanks for your reply.
After Firebugging the print PDF button in "View Test Plans" view, I think the print flow is related to com.ibm.rqm.print.common.service.IPrintService and com.ibm.rqm.planning.common.service.rest.IQueryFilterRestService.
But if you can have some runnable code I can leverage, that will be terrific.
You said that you want to print PDF files.i'd like to recommend a print code to have a try:
using RasterEdge.Imaging.Basic; using RasterEdge.Imaging.Basic.Core;
using RasterEdge.Imaging.Basic.Codec;
using RasterEdge.Imaging.PDF;
RasterEdgeImaging PDF = new RasterEdgeImaging();
public void PdfProcessorPrint();
{
PDFInputFile = (@"C:/1.pdf");
Printer = (@"C:/HP Color LaserJet 5550 PCL 6");
};
PDF. PdfProcessorPrint(@"C:/1.pdf", @"C:/HP Color LaserJet 5550 PCL 6");