I use:
Set WshShell = CreateObject("WScript.Shell")
ReturnCode = WshShell.Run ("%windir%\notepad.exe", 1, TRUE)
which works fine in MS Dev Env but not when I launch the html file in IE...
This function works ie it returns the cookie value correctly.
function CookieExist()
dim sValue
msgbox("products")
sValue = Document.All.myScriptlet.GetCookieKey("products")
msgbox(sValue)
end function
BUT, if I remove the first msgbox (obviously I don't...
the reason for the error is because the line
<a href="" class="barbutton1" onmouseover="MouseOver('Back')" onmouseout="MouseOut('Back')" onmousedown="saveForm(); saveCookie('Products'); location='index.html'"><img src="backb.jpg"...
I can't believe the hassle I'm getting with vbscript. Please would someone tell me what on earth is wrong with the following code as I keep getting the error: line 53 expected end of line.
<HTML>
<HEAD>
<LINK REL="StyleSheet" HREF="index.css" TYPE="text/css"...
Hang on a minute, my comment starting "no it doesn't work" came in after your comment starting "take this script I wrote".
Ok, I have tried your code and yes thats the effect I'm getting where doing a simple document.write removes the two buttons on the screen. And yes, it...
No it doesn't work. I want to use it from a vbscript function and this is quoted from the MS site:
'You should not use the write or writeln methods on the current document after the document has finished loading unless you first call the open method, which clears the current document's window...
Thanks for responding.
But, no, response.write is server side.
I'm only interested in client side. Document.write in vbscript creates a new page (or writes to a new page hence obliterating everything that existed in the present document). Whereas in javascript document.write writes to the...
I must be a complete thicky. It seems to me that what you can do with javascript, you cannot do with vbscript. And that is simply dynamically modifying (updating) a browser document (or web page) or dynamically creating a browser document. Using document.write in javascript allows you to do both...
Thanks for your help chaps.
In the Message "Vbscript fails to update screen" or thread 329-205466, dilettante states that document.write is not intended for general dhtml but rather for 'pre-pageload' scripting or for creating a fresh page.
So as I'm a relative newbie to vbscript...
Of course, that make not work because I read somewhere that document.write in vbscript creates a new page so effectively getting rid of everything (including the reference to the style, functions etc).
So if that is correct... how the heck do I do what I did in javascript with document.write...
Just checked and its thus:
<LINK REL=StyleSheet HREF="index.css" TYPE="text/css" MEDIA=screen>
I put "" around the REL and MEDIA values, but nope, no change :-(
sorry, typo in msg, the code in the lines:
document.write("<IMG src='leftmain.jpg'>")
document.write("<IMG SRC='Title2.jpg'>")
document.write("<IMG SRC='rightmain.jpg'>")
should include (and do in real life) the class reference.
Mark.
Thanks for responding.
Basically there is an onload="InitiatePage()" bit in the <BODY> tag. Inside that function are several lines eg.,
document.write("<IMG src='leftmain.jpg' class='Logo'>")
document.write("<IMG SRC='Title2.jpg' class='Title'>")...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.