Acrobat SDK parameter definitions initialization locations
I just updated an old plug-in to work in the SDK 9 environment using Acrobat 9.1.3. It works great now. However, our user community is still using Acrobat 7. My plug-in won't load in an Acrobat 7 environment (Windows PC with Acrobat 7 installed on it). Which parameters control whether my plug-in will work with prior versions of Acrobat such as Acrobat 7? Or do I need to install Acrobat 7 on my PC with the Acrobat SDK 7?
As I've research this issue, I've found numerous C++ compiler parameters whose definitions are checked by various C++ header files. However, I don't know where those headers are initially set. For example, where is PI_ACROVIEW_VERSION initially set?
Thanks for the very quick response. I just found the header file that contains a lot of the definitions that may allow me to configure my plug-in to work in Acrobat 7 as well as Acrobat 9. The header file is PIRequir.h. Do any other header files need to be updated to define the SDK and Acrobat versions?
Along with my getting up to speed writing plug-ins for Acrobat, I am having trouble compiling my working plug-in ourside the Acrobat SDK 9 Sample plug-ins directory/project environment. I defined a new DLL Project using Visual Studio 2008 under the Visual Studio Projects directory but some C++ compiler parameters were not properly defined. I tried to set the project properties to be the same in the new project as it was under the Samples project (i.e., the BasicPlug-in defined as the startup project). But I'm getting some compile errors because certain parameters are apparently not set properly. Note that I used Visual Studio 2008 with the Acrobat SDK 9 but I converted the BasicPlug-in to be my new plug-in and it worked fine.
Anyway, if you know any secrets for setting up a new Acrobat plug-in in Visual Studio 2008 Visual C++ project to ensure that the C++ compiler parameters are set properly such as which the ones that need special attention in a newly defined project, that would be very helpful.
Similar Messages
-
Use parameter to define location of xml-file
Hi,
here is a question about importing data from a xml-file using the xfa.host.importdata
A tool we use generates a copy of a 'template'-pdf an put it into a unique folder. This unique folder will contain:
(1) a Batch-file
(2) a fillable, certified, reader-enabled pdf
(3) a xml-file containing data for the pdf
The batchfile will run a command 'start iexplore.exe file://C:/Doc.pdf?Address="C:/Doc.xml"
So, the Internet Explorer will be started, opens the local PDF and creates a parameter with the location of the xml-file.
So, now is my question how to make it work that in the DocReady-event the command xfa.host.importdata(); will be executed pointing to the xml-file. It should be like xfa.host.importdata("C:/Doc.xml");
If I put the command in the click-event of a button, it works fine, but I need help with setting up that command using the parameter.
Thank in advance!
ErikYou will not be able to automate using script the reading of a data file. This is deemed a security risk (as the user is not aware that this iis happening) and as such the user must pick the file.
There is another way though. There is an xml format supported by XFA forms called XML Data Package(XDP). This format keeps the data in teh same way as the xml file but allows a couple of goodies in it. Like the template that was used to create the file. If you open your PDF file and save the data out in that xdp format, then open the file in a text editor you will see a reference to the template that was used to load it. Now if you double click the xdp file then it will open the data file, find the reference to the template and merge the data and template together for you. This is not a security risk because the user casued teh data file to open. Note that this will not work on machines that have Designer on it because the XDP extension is registered with Designer and not Acrobat/Reader. If you change that association in Windows then it will work fine.
So my suggested solution is to make your data files xdp files and add the reference to the template that you want to use and have the user launch the xdp file and you shoudl be able to accomplish what you asked for.
Hope that helps
Paul -
How [Insert|Add] Image into Opening PDF file with Acrobat SDK.
Hi Guys,
I'm trying to insert|add image file into opening PDF file with specified location (X|Y) and scale (Width|Hight) but got many of troubles
If use third party like iTextSharp or something else thing become simple but i want to use Acrobat SDK to do this
Any suggestion or idea?
Any help appreciated.Thank for your interested.
I use VB.NET and Acrobat
Here is some my code:
Try
If File.Exists(T(0)) Then
Dim AcroAVDoc As AcroAVDoc = Ap.GetActiveDoc
Dim AcroPDDoc As AcroPDDoc = AcroAVDoc.GetPDDoc
Dim AcroPDPage As Acrobat.AcroPDPage = AcroPDDoc.AcquirePage(Integer.Parse(T(3)))
Dim data() As String = T(1).Split("^")
Dim imgX = data(0)
Dim imgY = data(1)
Dim imgWidth = data(3)
Dim imgHight = data(4)
'TODO: insert into opening PDF file
Return 1
End If
Catch ex As Exception
End Try
I don not know what to do next to insert an image (JPEG, PNG, ..) into PDF file.
Can you show me or suggest some solution, idea?
Thank in advance. -
Add Digital Signature Using C# and Acrobat SDK
Hi everybody!
Please, how can I digitally sign PDF documents using Acrobat Professional 8 API and C# language?
I know that I need use JavaScript APIs (IAC) but I can't find anything really helpful in the Acrobat SDK Documentation. Could anyone post a sample of how use javascript manipulation inside C# (Framework 2.0), or give me a direction?
Thank in advance!Hi Felipe,
when i am signing the document.
I believe i am missing something in my code. After executing the code to sign, when i open it i get "The following signature fields are not signed".
Please let me know where i m doing wrong?
Here is my VB.NET Code
Dim gapp As Acrobat.CAcroApp
Dim gpddoc As Acrobat.CAcroPDDoc
Dim jso As Object
gapp = CreateObject("acroexch.app")
gpddoc = CreateObject("acroexch.pddoc")
If gpddoc.Open("C:\Test1.pdf") Then
jso = gpddoc.GetJSObject()
jso.SetUserPassword("'testpassword12'")
'jso.ShowMyMessage("SetUserDigitalIDPath")
jso.SetUserDigitalIDPath("'c:\\DrTest.pfx'")
jso.app.execMenuItem("ADBESDK:AddSignature")
jso.AddSignature(jso)
gapp.Show()
and here is the javascript
// password to use the digital signature
var sigUserPwd = "UNKNOWN";
// to test the sample without user input, specify:
// var sigUserPwd = "testpassword";
// path to the digital signature file
var sigDigitalIDPath = "UNKNOWN";
// to test the sample without user input, specify:
//var sigDigitalIDPath = "/C/DrTest.pfx";
// other variables the user can modify
var sigHandlerName = "Adobe.PPKLite";
var sigFieldname = "sdkSignatureTest";
var sigReason = "I want to test my digital signature program.";
var sigLocation = "San Jose, CA";
var sigContactInfo = "[email protected]";
/* Add a menu item for AddSignature */
app.addMenuItem( { cName: "ADBESDK:AddSignature", cUser: "Add My Signature", cParent: "Advanced",
cEnable: "event.rc = (event.target != null);",
cExec: "AddSignature(event.target)" });
// main function
AddSignature=app.trustedFunction(function (doc)
app.beginPriv(); // explicitly raise privilege
// if sigDigitalIDPath is not spcified, ask for user input
if(sigDigitalIDPath == "UNKNOWN"){
var cResponse = app.response({
cQuestion: "Input your digital ID path:",
cTitle: "Digital Signature",
cDefault: "/C/DrTest.pfx",
if ( cResponse == null) {
app.alert("No input.");
return;
else
SetUserDigitalIDPath(cResponse);
// if sigUserPwd is not spcified, ask for user input
if(sigUserPwd == "UNKNOWN"){
var cResponse = app.response({
cQuestion: "Input your password:",
cTitle: "Digital Signature",
cDefault: "testpassword",
if ( cResponse == null) {
app.alert("No input.");
return
else
SetUserPassword(cResponse);
// create a new signature field
var signatureField = AddSignatureField(doc);
// sign it
if(signatureField) Sign(signatureField, sigHandlerName);
app.endPriv();
// create a signature field in the upper left conner with name of sigFieldname
function AddSignatureField(doc)
var inch=72;
var aRect = doc.getPageBox( {nPage: 0} );
aRect[0] += 0.5*inch; // from upper left hand corner of page.
aRect[2] = aRect[0]+2*inch; // Make it 2 inch wide
aRect[1] -= 0.5*inch;
aRect[3] = aRect[1] - 0.5*inch; // and 0.5 inch high
var sigField = null;
try {
sigField = doc.addField(sigFieldname, "signature", 0, aRect );
} catch (e) {
console.println("An error occurred: " + e);
return sigField;
// define the Sign function as a privileged function
Sign = app.trustedFunction (
function( sigField, DigSigHandlerName )
try {
app.beginPriv();
var myEngine = security.getHandler(DigSigHandlerName);
myEngine.login( sigUserPwd, sigDigitalIDPath);
sigField.signatureSign({oSig: myEngine,
bUI: false,
oInfo: { password: sigUserPwd,
reason: sigReason,
location: sigLocation,
contactInfo: sigContactInfo}
app.endPriv
} catch (e) {
console.println("An error occurred: " + e);
// set a correct password for using the signature, so you can quietly sign a doc.
function SetUserPassword(pwd)
sigUserPwd = pwd;
// set path to the digital signature file
function SetUserDigitalIDPath(idPath)
sigDigitalIDPath = idPath;
Sumit -
Hi,
sorry for this noob questions, I have just graduated, and have no experience with MFC or the Acrobat sdk.
I have tried for some while to get a dialogbox opened and have followed the plugin apps developer guide and this guide http://www.adobeforums.com/webx?128@@.3bc2c0c7 , but I get an error message, "Assertion failed", every time I try to initialize the window. I have managed to localize where it fails. I can't seem to get hold of the modal parent using:
AVDoc avDoc = AVAppGetActiveDoc();
hParent = WinAppGetModalParent(avDoc);
My question is, what am I doing wrong? :P
And is there an other way to get hold of the handle for the modal parent?
best regards
SimenThe plug-in should go in your Acrobat\plug_ins folder (If you have a default install of Acrobat, the full path would be C:\Program Files\Adobe\Acrobat 9.0\Acrobat\plug_ins, but this would depend entirely on your system).
You don't need to "open" a plug-in. Once you put it in the correct folder, Acrobat will automatically load it the next time Acrobat starts, as long as the plug-in is compatible with that version of Acrobat.
You should know that a plug-in written for Acrobat 6 is certainly not guaranteed to work with Acrobat 9 (and there is a good chance it may not). -
We have been using acrobat SDK for loading the reader.
We are using classes like CAcroApp,CAcroPDDoc,CAcroPDPage etc.
In CAcroPDPage::DrawEx(short nHWND, short nHDC, short nXOrigin, short nYOrigin, short nZoom), the second parameter is the HDC parameter.
We have tried passing the destination HDC to DrawEx, but it doesnt work.Drawing onto HWND only works and not the HDC param.
Is there any way out to this problem?Please guide.Post your question in the forum for Acrobat SDK.
-
How to convert html to pdf using acrobat sdk 8.0?
hi
I am a beginner of acrobat sdk .
I want to know How to use acrobat sdk 8.0 to convert html to pdf?
herere some questions :
1:How to support navigation inside PDF file that generated using acrobat sdk 8.0? For example: theres catalog in the top of HTML file, customer hopes can navigate inside the PDF file just like navigating inside the HTML file.
2:How to support operating some controls in the PDF file that generated using acrobat sdk 8.0? For example: therere some drop down list and text box in HTML file, customer hopes can input text in the text box, click the drop down list to see available options in it just like in HTML file.
Thanks in advance for any help and suggestion.Hello,
I want a system to re-brand my 37 pages PDF for affiliates.
I want a php dynamic link in the PDF online in order to personalize automatically the PDF for each affiliate. I need to change 2 links each time. The affiliate ID and the Paypal email (payment button) in page 36.
Can you help?
Please let me know
Thank you
Alex
PS My system is online and i can give you the url if it helps. -
How can I find out the screen size of the users moniter using the Acrobat SDK?
How can I find out the screen size of the users moniter using the Acrobat SDK? I need to know how much sreen real estate that is available on the users moniter. Is there some call that I can make from the SDK to discover the maximun X and Y coordinates?
Thanks,
GregoryCurrently, I am testing on multiple moniters and it is defaulting to the moniter designated as the #1 moniter. For our purposes, this is acceptable. Once the two documents have loaded, the user can move and re-size at will.
Gregory -
Plug in for visual studio 6.0 in acrobat sdk 6.0
Dear Friends,
I am absolutely in to the pdf plug in work. Can any one please help me, to know that how to install the plug in for visual studio 6.0.
I have installed acrobat sdk 6.0 , acrobat professional and visual studio 6.0 in my system.
Please suggest me whether I have to download any other tool for this.
Regards,
SafeeMy problem has resolved... still thank you...
I just follwed
You must install the wizard manually. Simply copy the AcrobatPluginWiz.awx and
AcrobatPluginWiz.hlp files from PluginSupport\Tools\Visual Studio App Wizard
subdirectory of the Acrobat 6.0 SDK installation to the Common\MSDev98\Template\
subdirectory of the Visual Studio 6.0 installation. The default path to copy from is
C:\Program Files\Adobe\Acrobat 6.0 SDK\PluginSupport\Tools\Visual Studio App Wizard
and the default path to copy to is C:\Program Files\Microsoft Visual
Studio\Common\MSDev98\Template.
Once the files are copied, the Acrobat 6.0 Plugin Wizard option will now be available in the
File > New > Projects dialog. -
How to use Acrobat SDK with C# and how much is it?
I just want to know these info because I'm new here and I can't seem to find any answers to these here in the forums and on the Documentation.
Hi,
The Acrobat SDK is free and can be downloaded from http://www.adobe.com\devnet\acrobat. Please note to use the SDK you require Acrobat/Reader to be installed.
As for using it with c#, there are a number of sample files in the SDK that can be used to learn. There is also documentation online and in the SDK.
Hope thie helps
Malcolm -
Adobe Acrobat 9 Updater Preference File Location
What is the default Adobe Acrobat 9 Updater Preference File Location setting when you click on Help > Check for Updates?
Windows XP
C:\Documents and Settings\<current user>\Local Settings\Application Data\Adobe\Updater6\
Windows Vista
\\Users\<current user>[AppData]\Local\Adobe\Updater6\
Windows 7
C:\Users\<current user>[AppData]\Local\Adobe\Updater6\
Mac
"/Users/<current user>/Library/Application Support/Adobe/Updater6/"
AdobeUpdaterPrefs.dat -
Merging PDF / Page Numbers / Acrobat SDK V9 & LiveCycle
Hello everyone,
I use Adobe LiveCycle to create forms, Visual Studio 2005 and the Acrobat SDK for the application I'm programming to fill in these forms. The application fills in the forms and merges them with no issues.
The problem I have is that these pages have page numbers in the upper right. I use the Page N of M object on these forms in LiveCycle. PDF page numbers are filled in correctly when filling in the forms, but when I merge PDFs, the pages keep their original page numbers. I've looked at the Windows - Interapplication Communications even using templates to no avail.
How can I merge these pdf's and have my program renumber these pages correctly and how can insert pages anywhere I want in the merge document?
Below is the code I use to merge the PDF's. It was posted in a forum.
Sub MergePDF(ByVal ThePath As String, ByVal outFileName As String)
On Error GoTo serror
Dim dPDDocMerge As New Acrobat.AcroPDDoc
Dim dPDDoc As New Acrobat.AcroPDDoc
Dim strFiles() As String
Dim numPage As Integer
Dim TotalPage As Integer
Dim objThisFile As IO.FileInfo 'get FileInfo object for file string
strFiles = System.IO.Directory.GetFiles(ThePath) ' Read in the file names
Dim b As Boolean ' mostly for testing purposes... could use it for error 'checking to make sure that a file is really added before deleleting it...
For i As Integer = 0 To strFiles.Length - 1 ' run through all the files in 'the directory
objThisFile = New IO.FileInfo(strFiles(i)) ' Get the extension
If objThisFile.Extension = ".pdf" Then ' Only add in PDFs
If dPDDocMerge.GetFileName = "" Then ' check if it's the first file
dPDDocMerge = New Acrobat.AcroPDDoc
b = dPDDocMerge.Open(strFiles(i)) ' open first file
TotalPage = dPDDocMerge.GetNumPages
Else
dPDDoc = New Acrobat.AcroPDDoc
b = dPDDoc.Open(strFiles(i)) ' open other files
numPage = dPDDocMerge.GetNumPages ' get the page count
TotalPage += numPage
b = dPDDocMerge.InsertPages(numPage - 1, dPDDoc, 0, dPDDoc.GetNumPages, _ False) ' Insert
End If
End If
Next
'b = dPDDocMerge.Save(1, ThePath & "\" & outFileName) ' save file
b = dPDDocMerge.Save(1, ThePath & "\" & "\MyTest.PDF") ' save file
b = dPDDocMerge.Close()
Exit Sub
serror:
MsgBox(ErrorToString)
End Sub
Thanks for any code or advice.You can't merge LiveCycle forms this way :(. LC forms are NOT standard PDF files and can't be processed in the same way.
-
Create pdf using Adobe acrobat sdk
Hello,
I'm new to this concept of using adobe sdk to convert a html into pdf.I would like to know few details regarding this..
I went thorugh the documentation but I did not get any help about the vector image support in the pdf and I aslo want to know abot the dpi support in the pdf.
I also want to know wether I can create a pdf form a Html page.
thanks for the help.>I want this to be on the server.
Ok, we can start there - or stop. The Acrobat SDK is for automating
Acrobat. Acrobat must not be installed on a server. So you cannot use
Acrobat.
Adobe have a PDF Library, which can be licensed for server use. But it
does not have any easy HTML to PDF converter.
You might look into LiveCycle PDF Generator, a different application
with a Java API and more, for server use.
>The dpi what I was talking about was..in the pdf i want a logo to appear that would around 200-300 dpi.That logo is a vector image.
This seems a contradiction. PDF files can store text, vector images
and bitmaps/images. If you store a vector image, it remains vector and
there is no dpi to worry about.
HOWEVER if you can only convert HTML
1. HTML does not support any vector formats
2. HTML often forces images to 72 dpi.
HTML is not suitable for print quality.
Aandi Inston -
AcroExch - Acrobat SDK 9.0
Hi,
I have a copy of Adobe Acrobat 9 pro installed along with the SDK. I can run the BasicIACVB example and have used the sample to find text in the pdf, however I am having issues pulling the actual page number that the text is found on.
I am using the ACROBAT.CACROAVPAGEVIEW object.
Dim gAVPage as Acrobat.CAcroAVPageView
gAvPage = CreateObject("AcroExch.CAcroAVPageView")
I get an error stating "Cannot create ActiveX component." on the second line, the CreateObject line.
I can create an object of AcroExch.AVDoc just fine without errors.
Any Suggestions would be greatly appreciated. Oh, I am developing in VB.net 2005 on a Windows XP Pro Box.
Thanks!
JTYou should post in the Acrobat SDK forum.
-
How to Use Acrobat SDK for Automation Using VB or Perl
Hi Forum,
I am a new bie, just 2 days old to acrobat and javascript, and I am basically a perl developer
I am using Adobe Acrobat 9 Pro,
I downloaded Acrobat SDK, but i don't know what else to do further, how to use??
I tried to start learning SDK, but no proper documents i found to learn and start using SDK,
Please suggest some guide or documentation for start learning Acrobat SDK (Step by Step guide)
Here with I have created a small script to merge two pdf
// Create a new PDF document:
var newDoc = app.newDoc();
// Insert doc1.pdf:
newDoc.insertPages({
nPage : -1,
cPath : "/d/sathish/1.pdf",
// Insert doc2.pdf:
newDoc.insertPages({
nPage : newDoc.numPages-1,
cPath : "/d/sathish/2.pdf",
// Save the new document:
newDoc.saveAs("/d/sathish/myNewDoc.pdf");
My code is working fine and merging properly,
Is there any way to execute this script through commandline or using some other scripting languages like perl or through VB
My objective is to automate the merging process without any manual intervention, I don't want to open acrobat manually to execute this javacript, i want to automate that process too,
Please suggest me which will be very helpful to me,
Thanks in advance
Thanks & Regards
Sathish V.It is a big SDK and to learn its features requires a lot of reading. But to start with I guess I should start with "Introduction to SDK".
Since you want to control Acrobat from another application you should consider this under "Interapplication communication". You will be using OLE/COM.
Maybe you are looking for
-
ITunes 1.6 and Windows Vista 64bit Help
I have not been able to use iTunes properly since I got a new computer with Vista 64bit. I can play music, browse iTunes Store and watch Video, but the problem comes when I try to attach my iPod Touch or try burning a CD. With the last version, it se
-
Mail 4.1,not playing "new message" sound, and some sent mail not in outBox
For some reason, no "new message" sound is being played (has been like this for a few weeks), and some (~1/10) sent mail does not show up in the sent box (been like this for a long time). And yes, preferences are set to "play new messages sound" Any
-
Aperture thinks "Images Offline"
After installing Leopard and a second hard drive, Aperture thinks some of my projects are "Offline". I did not rename, or edit my reference files outside of Aperture. The only thing that has changed was adding a second hard drive and installing Leopa
-
We have a scenario triggering MATMAS Idocs to other systems. Change pointers activated. So Matmas Sent from system A to B and A to C. in System B then can change some thing which comes back to A as Inbound Idoc and will be posted to System A. this tr
-
Not exactly sure what happened but system no longer works. Removed HDD and appears it failed so I recovered what I could with recovery software and purchased a new HDD. I was able to recover the recovery partition and have set up the new HDD with t