Invalid Argument In Javascript Error
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about javascript invalid argument exception hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask 0x80070057 - javascript runtime error: invalid argument. Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. error invalid argument. at anonymous function Join them; it only takes a minute: Sign up 'Invalid Argument' Error in IE, in a line number that doesn't exist up vote 5 down vote favorite I'm getting the following error in IE 6: Line: 454 Char: 13
Ie11 "invalid Argument." -angular
Error: Invalid Argument Code: 0 URL: xxxxx/Iframe1.aspx and I can't for the life of me find what's causing this. This only happens in a situation where I have a main page that has several IFrames, and it only happens when I have one particular IFrame (the one pointed to by the URL in the error message), and that IFrame is invisible at the time of loading. I've narrowed it up to there, but I still can't find anything more window.open invalid argument specific... The IFrame in question doesn't have 454 lines in its HTML, nor do any of the JS files referred by it. I tried attaching VS to iexplore.exe as a debugger, and it breaks when the error occurs, but then tells me "There is no source code available for the current location"... Any suggestions on how I can go about chasing this one? UPDATE: I found this problem through brute-force, basically, commenting everything out and uncommenting randomly... But the question still stands: what is the rational way to find where the error is, when IE reports the wrong line number / file? javascript internet-explorer debugging share|improve this question edited Oct 2 '10 at 20:46 community wiki 4 revsDaniel Magliola It's really a difficult question to answer without being able to see the whole problem. Have you tried debugging in Firefox or opera? Open it in one of those and check the error console for perhaps a more helpful error message. –Ian Elliott Jun 17 '09 at 16:54 Firefox's firebug plugin makes debugging much, much simpler. I suggest trying that out on the page. –Ben Hughes Jun 17 '09 at 17:01 Ian, Ben, thank you for your suggestions. I in fact use FireBug all the time, but this problem happens only in IE. –Daniel Magliola Jun 17 '09 at 20:04 add a comment| 8 Answers 8 active
References & Guides Learning web development Tutorials References Developer Guides Accessibility Game development ...more docs Mozilla Docs Add-ons Firefox Developer ToolsFeedback Get Firefox help Get ie9 invalid argument -2147024809 web development help Join the MDN community Report a content problem Report
Script87 Invalid Argument
a bug Search Search Languages Català (ca) Deutsch (de) Español (es) Français (fr) Bahasa Indonesia (id) 日本語 (ja)
Ie9 Settimeout Invalid Argument.
한국어 (ko) Polski (pl) Português (do Brasil) (pt-BR) Русский (ru) 中文 (简体) (zh-CN) 正體中文 (繁體) (zh-TW) Add a translation Edit Advanced Advanced History Print this article MDN Web technology For developers JavaScript http://stackoverflow.com/questions/1008290/invalid-argument-error-in-ie-in-a-line-number-that-doesnt-exist JavaScript reference Standard built-in objects Error Your Search Results ariyankhan josephmcasey AlexanderFradiani fscholz mondwan SphinxKnight janosch-x davidchase Mingun shawnacscott Sheppy ethertank Nickolay evilpie trevorh teoli davidbourguignon secoif DomenicDenicola dgchurchill timemachine3030 Sevenspade Potappo Sephr Brettz9 Mgjbot Allanbonadio Ptak82 JustinLudwig Error In This Article SyntaxParametersDescriptionError typesPropertiesMethodsError instancesPropertiesStandard propertiesVendor-specific extensionsMicrosoftMozillaMethodsExamplesThrowing a generic errorHandling a specific errorCustom Error TypesSpecificationsBrowser compatibilitySee also The Error constructor creates an https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error error object. Instances of Error objects are thrown when runtime errors occur. The Error object can also be used as a base object for user-defined exceptions. See below for standard built-in error types. Syntax new Error([message[, fileName[, lineNumber]]]) Parameters message Optional. Human-readable description of the error. fileName Optional. The value for the fileName property on the created Error object. Defaults to the name of the file containing the code that called the Error() constructor. lineNumber Optional. The value for the lineNumber property on the created Error object. Defaults to the line number containing the Error() constructor invocation. Description Runtime errors result in new Error objects being created and thrown. This page documents the use of the Error object itself and its use as a constructor function. For a list of properties and methods inherited by Error instances, see Error.prototype. Error types Besides the generic Error constructor, there are six other core error constructors in JavaScript. For client-side exceptions, see Exception Handling Statements. EvalError Creates an instance representing an error that occurs regarding the global function eval(). InternalError Creates an instance representing an error that occur
August 11, 2009 by Frank Kim Today I noticed one of my links were not working. This was only happening in Internet Explorer 8. Looking http://betweengo.com/2009/08/11/javascript-invalid-argument-internet-explorer-only/ down at the status bar in the lower left corner I saw the message “Error on page.” Double-clicking on it popped up this window full of useless information. A Google http://www.webdeveloper.com/forum/showthread.php?252486-Javascript-Error-Invalid-argument search for “internet explorer invalid argument” brought me to this page, Internet Explorer Sucks. Fortunately the author had run into this problem and figured out the solution. It turns out invalid argument In Internet Explorer, the second argument to the JavaScript window.open method, which is the windowName argument, can’t have spaces. My original link looked like this. What's this? When I took out the spaces from the windowName argument the link worked. You would think Internet Explorer 8 would have fixed this issue by now, it doesn’t affect any other modern web invalid argument in browser. Related posts: Unobtrusive JavaScript Internet Explorer form does not invoke ATG handler Twitter Weekly Updates for 2009-08-16 Turning off Perforce Windows Explorer Integration URL.equals and hashCode make blocking Internet connections This entry was posted in JavaScript and tagged internet explorer, JavaScript by Frank Kim. Bookmark the permalink. 31 thoughts on “JavaScript Invalid Argument in Internet Explorer Only” John on August 18, 2009 at 2:36 AM said: A massive thank you for sharing this information. I had exactly the same problem. Firefox was fine but IE was doing what it is good at and stressing me out! Your solution worked perfectly. I wonder if I could sue Bill Gates for loss of hair and a drinking habit….? 😉 Frank Kim on August 18, 2009 at 2:42 PM said: Thanks John. Your thank you comment is almost exactly the same as the thank you comment I left in the blog post I referenced, "Internet Explorer Sucks." 🙂 Li on September 21, 2009 at 6:42 AM said: Thank you so much!!! I have been pulling my hair for twenty
this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. Results 1 to 9 of 9 Thread: Javascript Error: Invalid argument Tweet Thread Tools Show Printable Version Email this Page… Subscribe to this Thread… Display Linear Mode Switch to Hybrid Mode Switch to Threaded Mode 10-19-2011,06:52 PM #1 yizzy2976 View Profile View Forum Posts Registered User Join Date Oct 2011 Posts 5 Javascript Error: Invalid argument There is an error in the util.js file: wrapperDivElement.style.height=newIframeHeight+px Does anyone know the fix? Reply With Quote 10-19-2011,11:31 PM #2 pactor21 View Profile View Forum Posts Registered User Join Date Sep 2009 Posts 159 Without better description of the problem, you might not get assistance from people here. HTML and javascript code never hurt. Got jQuery problem? jQuery vault can help you find solutions. Give it a try and find out. Click jQuery vault to help us help you. Reply With Quote 10-20-2011,07:24 AM #3 yizzy2976 View Profile View Forum Posts Registered User Join Date Oct 2011 Posts 5 Sorry, you can tell I am new to this. Here is the code surrounding the error: function setNewIframeHeight(iframeOffsetForMenu) { cpo_iframe2Ht = self.document.body.offsetHeight; cpo_iframe2Offset = findIframeTop(wrapperDivElement); newIframeHeight = cpo_iframe2Ht-cpo_iframe2Offset; newIframeHeight -= ((offsetForMenu!=null)?offsetForMenu:0);//compensate for IE quirks wrapperDivElement.style.height=newIframeHeight+"px"; iFrameElement.height=(newIframeHeight-5)+"px"; } The error occurs on the line with wrapperDivElement.style.height=newIframeHeight+"px"; Reply With Quote 10-20-2011,12:39 PM #4 pactor21 View Profile View Forum Posts Registered User Join Date Sep 2009 Posts 159 What exactly does the error message say? and show us the relevant HTML mark-up. Got jQuery problem? jQuery vault can help you find solutions. Give it a try and find out. Click jQuery vault to help us help you. Reply With Quote 10-20-2011,02:11 PM #5 yizzy2976 View Profile View Forum P