Unlock the power of Acrobat SDK through our community.
Nyligen aktiv
This is what I have so far however I do not know how to get the 35 and 45 in the statement.I am using Adobe Pro XI. This is my first time adding scripts to document for validation.event.rc = true;if (event.value.length != 12 && event.value != 'Must be 12 digits Select Prefix and enter Account number behind. cheq - 25 ushceq - 35 plan 24 - 45') { app.alert("The entered value must be 12 characters long and start with prefix cheq '25' or uscheq '35' or plan 24 '45'!"); event.rc = false; }var n = event.value.indexOf("25");if (n == -1) { // substring not found app.alert("The entered value must be 12 characters long and start with prefix cheq '25' or uscheq '35' or plan 24 '45'"); event.rc = false;}else { event.rc = true;
Hi,I am converting a document to a form and there is a ratings section with 6 categories where a rating of 1 to 5 is given. A read only field Total-Score calculates the ratings given for each category.However, one category Kitchen, is only required if it a kitchen is present. Thus, a radio button with Yes and No option is present and if Yes is selected, the Kitchen-Rating field goes from hidden to visible, allowing the user to enter a rating. Otherwise, if No is selected, the field remains hidden.How do I go create a custom calculation script to sum up these fields yet factor in the change of state of the Kitchen-Rating field, i.e. if hidden it is not included and if visible it is included? Below is my attempt to create the script but I receive the error message "SyntaxError: missing : after property id 3: at line 4".if (this.getField("Kitchen-Rating").display = display.visible);event.value = {this.getField("Bathroom-Rating").value + this.getField("Beds-Rating").value + this.getField("
Hi, I'm trying to use the code below to add a barcode to a document. The variable cRtn is set to '1234' by an earlier script. this.addWatermarkFromText({ cText: cRtn, nTextAlign:app.constants.align.center, cFont: "Free3of9", nFontSize:36, aColor: color.black, nStart: this.pageNum, nOpacity: 1.0});SyntaxError: syntax error1:Console:ExecundefinedI can add the barcode if I use the UI to add the barcode, but seem to have a problem if I call this from JavaScript. The console gives an error and nothing appears on the document. Any idea what's going wrong?
Hello,Is there a script to display only the last 4 of a string of numbers where the full number of numerical characters can very?Either display as "xxxx2298" or "2298". Or any other method.Thanks,Ed
I'm attempting to write a C++ function that will generate the following on a PDF page:A top bar that that has a solid line of color around it and inside a gradient that shades from white to this color top to bottom inside this bar.Place within the top bar an icon, some text and then some optional icons on the right hand side.Under the top bar have one or more lines of text with the color bars on the left and right hand side to match the width of the top bar.Between lines of text draw a black line.Below the last line of text have a color line to act as the bottom of the box.Does anybody know of sample code that does one or more bits of this?
HI all - apologies in advance, I'm a complete laymen when it comes to JS. I've searched high and low for the answer, but I worry that I don't know how to phrase the question to find the right answer.In short, I have a form that will have three figures manually entered into three different fields. A fourth box will run Adobe built-in code to sum three other fields. I then have a fifth text field. I'm having trouble with the fifth field. I want it to look at the sum total of the fourth field and depending on the value, return the words "Low", "Medium", or "High". From my first image below, you'll see this will then be repeated for "Simple", "Intermediate", and "Complex". Each half of this form will determine Seriousness and Complexity.I've only worked on the Seriousness side at this stage. If the value is 0-5, I want to return "Low", 6-10 "Medium", and 11+ "High". The second image is the script I've been trying to use. I've seen multiple variations of different ways, but none of them see
Not when opening a file, but when opening a program?
Hi All,I'm fairly new to javascript. I've been working my way up more complex combinations, but I can't seem to figure this one out. I'm trying to get the results of two sets of radio buttons to determine whether multiple fields are shown and which message comes up when clicking the submit button.If button 1 = yes and button 2 = yes, I need to show fields 3, 4, 5.If button 1 = yes and button 2 = no, I need to show field 6.If button 1 = no and button 2 = no, I don't show any fields.I've been at this all day and unable to write the script that works. PLEASE Help!
Is there any way using the Acrobat API to say search through a PDF, and find, the location within the document (say page number) of where any image shows up?I want to have a script where I can present to the user the areas of the document that contain images for review.
Good eveningI am wondering if there is a way to change text that the user puts in into "ERROR" if that said text is wrong.For more clarification, I am trying to make a script where, if the user puts in the code "Z85" in a field where it shouldn't be there, it'll change the "Z85" into "ERROR."
Good morning,I have to create a "checklist" for our office and would like to add a text frame with a onClick event behaviour. My idea is that after exporting as an interactive PDF file the user can click (or double-click, doesn't matter) on this specific frame and it shouldauto-complete this field with date and the windows login name. Is this possible and if yes, how can I do this?What I've got so far is this command--> alert($.getenv("USERNAME"));which returns the actual logged in user but I'm struggeling with the onClick event (javascript is not really my business)Thank you in advanceKind regardsMoritz
Hi,I'm developing a Plugin for Adobe Reader, where we (form a stand alone program) can read the selected text range aloud. The words are highlighted during read.The plugin can read now read and highlight selected body text.I want to extend the plugin so it would be able to read and highlight text in form fields. (where user can enter data).If I select text in a form field AVDocGetSelectionType return "AcroTextEditSelection". I cant' find any information about this selection type.Does anyone know how to get and highlight text in form fields?Thanks in advance.Carsten
Making a form which is 11 pages long on page 2 is Surname1 1st field Givenames1 2nd Field on page 11 I have a Name1 i want to combine the first 2 into the 3rd automatically. Really dont know what I am doing do I do script in the first 2 fields or just tell the 3rd field to look and enter info....thanks in advance
We save a lot of PDF files one a daily basis and we need to stamp on top of each document a section of the filename.The sample filename would be - 023 - PID 123456789 - ABC 1234567The PID and 9digit number after it will always be different, and needs to be stamped on each document. Is there a way for us to batch stamp each document and is there a code to section off just that part of the filename for maybe, a dynamic stamp. We only have Acrobat Reader DC.
Hey,I am trying to underline (or highlight) a text (few words) in a PDF using AppleScript. Can someone provide me with an example (script) for doing this?ThanksL.
I have a section of Yes/No radio dials. Each of these dials needs to equal a numerical value for calculating a score for example:Do you like the color red?-Yes (3 points)-No (3 points)Do you like ice cream?-Yes (1 point)-No (1 point)(Each question holds a different numerical value for calculating a score)The Yes and No radio dials equal the same number for each individual question; however, each question has its own value. I need to assign values to the Yes and No radio dials so that I can total them by their answers of Yes or No based on their assigned values.Is there any script to do this or is there a simple setting I'm missing to accomplish this? Thanks!
Hi All,I have a form we are giving to service guys in the field to fill out on a Galaxy Tablet.My goal is to have a button on the PDF that attaches the PDF to an email, makes it read-only, and names the document a combination of text from fields. I have done similar very simple things with PDF buttons for use on a desktop, but never on a tablet and not with these many items.Any ideas if this can actually be done and if so, some code examples?Thank You!Hunter
I've been refreshing/expanding my understanding of how to use the Acrobat Interapplication Communication OLE Automation in Powershell to work with PDFs.I'd appreciate any feedback on the following code, which I view as the basics of creating the App, PDDoc, and AVDoc COM objects needed to open, work with, and clean up after working with a PDF. Are there better/more efficient ways to accomplish the same end?(I had to paste the code in as an image because I didn't see a way to paste code in this editor.)ThanksChristian Bahnsen
Hello, I am trying to make a code, where the "check-spelling" feature will work on fully capitalised words, I was wondering if there was a script to insert into the document for this to work in any way?
i have a if loop to check some parameters :var A0 = this.getField("Dropdown14.0").valuevar A1 = this.getField("Dropdown14.1").valuevar A2 = this.getField("Dropdown14.2").valuevar A3 = this.getField("Dropdown14.3").valuevar A4 = this.getField("Dropdown14.4").value...var A500 = this.getField("Dropdown14.500").valueif (num1!=0 && A0=="check" && A1!="check" && A2!="check"... A500!="check")now the problem is A0 go to A500.....the only solution is to write A0=="check" && A1!="check" && A2!="check"....any smarter solution?
I used adobe acrobat pro to make a binder of duplicate forms and when open on my iPad using the reader app I can fill in the forms, but because the forms are all duplicates, all of the box names are the same, so each page comes out identical. I can't just rename the boxes because each form has over 200, and it would take forever since I have 10 of the forms in the binder. I tried creating a portfolio, which seems to have worked, but once i open it on the reader app, it says "modifying the document is not allowed because it is an attachment". Does anyone have a suggestion on how to either fix the binder so that all of the boxes are not named the same without manually changing the names individually, or a way to make the portfolio editable, and not viewed as an attachment?
i have 52 lines, and 52 text fields with some parameters.. and understand the code is not manageable... (so many writes) it is possible for a smarter solution ? if i use arrays? something else?var A0 = this.getField("Dropdown14.0").valuevar A1 = this.getField("Dropdown14.1").valuevar A2 = this.getField("Dropdown14.2").valuevar A3 = this.getField("Dropdown14.3").value...var A52 = this.getField("Dropdown14.52").valuevar J1 = this.getField("Text58").value var num = 0;var num1 = 0;var al = user;var als = users;...if (num!=0 && A0==" check" && A1!=" check" && A2!=" check" && A3!=" check" && A4!=" check" && A5!=" check" && A6!=" &
I have pdf's from scanned documents. Most pages have size A4 (210x297mm). 'Document Properties' > 'Initial View' > 'Page layout' is set to 'Two-up' (Cover page)', so that always 2 pages will be showed side by side, like reading a book. Now, few pages have the double size, A3 (297x410mm). Viewing them, 'Page layout' should switch to 'Single sided'. Going back or forward to an A4 page, 'Page layout' should switch back to 'Two-up'.The only method I found for achieving this, was by adding an action to each page of the document. The trigger is 'Open page', the action 'javascript'. Depending on the page size:this.layout = "TwoPageRight";this.layout = "SinglePage";My quesion: How can I add such (identical) actions with (identical) javascript snippets conveniently for page x to y ? I could not find any feature in preflight.
I am using Adobe Acrobat Pro DC on Windows. I am looking to create a form for my office that does the following:Checkboxes for each the given rolesWhen a box is checked, insert the related text field into the document showing the related training (all in an obnoxiously long default text), shifting all text fields downWhen a box is unchecked, remove the related text field from the document, and shift all the fields underneath it up (this is not removed like deleted, just removed from view and printing)I have gotten the fields to be hidden when I uncheck the box, and show when I check the box. That was easy enough. However, the text fields are just hidden (not showing), not removed from the document structure (which makes sense but is not what I am looking to do). Pretty much, I want the fields to move up and down and all around as the boxes are checked and unchecked. I am relatively new to PDF programming, but not to programming overall. In this vein, I would like some help getting this
I have a large PDF file that contains data for invoices. I'm using a pdf splitter, but it will only split based on the number of pages of the invoice, so each invoice must be the same number of pages. Is there a way to scan through the pdf, looking for a specific word then count how many pages there are in each invoice looking for the invoice with the most number of pages and then add blank pages to the invoices that don't have meet that maximum?
Remix with Firefly Community Gallery
Thousands of free creations to fall in love with and remix in Firefly.
Har redan ett konto? Logga in
Har du inget konto än? Skapa ett konto
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.