Unable to Resolve Script Error Message

Hi,
I am using Windows Vista and Acrobat Adobe Extended Version 9.
I am struggling with a script. I am sure it is something simple; however, I am struggling mightily with it. I am getting an error message, shown below, that I am unable to understand and resolve.
I am trying to calculate age when given a birthdate. I used "Search" to find a script here at Adobe forums.
Here's the script that I am using:
StoneG, "Third Time Lucky to get Age from DOB entry" #1, 24 Oct 2006 7:21 am
// Jared Langdon
// J. Langdon Consulting
// www.jlangdon.ca
// DOB = Date of Birth
var strDOBYear = Birthdate.rawValue.substr(6,4);
var strDOBMonth = Birthdate.rawValue.substr(0,2);
var strDOBDay = Birthdate.rawValue.substr(3,2);
var oDOB = new Date(parseInt(strDOBYear,10), parseInt(strDOBMonth,10)-1, parseInt(strDOBDay,10) );
var oToday = new Date();
// determine whether the person's birthday has already occurred this year
var bBirthdayHasOccurred = false;
if (oDOB.getMonth() < oToday.getMonth()) bBirthdayHasOccurred = true; if ((oDOB.getMonth() == oToday.getMonth()) && (oDOB.getDate() <= oToday.getDate())) bBirthdayHasOccurred = true;
var nCurrentAge = 0;
if (bBirthdayHasOccurred)
nCurrentAge = oToday.getFullYear() - oDOB.getFullYear();
else
nCurrentAge = oToday.getFullYear() - oDOB.getFullYear() - 1;
this.rawValue = nCurrentAge;
==========
I changed the script slightly. I changed from:
var strDOBYear = DateOfBirth.rawValue.substr(6,4);
to
var strDOBYear = Birthdate.rawValue.substr(6,4);
My variable is "Birthdate".
And I changed boolBirthdayHasOccurred to bBirthdayHasOccurred.
Upon opening the file in Acrobat 9, my error messages is as follows:
Acrobat JavaScript Debugger Functions Version 9.0
Acrobat EScript Built-in Functions Version 9.0
Acrobat Annotations / Collaboration Built-in Functions Version 9.0
Acrobat Annotations / Collaboration Built-in Wizard Functions Version 9.0
Acrobat SOAP 9.0
Birthdate.rawValue has no properties
8:XFA:form1[0]:#subform[0]:Age[0]:calculate
The line above repeats several times. And then...
boolBirthdayHasOccurred is not defined
19:XFA:form1[0]:#subform[0]:Age[0]:calculate
boolBirthdayHasOccurred is not defined
19:XFA:form1[0]:#subform[0]:Age[0]:calculate
Birthdate.rawValue has no properties
8:XFA:form1[0]:#subform[0]:Age[0]:calculate
Birthdate.rawValue has no properties
I have no idea why it mentions "boolBirthdayHasOccurred" because that text is not even present. The last two lines repeat more several times.
When I have delete this entire script, the problems disappears. I have tried finding "boolBirthdayHasOccurred" without success.
Can someone point me in the right direction to troubleshoot this problem?
Regards,
Kevin

Hi Paul,
>>The default would be the format that your machine has set.
That's interesting. So the users' machines are very likely different than mine. So there's no way of knowing in advance. That would seem to make the routine suggested by Jared Langdon (see my top post in this thread) somewhat troublesome? If users' machines are set differently than his, then his routine wouldn't work?
I learned two important items with this task:
1) I need to somehow specify (as done by Stephen) the format of the date numbers before I use them;
2) Rather than using the Calculation Event on the Age, I should instead use Exit Event on the Date-of-Birth field.
Thank you for your response.
Regards,
Kevin

