>>>>I am having a problem calling a simple JS function from the ASP.NET page.
>>>>
>>>>The HEAD section of the page has code:
>>>>
>>>>
>>>><script type="text/javascript" language="JavaScript">
>>>>function popWindow() {
>>>>
>>>>test = window.open("test.htm","","width=300,height=250")
>>>> }
>>>></script>
>>>>
>>>>
>>>>The FORM section of the page has code:
>>>>
>>>>
>>>><a href="javascript:PopWindow()">Pop New Window</a>
>>>>
>>>>
>>
>>>>But when I run the form and click on the link, I get error "Object Expected".
>>>>
>>>>What am I missing?
>>>>
>>>>TIA.
>>>
>>>A semi-colon after the window.open(blah); ?
>>>
>>>
>>>Just a guess.. i just glanced at it.
>>
>>I don't think Javascript needs ";" at the end of the line. Strange thing is that if I put
>>
window.onload = popWindow;
after the Javascript, the function PopWindow gets called and a window is open. It is only when you call it from the FORM section of the page I get the error.
>
>Oh, why are you popping up a new window with JavaScript?
>
>
><a href="foo.html" target="_new" >Here ya Go</a>
>
>
>Works just as good.
>
>Morgan
Yes, it will work just as well. But I need to open the Foo.html without scrollbar, toolbar, and in a certain size window. And I can only do these things in javascript function, as far as I know. Correct me if I am wrong.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham