Step 1: To install the PDF Viewer SDK ActiveX, begin by launching the setup file (http://www.viscomsoft.com/demo/imageviewercpprosetup.exe). Select the desired installation folder for the PDF Viewer SDK ActiveX and continue with the installation on your development computer.

}
Step 7: Now you will see the PDF Viewer ActiveX Control, drag it on form.

Step 8: Create the UI as the following

Step 9: In form init event, add the following code
thisform.cbostampicon.AddItem("Approved")
thisform.cbostampicon.AddItem("Asls")
thisform.cbostampicon.AddItem("Confidential")
thisform.cbostampicon.AddItem("Departmental")
thisform.cbostampicon.AddItem("Draft")
thisform.cbostampicon.AddItem("Experimental")
thisform.cbostampicon.AddItem("Expired")
thisform.cbostampicon.AddItem("Final")
thisform.cbostampicon.AddItem("ForComment")
thisform.cbostampicon.AddItem("ForPublicRelease")
thisform.cbostampicon.AddItem("NotApproved")
thisform.cbostampicon.AddItem("NotForPublicRelease")
thisform.cbostampicon.AddItem("Sold")
thisform.cbostampicon.AddItem("TopSecret")
thisform.cbostampicon.ListIndex = 1
thisform.cbostampcolor.AddItem("transparent")
thisform.cbostampcolor.AddItem("aqua")
thisform.cbostampcolor.AddItem("black")
thisform.cbostampcolor.AddItem("blue")
thisform.cbostampcolor.AddItem("fuchsia")
thisform.cbostampcolor.AddItem("gray")
thisform.cbostampcolor.AddItem("green")
thisform.cbostampcolor.AddItem("lime")
thisform.cbostampcolor.AddItem("maroon")
thisform.cbostampcolor.AddItem("navy")
thisform.cbostampcolor.AddItem("olive")
thisform.cbostampcolor.AddItem("orange")
thisform.cbostampcolor.AddItem("purple")
thisform.cbostampcolor.AddItem("red")
thisform.cbostampcolor.AddItem("silver")
thisform.cbostampcolor.AddItem("teal")
thisform.cbostampcolor.AddItem("white")
thisform.cbostampcolor.AddItem("yellow")
thisform.cbostampcolor.ListIndex = 4
Step 10: In Open PDF button click event, add the following code
strfile = GETFILE('pdf', 'Browse PDF file', 'Browse', 1, 'Select PDF file ')
thisform.pdfviewer.LoadPDFFile (strfile)
thisform.pdfviewer.PDFClearStamp
Step 11: In Add PDF Stamp button click event, add the following code
thisform.pdfviewer.PDFAddStamp(1, thisform.cbostampicon.ListIndex-1, thisform.txtleft.Value, thisform.txttop.value, thisform.txtwidth.value, thisform.txtheight.Value, thisform.cbostampcolor.ListIndex-1, ALLTRIM(thisform.txtstamptext.Text))
Step 12: In Save PDF button click event, add the following code
strOutputFile=GETFILE('pdf', 'Output PDF file', 'Browse', 1, 'Select')
bResult =thisform.pdfviewer.savePDF (strOutputFile)
IF bResult then
=MESSAGEBOX("Save PDF Completed")