Add a button to print with Java Script to print different Pages differently
Hello
I'm doing a form and most is done and now I want to be able to print two pages but on different printers, I have one that must be printed on a standard A4 printer and another who needs to go to a label printer. I have two names for printers and I tried something, but he just never did anything (this is suggested by adobe I think?)
pp var = this.getPRintParam ();
var printamount = this.getValue ("Quantity_Boxes");
pp.printerName = "Zebra ZTC GK420t Technologies";
pp.firstPage = 3;
pp.lastPage = 3;
pp. NumCopies = 2 * printamount;
This.Print ();
I tried without the first and last page and nothing happens, I use a shared printer that works when I do cmd + P, which is the name of the printer complete iMac of Zebra Technologies ZTC GK420t @ user. (I tried also to put the full name in aswell)
This is just to test a page so far but there at - there no way that a single button will be able to print 2 different pages for 2 different printers?
If anyone knows how this would be a great help!
Thank you
Bruce
TSN's right. You've also used a nonexistent function (getValue), and this one is misspelled (it should be getPrintParams)... Where did you get this code?
Tags: Acrobat
Similar Questions
-
Hi, I'm doing a site with dream weaver cs5. I am instituting a slider, this cursor uses java script coding, I'm not familiar with Java script. Here is the site that I have problems with. Www.bussmanncomputers.net/Jara.
What said Teodor, the jQuery library is not found as can be demonstrated when we follow him - http://www.bussmanncomputers.net/Jara/js/jquery.js - link you have placed in your document online.
The only reason why there is a 404 error is because the file is not in the specified location, it has not been downloaded to the location of i.o.w..
-
invoke the button action or a java script page
Hello
I wanted to call a java script button action. I created a button associated with a request. The button action should redirect to an existing page. I did the hidden button. I would like to call a java script function button. Can someone point me to a thread with the syntax which handles this.
Or is it possible to directly call a function of java script to a page?
Thank you
-vkantVkant
In a javascript function, you can set the property from 'rental' of the window object to point to the APEX page as in the example below. How you call this function from the Applet javascript I don't know.
function goToPage(pageno) { var str="f?p=101:" + pageno + ":&SESSION." // 101 is the APEX application id window.location=str; }
See here for APEX URL syntax http://download.oracle.com/docs/cd/E14373_01/appdev.32/e11838/concept.htm#sthref185
CITY
-
Problem with Java Script in my mail service
I'm unable to access my email GMX account. Whenever I try, a rose windows opens at the top indicating that Java Script is required. However, when I check with the tolls, the enable JavaScript box is checked. I've deleted and reinstalled Firefox 10.0.1 two times with the same results. I can to my account via Internet Explorer and Safari without difficulty.
Any ideas?
Due to various difficulties, I reinstalled Windows 7. That solved the problem
-
Hello
I created a form that contains a few simple calculations at the bottom. I have zero experience java script so any help is appreciated.
The way the script is written right now gives me the error "the value entered does not match the format of the [Total] field.
This is out of pocket expense claim form and I'm trying to have it display the total is due to the employee in the [Total] line. The form must take everything that is entered in the 'calculate.0; Calculate.1... "and multiply that number by 0.55 which is the rate for reimbursement of mileage. In the areas of 'numbers', the user will be able to enter the amounts for other expenses such as tolls and parking.
The line [Total] must take each of the fields 'calculate' and multiply by 0.55, then add this total to values "numbers."
Help, please!
Thank you!!!
(This.getField("calculate.0").value) = Event.Value * 0.55 +.
(this.getField("calculate.1").value) * 0.55 +.
(this.getField("calculate.2").value) * 0.55 +.
(this.getField("calculate.3").value) * 0.55 +.
(this.getField("calculate.4").value) * 0.55 +.
(this.getField("calculate.5").value) * 0.55 +.
(this.getField("calculate.6").value) * 0.55 +.
(this.getField("calculate.8").value) * 0.55 +.
(this.getField("calculate.9").value) * 0.55 +.
(this.getField("calculate.10").value) * 0.55 +.
(this.getField("calculate.11").value) * 0.55 +.
(this.getField("calculate.12").value) * 0.55 +.
(this.getField("calculate.13").value) * 0.55 +.
parseInt (this.getField("numbers.0").value) +.
parseInt (this.getField("numbers.0.0").value) +.
parseInt (this.getField("numbers.0.1").value) +.
parseInt (this.getField("numbers.0.1.0").value) +.
parseInt (this.getField("numbers.0.1.0.0").value) +.
parseInt (this.getField("numbers.0.1.0.1").value) +.
parseInt (this.getField("numbers.0.1.0.1.2").value) +.
parseInt (this.getField("numbers.0.1.0.1.3").value) +.
parseInt (this.getField("numbers.0.1.0.1.4").value) +.
parseInt (this.getField("numbers.0.1.0.1.5").value) +.
parseInt (this.getField("numbers.0.1.0.1.6").value) +.
parseInt (this.getField("numbers.0.1.0.1.7").value) +.
parseInt (this.getField("numbers.0.1.0.1.8").value) +.
parseInt (this.getField("numbers.0.1.0.1.9").value) +.
parseInt (this.getField("numbers.0.1.0.1.10").value);
This is because there is difference between 'Number as text' and 'numbers '. JavaScript uses the same operator '+', for the addition and concatenation. You must ensure that you have access to a certain number. You and use the constrictor 'Number' or the multiplicative identity. JavaScript has also tries to guess the action to use.
Event.Value = (this.getField("calculate.0").value * 0.55) +.
(this.getField("calculate.1").value * 0.55) +.
(this.getField("calculate.2").value * 0.55) +.
(this.getField("calculate.3").value * 0.55) +.
(this.getField("calculate.4").value * 0.55) +.
(this.getField("calculate.5").value * 0.55) +.
(this.getField("calculate.6").value) * 0.55 +.
(this.getField("calculate.8").value * 0.55) +.
(this.getField("calculate.9").value * 0.55) +.
(this.getField("calculate.10").value * 0.55) +.
(this.getField("calculate.11").value * 0.55) +.
(this.getField("calculate.12").value * 0.55) +.
(this.getField("calculate.13").value * 0.55) +.
Number (this.getField("Numbers.0").value).
Number (this.getField("Numbers.0.0").value).
Number (his.getField("Numbers.0.1").value).
Number (this.getField("Numbers.0.1.0").value).
Number (this.getField("Numbers.0.1.0.0").value).
Number (this.getField("Numbers.0.1.0.1").value).
Number (this.getField("Numbers.0.1.0.1.2").value).
Number (this.getField("Numbers.0.1.0.1.3").value).
Number (this.getField("Numbers.0.1.0.1.4").value).
(1 * this.getField("numbers.0.1.0.1.5").value) +.
(1 * this.getField("numbers.0.1.0.1.6").value) +.
(1 * this.getField("numbers.0.1.0.1.7").value) +.
(1 * this.getField("numbers.0.1.0.1.8").value) +.
(1 * this.getField("numbers.0.1.0.1.9").value) +.
(1 * this.getField("numbers.0.1.0.1.10").value);
-
How can I link to pages in a selection tree / index level 2 with java script popup?
I can do something unique popup level using the java script below (#1) and selections link to pages but to change a tree of selection index popup level 2 as below (#2), I can't seem to understand how to link to the pages. Any help much appreciated. Thank you
1
var itemIndex = app.popUpMenu("INTRODUCTION", "ALPHABET", "GRAMMAR", "NUMBERS", "DATES & TIME", "GETTING TO KNOW PEOPLE", "PHRASES FOR LEARNING", "DIRECTIONS & TRANSPORTATION", "DESCRIBING THE TRAIL", "DO'S & DON'TS", "EQUIPMENT", "FOOD", "INTRODUCING A VILLAGE", "CULTURE AND ETHNIC GROUPS", "HANDICRAFTS", "TEMPLES & MONKS", "AGRICULTURE", "ANIMAL HUSBANDRY", "SCHOOL & EDUCATION", "LEADING A TREK", "NATIONAL PROTECTED AREAS", "IDENTIFYING WILDLIFE", "PLANTS & FORESTS", "BOATS", "CAVES ", "HEALTH AND SAFETY"() "
switch (itemIndex) {
case 'INTRODUCTION' :
this.pageNum = 1
breaking
case "ALPHABET" :
this.pageNum = 2
breaking
case 'GRAMMAR' :
this.pageNum = 5
breaking
case "NUMBERS" :
this.pageNum = 30
breaking
case 'DATE & TIME' :
this.pageNum = 35
breaking
case "GET to KNOW the PEOPLE" :
this.pageNum = 42
breaking
case "PHRASES FOR LEARNING" :
this.pageNum = 56
breaking
case 'DIRECTIONS & TRANSPORT' :
this.pageNum = 59
breaking
case "DESCRIBING THE TRAIL" :
this.pageNum = 63
breaking
case 'Things to do and not to do' :
this.pageNum = 68
breaking
case "EQUIPMENT" :
this.pageNum = 74
breaking
case 'FOOD' :
this.pageNum = 83
breaking
case "INTRODUCE a VILLAGE" :
this.pageNum = 96
breaking
case 'CULTURE AND ETHNIC GROUPS' :
this.pageNum = 105
breaking
case "CRAFTS" :
this.pageNum = 120
breaking
case "The TEMPLES and the MONKS" :
this.pageNum = 126
breaking
case 'AGRICULTURE' :
this.pageNum = 131
breaking
case "FARMING" :
this.pageNum = 140
breaking
case "SCHOOL & EDUCATION" :
this.pageNum = 145
breaking
case "LEADING a TREK" :
this.pageNum = 151
breaking
case 'NATIONAL PROTECTED AREAS' :
this.pageNum = 155
breaking
case "IDENTIFICATION of WILDLIFE" :
this.pageNum = 161
breaking
case "PLANTS & FOREST" :
this.pageNum = 169
breaking
case 'BOATS' :
this.pageNum = 175
breaking
case "CELLARS" :
this.pageNum = 178
breaking
case 'HEALTH AND SAFETY' :
this.pageNum = 182
breaking
}
2
var aINTRODUCTION = ['INTRODUCTION', 'How to use this book', 'Format'];
var aALPHABET is ["ALPHABET", 'Vowels', 'Sounds consonants'];.
var itemIndex = app.popUpMenu (aINTRODUCTION aALPHABET);
Thank you.
It works exactly the same... itemIndex will bear the name of the selected
order of the day.
-
Here's my problem:
I have a field that populate a 18 digit number.
I need a java script that will fill only the last 4 digits of the 18-digit number in a separte field.
Then F1 = 18 pre-filled numbers
F2 = last 4 F1
Can anyone help?
Thanks in advance for any help!
Use what the calculation script customized for F2:
var F1 = this.getField("F1").valueAsString;
Event.Value = f1.substring(f1.length-4);
-
I need help with Java Script if/then statement
I have absolutily no experience writing Java Script any help at all would be appreciated.
I am working on a form in which I need a box for the person filling out the form click if they are a company be exempt from taxes. Well, obviously when they check the box I need field sales tax to change $ 0.00 total cost will only be calculated on the price of the items.
Currently I use steps in the field of calculation for my Salestax.
var k = this.getField ("SubTotal");
K.value = Event.Value * 0.0825;
Yet once, all possible assistance would be greatly appreciated.
Tiffany
Let's say the name of the box is "IsTaxExempt". Then you can use this code as the field of Salestax calcluation:
If (this.getField("IsTaxExempt").value == "Off") {}
var k = this.getField ("SubTotal");
K.value = Event.Value * 0.0825;
} else event.value = 0;
-
Need help with Java Script to perform a calculation in the form of Adobe Acrobat Pro 9
I have a form (test) I created in Adobe Acrobat 9 Pro.
I need help to create a custom JavaScript, so I can get the desired response.
1) there are several questions in each group requiring a numeric response between 0-4
2) there is a total set up field to calculate the sum of the responses of all of the above questions
(3) the final "score" takes the answer in step 2 above and divide by the total possible response
Any help to what Java Script I need to fill it would be greatly appreciated!
I have attached a spreadsheet "" which shows more in detail as are the result of what I used in Excel to get the desired end formulas.
Thanks in advance.
Have you tried the "field is the average of:"?
-
Button to "print this Page on a printer of your choice.
I need to create a button to allow my user to print their current page to a printer of their choice.
Make them go to file print, etc. etc. is not an option because it will be used by hundreds of people and the pdf file is hundreds of pages long. (just select 'Print', if a lot of wasted paper)Ive been able to locate a Javascript that prints to the default printer, but my users change several times a day, the computers and the default printer could find across town!
Here is the script for 'Print this page for the default printer' if anyone can help by changing to choose which printer, which would be amazing...
JavaScript:
This.Print (this.pageNum, false, this.pageNum);It would similarly create a button to open the dialog box print with "Current Page" have been screened in.
It's very strange. Try this:
This.Print (this.pageNum, this.pageNum, true);
It will not select the current Page (which is not possible) option button, but it will fill the page range with just the current page number.
-
How to add a BUTTON in the form of a report in report Page last column
Hi friends,
I created a form with Page report. Now, I want to ADD a button in the last column named Add in the last column of the Report.that would be a new column added to the report.
How can I add a button to the form with Page report in the report and tell me how PK as ORDER_ID of a particular LINE with this button to add a reference ELEMENT.
When I click on the button Add ELEMENT, then command to go to the next Page with ORDER_ID.
How can I do that.
Thank youHello
Modify your report and click the report attributes. On the right under 'Tasks' is "Add the link in the column" - click that. This creates a new column. Scroll down to the links section of this new column and add in the following:
Link text: Add article
Target: Page in the present application
Page: (enter the number of the form page)
Clear the Cache: (enter the number of the form page)
Point 1 (name): (enter or select the name of the element of the form for the primary key page - for example, P2_ORDER_ID)
Point 1 (value): (enter or select #ORDER_ID #-which should be the ORDER_ID column on the table for the report)Click on apply changes to save and run the report
This creates a normal hyperlink in the column - each line will have a different value of ORDER_ID, so every link will be slightly different. If you want to make the link look like a button, you can do it with style if necessary
Andy
-
I have a small script that changes the color of a button image that I use for a popup topic. It does this, of course, by exchanging the two images.
The script works very well in HR overview and also when the htm page is opened directly in a browser (IE or Chrome).
However, when I open the topic in the compiled help, the second image does not display.
Those who work in HR overview. Who isn't in the compiled help.
Here is the code:
< a href = "javascript:BSSCPopup('..)". /MenuLocations/3DFace_menu_location.htm'); »
"ID ="a1"style =" "position: relative;" > < img onmouseover = "this.src = '... /ClickButton - O.png'.
onmouseout = "" This.src = '... ClickButton.png' ""
"SRC ="... / clickbutton.png ".
ALT = "Click for locations of menu and toolbar and related topics."
border = "0" / >
Any ideas?
~ Margaret Becker
HI Margaret
You should probably add the second image to luggage to its intended location. Because JavaScript must manage by exchanging images, RoboHelp is probably not aware of the second image.
See you soon... Rick
Useful and practical links
Wish to RoboHelp form/Bug report form
Begin to learn RoboHelp HTML 7, 8 or 9 in the day!
-
ADF page with java script disabled in the browser?
Can a web page developed by ADF with Jdeveloper render in the browser with JavaScript disabled? It does not fror me. Is there an alternative? Please answer.Raphael is exact - ADF Faces requires JavaScript.
John
-
Need help with java script date
Hi all
Using Mac OS 10.6.8 and Adobe Acrobat 9.
I am working on a form that has course date when you open the form.
I have a field to enter an earlier date.
If the effective date is = to or more than 3 years old (1095 days), then it will show a hidden field "sorry your registration has expired.
If date enered is less than 3 years, then the field remains hidden.
I have a field to display the result in days, I'm going to hide once the script works.
Here is the shape right now.
www.nixmailmac.com/register.PDF
Any help would be appreciated.
Ron has
The code that I provided above is a compacted to if-then-else way. If you really want to, you can use this instead:
If (event.value< 1095)="">
getField("Enter_Field_Name_Here").display = display.hidden;
} else {}
getField("Enter_Field_Name_Here").display = display.visible;
}
-
Cannot watch videos on Web sites
Maybe you are looking for
-
Possible HP Pav p6-2007nl Desktop PC - USB 3.0?
Hello. I would like to know if I can do USB3.0 slot available on my HP Pav p6-2007nl desktop PC. I've read elsewhere that some PCI for USB3.0 card there wouldn't fit physically this desktop computer many years ago. I'm not very knowledgeable on the c
-
How to download and install on another computer without internet connection?
I have an old computer with windows XP Home Edition. How to download and install on another computer without internet connection? Files such as DirectX, real player, Media Player. What I find it just download and install the file must then go to th
-
Why my computer does not freeze if online or offline?
I can play solitaire and it will freeze in the middle of the game. I'll be in my email address and it will freeze. I can be offline and going through my photos and it will freeze up.i can be watching a tube in u online and it will freeze. Using anyth
-
Windows mail using vista I have to login every time I open windows mail how to stop that
I get a pop up that says: enter your user name and password I also tick the box that say they remember me, but I still have to connect whenever I have open windows mail
-
Hello. I have an Acer Aspire under Vista 64-bit desktop. I have an error message when I try to export photos from Adobe Lightroom on my zenfolio online gallery. The error message reads: "Lightroom can't access the internet. Please check your fire