The SAS Output Delivery System and reporting techniques

How to add OMR (Optical mark recognition) to a PDF format?

Accepted Solution Solved
Reply
New Contributor
Posts: 4
Accepted Solution

How to add OMR (Optical mark recognition) to a PDF format?

Hi,

 

Please may I know, if it possible to add an OMR mark to a PDF output using ODS and template procedure.

I have seen how to add an watermark and used this code which is already available.

 

proc template;
    define style watermark;
    parent=styles.printer;
    style header from header /
          background=_undef_;
    style body from document /
          background=_undef_
          backgroundimage="watermark.jpg";
  end;
  run;

  ods pdf file="test.pdf" style=watermark;
  proc report data = sashelp.class nowd;
  run;
  ods pdf close;

Please may I know if I have any specific style in order to get OMR on PDF output, or do I need to define a new style.

 

Thankyou all for your help and time.

 

Regards,

Rahul


Accepted Solutions
Solution
‎06-17-2016 11:58 AM
SAS Super FREQ
Posts: 8,641

Re: How to add OMR (Optical mark recognition) to a PDF format?

[ Edited ]

Hi:
RW9 is correct -- the ODS PDF destination does NOT have a way to invoke JavaScript to alter the document. This is a very old user group paper that outlines reading OMR data with SAS, but not how to put the OMR into a PDF file -- http://www2.sas.com/proceedings/sugi26/p120-26.pdf

Then, this paper http://support.sas.com/resources/papers/proceedings13/099-2013.pdf also mentions OCR and OMR but in the context, again, of reading the data, not making the form or making the OMR in a file.

I believe that Adobe has something called a "Form Wizard" for making forms, that is not something you could interface to using ODS PDF.

cynthia

View solution in original post


All Replies
Esteemed Advisor
Esteemed Advisor
Posts: 6,670

Re: How to add OMR (Optical mark recognition) to a PDF format?

I cannot find anything PDF Optical mark recognition related, so this isn't part of the base PDF package (unless its called something else?).  How do you do this normally - i.e. if you did it outside of SAS completely, is it a third party apllication or plugin?  If so I don't think you would be able to do it through SAS< you would need a manual step after the output process has completed.  Never heard of the term myself.

New Contributor
Posts: 4

Re: How to add OMR (Optical mark recognition) to a PDF format?

Hi,

 

As far as I know, an OMR mark is added to pdf by using Javascript. 

 

Actally, what I am trying to do is, I am able to generate a PDF document using SAS ODS and after that the PDF file needs to be folded at the bottom of the letter. Curretly this is done manually. If, I am able to add an OMR mark by using SAS to the PDF then the machine will recognise the OMR mark and it will fold the letter at the location of the OMR mark.

 

I would like to know if you have ever come across this type of situation. I have read papers on adding watermark and making it transparent. Unfortunately, there is nothing related to adding an OMR mark.

 

I hope someone might have done this.

 

Thank you very much for your reply.

 

Regards,

Rahul

Esteemed Advisor
Esteemed Advisor
Posts: 6,670

Re: How to add OMR (Optical mark recognition) to a PDF format?

"PDF file needs to be folded at the bottom of the letter" - is this some mechanical process or do you mean page break?  Anyways, I don't think you can trigger Javascript from a template/output to PDF.  You could of course have an external trigger for that, generate the PDF as normal from SAS, and then call a batch file which runs some javascript over the exported PDF to add this OMR.  It would be outside the scope of a SAS forum though, maybe have an empty PDF with the Javascript in it, then your output from SAS is merged with that to create a new file, and the command is triggered to add in at close?  Not sure really never heard of this, PDF is just and end destination for me.

Solution
‎06-17-2016 11:58 AM
SAS Super FREQ
Posts: 8,641

Re: How to add OMR (Optical mark recognition) to a PDF format?

[ Edited ]

Hi:
RW9 is correct -- the ODS PDF destination does NOT have a way to invoke JavaScript to alter the document. This is a very old user group paper that outlines reading OMR data with SAS, but not how to put the OMR into a PDF file -- http://www2.sas.com/proceedings/sugi26/p120-26.pdf

Then, this paper http://support.sas.com/resources/papers/proceedings13/099-2013.pdf also mentions OCR and OMR but in the context, again, of reading the data, not making the form or making the OMR in a file.

I believe that Adobe has something called a "Form Wizard" for making forms, that is not something you could interface to using ODS PDF.

cynthia

New Contributor
Posts: 4

Re: How to add OMR (Optical mark recognition) to a PDF format?

Hi...

 

Cynthis_sas and RW9 thank you for your time and answers.

 

Regards,

Rahul

 

 

Post a Question
Discussion Stats
  • 5 replies
  • 573 views
  • 0 likes
  • 3 in conversation