Similar Messages

  • Script error message when printing google maps driving direction into PDF

    My system; Win 7/ 64bits/IE 9 both 32 and 64 bits/Adobe Acrobats 10.1.1. Pro
    Intial problems in printing web sites into PDF files has been resolved when I upgraded into 10.0.1 after having installed IE9.
    However, with 10.1.1. version, I noticed that when I tried to convert google maps results for a driving direction (From A to B), script error message showed up and I could not convert it into PDF. I tried both IE 9 32bits and 64 bits version, but both failed to do it. Please fix the problem for the next updates.
    Thanks

    You might try running CHKDSK on the disk to where you try to save the file. You might have a corrupted file directory or a damaged track on that disk. I urge you to backup what you can before trying this.
    Ken F.

  • I can't get Firefox to open on my computer. I've been using it for a year and a half with no problems until now. I keep getting the following "Unresponsive script" error message: Script: resource:///components/nsHandlerService.js:432 How do I fix this?

    Unresponsive script error message keeps popping up, Firefox will not open.

    Try to delete the mimeTypes.rdf file in the Firefox Profile Folder.
    * http://kb.mozillazine.org/mimeTypes.rdf
    * http://kb.mozillazine.org/File_types_and_download_actions#Resetting_download_actions
    You can use this button to go to the Firefox profile folder:
    *Help > Troubleshooting Information > Profile Directory: Open Containing Folder

  • RH7 HTML - Receive IE script error message when double-clicking link to auto-size pop-up

    Hi, all,
    Anybody ever seen this situation? When double-clicking on a link to an auto-size pop-up, I get the following Internet Explorer script error message:
    This error also occurs when I double-click the link in preview mode within the project. A colleague that is running the same version of IE with the same settings is not receiving this error. A couple of other co-workers are running a different version of IE, and one gets this error and one does not.
    This error does not occur if you single-click the link (which you would normally do), nor does it occur if you double-click a link to a fixed-size pop-up. Once you receive this message and click Yes or No, the link sometimes works correctly when you double-click. I haven't been able to establish a pattern. Also, if you single click the link to display the pop-up, click off of it, and then double-click the link, the error does not occur.
    As you can tell by now, this problem is kind of hard to pin down. I've done some research and I have yet to stumble upon anything that deals with this issue. Unless there is a solution out there, I can do one of two things: 1) change all of the auto-size pop-ups in the project to fixed-sized, which defeats the purpose of creating auto-size pop-ups, or 2) tell our customer not to double-click links.
    Any advice you could give would be welcome.

    Hi there
    Indeed it has been reported on many occasions over the years. Unless someone like Willam has some way cool error detection magick with the scripts, the best approach we have always offered is this.
    Educate your users on the way computers and HTML works. HTML works using SINGLE clicks, not DOUBLE clicks.
    The reason for the error is because the first click caused the computer to launch a JavaScript command to open the sized popup. The second click that followed in rapid succession confused things by asking the script to stop what it was doing and run again.
    Maybe it would help to explain it to your users like this. If you visited a restaurant and when the server asked what you wanted to order, would the become confused if you said to them: I'll have the T-Bone Steak and nearly immediately you repeated it by saying again I'll have the T-Bone Steak.
    Cheers... Rick
    Helpful and Handy Links
    RoboHelp Wish Form/Bug Reporting Form
    Begin learning RoboHelp HTML 7 or 8 within the day - $24.95!
    Adobe Certified RoboHelp HTML Training
    SorcerStone Blog
    RoboHelp eBooks

  • Spinwheel when syncing, unable to sync photos, error message "the disk cannot be read from or written to" ... please help!

    spinwheel when syncing, unable to sync photos, error message "the disk cannot be read from or written to" ... please help!

    Everytime I try to sync my photos to iPad or my iPhone. The sync freezes for a whilie then comes back with "the disk cannot be read from or written to". I have already exported photo library from iPhoto and readded the photos.

  • How do I resolve this error message? The iPhoto library is on a locked volume.  Reopen iPhoto when you have read/write access, or reopen iPhoto with the Option key held down to choose another library.

    How do I resolve this error message? The iPhoto library is on a locked volume.  Reopen iPhoto when you have read/write access, or reopen iPhoto with the Option key held down to choose another library.

    Hi j,
    I don't know if this will work, but I'd try logging in to an admin account, going to your main library (not user library), opening it, opening Application Support, selecting iPhoto, hold down the command key and press i, click on the lock in the lower left, entering the password and making sure you have Read & Write privileges for System and Admin.

  • End script error message: Script:chrome//wrc/content/overlay.js:1149

    I get an unresponsive script error message asking me if I would like to end script now.
    Script:chrome//wrc/content/overlay.js:1149
    Firefox freezes and I have to end the program in task manager. Please help!

    The name "wrc" mentioned in the chrome URL is usually a hint to which extension is causing such an issue.<br />
    You didn't list the extensions, so madperson wasn't able to give more precise instructions.
    If it does work in Firefox Safe-mode then disable all extensions (Tools > Add-ons > Extensions) and then try to find which is causing it by enabling one extension at a time until the problem reappears.
    Close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")
    *https://support.mozilla.org/kb/Troubleshooting+extensions+and+themes

  • How do I resolve an error message 150:30 that will not allow me to open photoshop?

    How do I resolve an error message 150:30 that will not allow me to open photoshop?

    http://helpx.adobe.com/x-productkb/global/error-licensing-stopped-mac-os.html

  • Getting "Script Error" message in Contribute 6.5

    What's causing this and how do I fix?

    Possibly the website uses Java script and there is an error in this script.
    You can do two things:
    1. Best, is to find the error in the script or let someone do it for you, and repair the script.
    2. Second best, is to go to the advanced setting of IE and disable the display of script-errors. To disable the Script error please watch the video linked :- How To Stop Internet Explorer Script Error Messages - YouTube
    Regards,
    Rajeev.

  • Script Error message when checking for updates....

    Post Author: rcoleman
    CA Forum: General Feedback
    Getting a Script Error message when checking for updates or logging in to Crystal Reports. CR Developer v XI 11.0.0.1994.
    Script Error
    Line 481
    Position 41
    If g3()=True then main=True: Exit Fun
    FYI to the Site Administrator

    parkerpress wrote:
    Any idea how to solve this if I haven't activated the 3GS service? I've been doing fine on wireless only.
    Steve
    Same problem here. After upgrading to iOS 4.2.1 a couple of weeks ago I'm getting the same error as the OP in the first post. I've never activated the 3G service.
    I tried turning the cellular service on and checking for updates, pulled and replaced the SIM card, rebooted, nothing helps. I'm still getting the error when I click on the "Check for Update" button in iTunes (v10.1) when my iPad 64GB 3G is connected to my iMac. Any help would be appreciated. TIA.

  • Deskjet840c on win7 script error message is preventing printing from a web page.

    when I try to print from a webpage I get a script error message that says line1527---error invalid argument---code0---url res://ieframe.dll/preview.js. I can print ok from documents stored on pc and have tried all the fixes I can think of. It worked fine before microsoft auto update on 02/12/11.I was using int browser 9 but downloaded firefox browser recently on which I can print web pages ok.would like to fix original prob.Help!--anyone.

    Hi mince, 
    If you are able to print documents from the computer and Firefox then you will need to contact Microsoft support so they can assist you with fixing IE 9. 
    I am an HP employee.
    Say Thanks by clicking the Kudos Star in the post that helped you.
    Please mark the post that solves your problem as "Accepted Solution"

  • Script Error Message Printing in IE9

    I get a "Script Error" message when I try to print anything from IE9.  My OS is Windows 7 and I have a HP Deskjet 4480 all in one.  I ran printer tool fix and it gave me a green light.  I can print anything else from my computer that is not within IE.  Would appreciate help to remedy this situation.  Thank you.
    This question was solved.
    View Solution.

    Hello sassy59,
    On your computer:
    Go to the Start button.
    Select All Programs.
    If you have both Internet Explorer and Internet Explorer 64-bit, open the version that is not the 64-bit and try to print.
    If I have solved your issue, please feel free to provide kudos and make sure you mark this thread as solution provided!
    Although I work for HP, my posts and replies are my own opinion and not those of HP.

  • Can't insert text into web page plus script error message

    I'm using CS3 and, on a fairly regular basis, when I am either pasting or inserting content (usually a newsletter of 500-1000 words), I get a message saying something like I can't insert text in this area. I definitely can insert text in the area as I have done it tons of times before. I sometimes have to cut and past a doc line by line to get it to insert. Very frustrating!
    Also, just recently, I've been getting a script error message, "An error has occurred in the script of this page" followed by Line: 992, Char: 106, Error: Unterminated String Constant, followed by the question: Do you want to continue running scripts on this page? I click Yes and everything seems to work fine.
    Help on either would be appreciated.
    Thanks in advance.

    You might want to make sure you are trying to copy plain text. It's possible that if you are copying from a Word document or another Web site that you are bringing along extra unseen code it doesn't like.  Try copying into Notepad first and then copying from Notepad into Contribute.  Not sure if that's the problem or not, but that's what came to my head first.
    I used to get an error that sounds similar (however it's not reproducing the error for me right now) to your error.  It was because some of my users had javascript menus on their page that Contribute didn't like.  However, if worked fine when you clicked yes and it was fine once it was published.   So if you are running a script that's probably why and I wouldn't worry too much about it as long as you can continue working and the page displays to your users correctly once published.  It's just annoying.
    Hope that helps.  Good luck.

  • My ipad suddenly unable to download with error messages error1004 anybody know why?

    my ipad suddenly unable to download with error messages error1004 anybody know why?

    Error 1004 is explained here:
    http://support.apple.com/kb/TS3694#error1004

  • Why is Adobe crashing and giving me "script " error messages?

    Why is Adobe crashing and giving me "script" error messages?

    Let's see if we can get you the details you need here:
    I'm getting the same Action Script pop-up on WinXP Sp3 32-bit and Win7 Pro SP1 64-bit systems, both running Seamonkey 2.10.1 with the Build Identifier: Mozilla/5.0 (Windows NT 5.1; rv:13.0) Gecko/20120615 Firefox/13.0.1 SeaMonkey/2.10.1, so this is the same browser as Firefox 13.0.1.
    The Action script pop-up has a Dismiss and Continue button and on WinXP clicking Dismiss seems to close the pop-up window and allow the Flash Player to work normally, at least for a while; clicking Continue results in repetitions of the Action Script pop-up - takes some time to come up again so not 100% sure on this behavior.  On Win7, the Action Script pop-up window does not respond to clicking either button, the browser appears to be hung and after a minute or so a message comes up in the Flash player box saying the Flash Player has crashed and to reload the page to retry.
    Here are the contents of the Action Script pop-up:
    I have experienced this on a couple of different sites, notably the Animated Map at weather.com which I get to through my Yahoo login.  Here's the URL, which may or may not work for you, since I get there through my Yahoo ID login:
    http://www.weather.com/weather/map/interactive/USNJ0523:1:US?animation=true&site=ca.yahoo. com&cm_ite=CityPage&par=yahooCA&cm_pla=WxPage&cm_cat=ca.yahoo.com&cm_ven=YahooCA&promo=0
    I am using Flash Player 11.3.300.262 downloaded from this URL:
    http://helpx.adobe.com/content/help/en/flash-player/kb/installation-problems-flash-player- windows.html#main-pars_header
    I hope this provides the necessary info to pursue this. Please let me know if you need more.
    I tacked this on to this thread since it seems relevant but if you want a fresh thread, please specify.
    Thanks.

Maybe you are looking for

  • Indesign 5 - Pdf export - Changing transparency opacity

    Just installed CS5. Its my first time in Indesign for CS5. I need to make some changes on an Indesign doc I created in CS4 and save to pdf. There is a background image that I have on every page of the doc... its set to opacity of 40%. Every time I tr

  • My screen is not turning when I turn the iPad

    My screen is not turning when I turn the iPad. I need help so if I turn my the screen should turn

  • Help my macbook pro 374

    I shutdown my macbook pro 374 about 22 days. then i open it, it work 'normal'... except I found the power adaptor LED dont light not green nor yellow... Just like dont work. and the battery is in low power then auto shutdown. Now still cant charge fr

  • The application smbd quit unexpectedly. (???!)

    Something definitely kooky going on... I haven't been able to access any XP shares in the office (other macs have no probs) for 2 days. Now I am getting an error alert on a regular basis saying: The application smbd quit unexpectedly. EXCBADACCESS (0

  • Why is time machine indexing so long?

    why is time machine indexing so long?