Unlock the power of Acrobat SDK through our community.
Récent
Hey my question is a bit of a mouth full.Trying to write a java script ( i believe this is the best way) for a button once clicked:Prints a water mark/ configures the header footer in all pdf pages after the first page. Button is on the first page of the pdf. The text for this water mark/ header footer, being dependent on 2 dropdown and a text boxE.gDropdown box called HSC, options are 1,2,3,41 selectedDropdown box called A/c options are 206,207,208,209,210,211,212,213211 selectedText box called reg, with the text "112/18"When the button is pressed the Watermark/header comes out as"HSC 1 A/c 211 reg 112/18"My understanding watermark is the best way to configure this.Any help will be greatfull.I am using Adobe Acrobat DC with all tools available.
I have a script that will split PDF files based on a set amount, so If I have a 1,000 page pdf, I have it split every 997 pages, I wish to modify it to split based on the actual size of the file.So if the file is 1,000 pages read it and split it too 2 seperate 500 page documents or if it's a 1,200 page document split it into 5, 300 page documents, so my end goal is too split it evenly if the file is larger than 1,000 pages.var re = /\.pdf$/i;var filename = this.documentFileName.replace(re,"");var n = 1;var nParts = Math.ceil(this.numPages/998); try {for (var i = 0; i < this.numPages; i+= 998){ var oNewDoc = this.extractPages({nStart: i,nEnd: (((i+997)>=this.numPages) ? this.numPages-1 : (i+997))});oNewDoc.newPage({nPage: 0});oNewDoc.addWatermarkFromText({cText: filename + "Part "+n + " of " + nParts,nStart: 0,nFontSize:36});oNewDoc.saveAs({cPath: "/K/Penta/Split/"+filename+"_" +"Pages_" + (i+1) + "-" + (((i+998)>=this.numPages) ? this.numPages : (
Hello,I work for a finance company that uses an uses a designated department for larger loan approval. There are multiple documents that are generated already as form pdfs or are hand written and scanned to a network drive. For a example the required documents that are to be sent are a: Coversheet(form pdf), Loan Scoring(hand written), Application (originally pdf, but printed and some hand written then scanned), and a credit report (pdf). All in that order. Right now, we currently print/hand write everything and scan it all back in to the network drive as one file and e-mail it. What I'm interested in doing is minimizing the printing and creating a button on the Coversheet that will allow me to import the have to be scanned items (which generate as pdfs) and the credit report, and output to a new file that has the forms flattened and the separate pdfs combined in order. ALL WITHIN ADOBE READER. Now I'm not fluent in JavaScript at all so I'm sure this is a tall order, and I wouldn't be
I have a regex which should find a string pattern of any of the following formats28.05.2018 SB RS CS 28-05-2018 SB RS CS 28/05/2018 SB RS CSThe regular expressions matches the first example with the full stops in the date, but does not match the second and third example with the dashes and forward slashes in the date.Can any one please advise how to correct the regular expression so that it matches a dash or a forward slash?Any assistance will be most appreciated.This is part of a script which matches the string and reports it back to the console.var ckWords4; // 4 words to testvar re = new RegExp(/\d{1,2}[/.-]\d{1,2}[/.-]\d{2,4}\s([A-Z]{2,5})\s([A-Z]{2,5})\s([A-Z]{2,5})/);var count; // count number of wordsnumWords = this.getPageNumWords(0); // number of words on page // loop through the words on page for (var j = 0; j < numWords-1; j++) { ckWords4 = this.getPageNthWord(0, j) + ' ' + this.getPageNthWord(0, j + 1) + ' ' + this.getPageNthWord(0, j + 2) + ' ' + this.getPag
Hi all, I can't seem to solve this problem. I am writing a C# desktop app that lets a user view a PDF file and then the user will have an option to delete that file.I first call the LoadFile("FileName") Function. My problem occurs when the user has finished deleting the file I can't figure out a way to clear the document from the AxAcroPDF object. It has been really bothering me. I need to figure out how to clear the document from the AxAcroPDF object. Could some one please help me out? Thanks In advance. -Adi
Hello all, I have several PDF documents that are over 1,000 pages in length and need to rearrange them from their default page order. Each page of the document has a name on it and each page must be placed into alphabetical order based on the name. I have already generated a work around script outside of Acrobat that will output the proper page order, what I am trying to do at this point is to get Acrobat to place the pages in order according to my generated list.Example of issue:I have a list of pages the document should be in (4,782, 43, 125, ect...) and need to have the document rearranged into that order. This involves moving every page of the document.Any help in this matter would be greatly appreciated, I'm an Acrobat noob.P.S. If there is also a way to get a script to generate the proper alphabetical order based on the name in Acrobat in addition to also placing the pages in the proper order would be great, that way we can keep it all in one application.
Adobe Reader DC is getting an error message when opening pdf files. "The Application was unable to start correctly (0xc00000a5). Click OK to close the application" Clicking OK allows the file to be opened normally, but I am still unable to save the file. I have uninstalled Adobe Reader DC with the fixit tool rebooted, and reinstalled multiple times, but always get the same error. I am using a Windows 7 64bit machine.
Hey all. I have been scouring forums all morning for an answer to this but keep coming up empty. First of all, I am still VERY novice at javascript in Acrobat, but here is the scenario:I have 5 required fields in my form. When I have a submit button that just uses the mouse up - submit form event, it will reject the submission if a required field is empty. However, I am submitting using javascript so that I can add text from one of the fields to the subject of the email that this is submitted by. The issue is when it is submitted this way, it no longer seems to validate the form to ensure the required fields are filled.Some addition context:The required fields are largely text and are as follows:repname (text)pneumonic (text)customer id (text)client name (text)Verification Method1 (drop down)If all of these are filled out then the form should allow submission. In a perfect world, if they click submit and any of the fields are empty I would love a pop up message that lets them know that
If there is some fields like the following, is there anyway (maybe using API or SDK) to get the position of the fields (for example left 47.52 pt, ...) and the name of the field (in this case Text1, Text2 and Text5)? I would like to export these information into a text document or XML.
Hii will searching Text object Containers for all the pages in the PDF Doc.The following code Demonstrates the above functionality.if (AVAppGetActiveDoc()){for (int i = iSPage; i <iEPage; i++){PDPage pdpage = PDDocAcquirePage(pdDoc, i);PDEContent pdeContent;CString rcsTag;pdeContent = PDPageAcquirePDEContent(pdpage, gExtensionID);PDEElement pdeElement;ASInt32 NumEle = PDEContentGetNumElems(pdeContent);for (NumEle = PDEContentGetNumElems(pdeContent) - 1; NumEle >= 0; NumEle--){pdeElement = PDEContentGetElem(pdeContent, NumEle);if (PDEObjectGetType((PDEObject)pdeElement) == kPDEContainer){ASAtom asaActualTag = PDEContainerGetMCTag((PDEContainer)pdeElement);LPCSTR csActualTagvalve = ASAtomGetString(asaActualTag);CString csActualTag = (CString)csActualTagvalve;if (csActualTag.Find(L"ACUTAHeader") != -1 || csActualTag.Find(L"ACUTAFooter") != -1){HeaderPresent = true;}}}PDPageReleasePDEContent(pdpage, gExtensionID);PDPageRelease(pdpage);}}After Searching completes, in Task manager Acro
Hi,I have no javascripting knowledge, is it possible to add an export .fdf javascript to a button in a pdf form?seems simple but i can't seem to find an example? ThanskAdamsski168
I have a text field created and when someone fills it out I want the degree symbol to show up after. For example, if someone enters the number 180 I want the degree symbol to show up so it looks like 180°. When I open up Text Field Properties > Format, which one do I use (Custom format script: or Custom keystroke Script" and what is the javascript code for this to occur?
When I click a button that I have placed on a form, I want the text in a text field already on the form to change to the text in a variable that I have created.Specifically what I am trying to do://creates my variablevar date = new Date();var components = [ date.getYear(), date.getMonth(), date.getDate(), date.getHours(), date.getMinutes(), date.getSeconds(), //date.getMilliseconds()];var id = components.join("");I then have a text field called "ID_Text"I thought I could just use the following, but it does not work.getField("ID_Text").value = id
What is the link to Acrobat JS reference guide? The one I had is broken.
Is it possible to run an action with a script (NOT execute a javascript inside the action, but run the action itself with a script)?
Hello everyone, I'm currently working for a company as an Intern and they asked me to create a custom form panel (basicaly a window that pops up when you call a javascript script) that should be filled with fields for the user to fill. Once those fields are filled i'm supposed to create and XML file from those fields.The problem is not about the XML file it's about creating the panel. Does anyone knows anything about it or is there any topic talking about it ? (I was not able to find any)Thanks for your time and have a nice day !
I'm going to add a dropdown that populates a text box in my custom dynamic stamp. I would then also like a way to go to the page in a PDF that contains specific stamp text without having to type that text into the search field every time, or scroll thru the document, or look thru the Page Thumbnails.Googled for a way to have a separate dropdown with the same values as the stamp dropdown, that searches the document for that stamp text, so far without success.I also looked for a way to programmatically create individual bookmarks named for the stamp dropdown values that are chosen, so far without success.Any ideas for the best way to do this please?Thank you.
I have a new credit card and need to change the credit card number & expiry date. I get to the right web page, but when I click on 'save', nothing happens. Can anyone help, please?
I've made countless attempts to change parenthesis, quotes, etc. and updated the entire script to match, but continue to get the same error in the same place. I need help from someone smarter than I am! Any thoughts?*Field1 has an export value of 1, 2, or 3.*Field2 is a number1 var v = this.getField("Field1").value;2 var l = this.getField("Field2");3 if ((v==1) && (l<21)) event.value = l;4 else if ((v==1) && (l>20)) event.value = (Math.ceil(l/2))+10;5 else if (v==2) && (l>0) && (l<5) event.value = (l-1);6 else if (v==2) && (l>4) && (l<9) event.value = (l-2);7 else if (v==2) && (l>8) && (l<13) event.value = (l-3);8 else if (v==2) && (l>12) && (l<17) event.value = (l-4);9 else if (v==2) && (l>16) && (l<21) event.value = (l-5);10 else if (v==2) && (l>20) event.value = (Math.ceil(l/2)
I will try with PDEText object to get Font Properties like Font name, font Size, Text and Text Color..Through PDEText I get Font size, Font name and Text color, But i couldn't get all words present in the PDF Page.Please Suggest me..How to get all Text information through PDWordFinder..Thanks...
I would appreciate any assistance regarding several questions I have about scripting for a particular form. I am NOT a coder (so please type slowly!). I am currently using Acrobat Pro 11.0.23 on Windows 10.Below is a screen shot of the planned form:INFORMATION ABOUT THE FORM:Need to be able to check off all that apply – for example a typical response might be POSITIVE for: Problem 1; Problem 5; Procedure 6; Procedure 10 and Option 10. (All of these POSITIVE). For Calculation of the “FINAL LEVEL” – this relies ONLY on the single HIGHEST Problem – or Procedure – or Management Option.In the case above – the Final Level would be HIGH because both Procedure 10 AND Option 10 were POSITIVE.The YES / NO field could be used to indicate that ANY of the responses at that particular level had been selected. (This is not completely necessary – but would make it easier
We have a Mileage Reimbursement form. I was tasked with figuring out how to automatically calculate the miles due. Below is what I did to make it calculate. Now the problem is that when someone puts in decimals it goes into some really long decimal. But it's only some of the decimals and it doesn't matter where on the column the decimal is put it will do it. Can some please tell me what I should do? Thnnk you!
Good Afternoon All Professional,Would need your professional information as below table i have create in adobe reader.the calculation of Total Hrs as below "3rd screenshot"what i want is as below:-3.15 change to 3.252.45 change to 2.755.30 change to 5.50the actual calculation is9:15pm = 21:15 hrs = 1260min + 15min = 1275min6:00pm = 18:00 hrs = 1080 min1275min - 1080min = 195 min195 / 60 = 3.25do any can give me a code to solve it?Many thanks for all of you.
Customer asked how to make it calculate. It was summing the hours up, but not adding it as time. I don't know much about this, customer created this on her own. We don't have anybody at our company that does this. There is some JavaScript code in there to do the calculation, but I have no idea how I know if there is a problem with it and how to make it work and calculate properly. Any help much appreciated! Thank you!Before I messed with it and added the last time to see if it was working and how, it has 6.9 in there to total up the top 3. I noticed there is just no code for the total field. All the other Total hours Fields had a section of that JavaScript code below, but the bottom Total hours for day didn't have JavaScript math in it which is why it's not working. The customer did have Sum selected which is why it was adding them wrong. I took that off, but I have no idea how to put a calculation in that field. I mean what the JavaScript Calculation should be. Hoping somebody could b
Hi,I'm assuming if this could be done it would be done with a Javascript.I'm working on a form and am trying to sum the totals entered into four different fields.Is this possible?
Remix with Firefly Community Gallery
Thousands of free creations to fall in love with and remix in Firefly.
Vous avez déjà un compte d'utilisateur ? Connexion
Pas encore de compte ? Créer un compte
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.