If you select from the dropdown (payperiods list) say for instance payperiod 15: 7/5/2009 - 7/18/2009, the prepopulated payperiod fields will appears as e.g. 7/5 - I would like for it to show as Sunday - July 5 instead of 7/5 in the textfield.
Thanks in advance
Views
Replies
Total Likes
There are no functions in Javascript that will return to you the day of the week and the month in words. They will return a value that represents the days of th eweek 0 for Sunday, 1 for Monday etc... The same is true for the month. I have coded a large if condition to determine the daty and you can do the same for the month. You might find it easier to use a Switch statement but you wil have to turn the coded month into the appropraite word to get what you want.
See my attached sample. The code is on the exit event of the dropdown.
Paul
Views
Replies
Total Likes
Try to make use of printd and scand methods available in Util object..
I ve attached a JS guide. This should help you.
PS: See page 264 of the attachment
Nith
Views
Replies
Total Likes
Thanks $Nith$ !
Views
Replies
Total Likes
Hi Nith,
I have a requirment to create a button called "Index" in a pdf.
When I click on that button it should show the popup menu and if I click any of the menuitem in that, it should take me to that particular page. I saw some of the interactive pdf's has this and I tried to incorporate this into my pdf, it shows the popup menu item correctly but not taking me to that particular page.
Below is the code I tried for your reference.
My question: Is there any way to populate this popup menu with the action to go to particular page from the bookmarks of a pdf?
Please help me. Thanks in advance.
var itemInedex = app.popUpMenu("Executive summary", "Why backups?", "Defining the data status (consistency)", "New disk technologies", "Understanding disaster recovery and restart and recovery", "Drawbacks with backups", "Backup in mainframe", "Schematic presentation", "For more information")
switch (itemIndex) {
case "Executive summary":
this.pageNum = 0
breakcase "Why backups?":
this.pageNum = 3
breakcase "Defining the data status (consistency)":
this.pageNum = 4
breakcase "New disk technologies":
this.pageNum = 5
breakcase "Understanding disaster recovery and restart and recovery":
this.pageNum = 6
breakcase "Drawbacks with backups":
this.pageNum = 7
breakcase "Backup in mainframe":
this.pageNum = 8
breakcase "Schematic presentation":
this.pageNum = 9
breakcase "For more information":
this.pageNum = 10
break
}
Views
Replies
Total Likes
One typo issue on your code.
Your variable is declared as itemInedex but it is refered as itemIndex . That might be the problem.
I tired the following code, it works.
var itemIndex = app.popUpMenu("Executive summary", "Why backups?", "Defining the data status (consistency)", "New disk technologies", "Understanding disaster recovery and restart and recovery", "Drawbacks with backups", "Backup in mainframe", "Schematic presentation", "For more information")
switch (itemIndex) { case "Executive summary":
xfa.host.currentPage = 1
break
case "Why backups?":
xfa.host.currentPage =2
break
case "Defining the data status (consistency)":
xfa.host.currentPage = 3
break
case "New disk technologies":
this.pageNum = 5
break
case "Understanding disaster recovery and restart and recovery":
this.pageNum = 6
break
case "Drawbacks with backups":
this.pageNum = 7
break
case "Backup in mainframe":
this.pageNum = 8
break
case "Schematic presentation":
this.pageNum = 9
break
case "For more information":
this.pageNum = 10
break
}
Also note that I have used xfa.host.currentPage property
Nith
Views
Replies
Total Likes
Hi,
How are you?
I have the same question, is there any solution to create a popupmenu from acrobat dc bookmarks?
I'll be very greatfull your help!!
Views
Replies
Total Likes
Hi,
Are you developing in Livecycle Desginer? if not , you probably want to post your question on the Acrobat JavaScript forum.
Regards
Malcolm
Views
Replies
Total Likes
Views
Likes
Replies