How can i get the URl in th eaddress bar in IE?
Cheers. I havent got a clue how to do this and i need to know really badly, as my internship finishes 2moro and i have a problem
How can i get the URl in th eaddress bar in IE?
Cheers. I havent got a clue how to do this and i need to know really badly, as my internship finishes 2moro and i have a problem
This might work on the frontmost window.
tell application "Internet Explorer" to ¬
set URL_ to item 1 of (GetWindowInfo -1)
– Rob
tell application "Internet Explorer"
GetWindowInfo 1
end tell
cheer.
I thought as much but it wasnt working.
Cheers, i know its a different problem now.
I dont know if you guys can help. I had the same problem before but it never got fixed.
basically i would like to insert some text into a textarea form.
I know the JS.
do script “window.document.forms[0].elements[5].value='”&hello&“'”
But hello is in fact a caption that is from fileinfo of an image.
basically if i do the above with the following caption then it wont insert it. Is it because of the way that the caption is worded, like a paragraph? or what could it be. is there anything that i can use to get round this really major issue.
Defiant, one of the Bill Koch's several IACC yachts, leads the Dennis Conner Stars & Stripes during the 1992 Defender Series off Sand Diego. Both boats are powering under gennaker on the reaching leg of the race, now disappeared from the race format.
© Photo Christian Fevrier / Bluegreen Pictures
Could it be the ©, as i know in the other fields of the form if i just simply use normal trext then it works. But this doesn’t.
Argh!!!
I can’t offer anything on the form stuff.
– Rob
I see two unsafe strings: ’ and return, which you must escape as ’ and r
Also, you won’t conserve the © symbol. For speed’s sake, just replace coincidences of ’ & return with ’ and r
For an exact copy of the string, try this:
set x to "Defiant, one of the Bill Koch's several IACC yachts, leads the Dennis Conner Stars & Stripes during the 1992 Defender Series off Sand Diego. Both boats are powering under gennaker on the reaching leg of the race, now disappeared from the race format.
© Photo Christian Fevrier / Bluegreen Pictures"
--> hex-encode string
set x to stringtoHex(x)
set y to {}
repeat with i from 1 to x's length by 2
set y's end to "%" & text i thru (i + 1) of x
end repeat
tell application "Internet Explorer"
do script "window.document.forms[0].elements[5].value=unescape('" & (y as string) & "')"
end tell
on stringtoHex(this_string)
this_string as C string
try
result * 5
on error msg
return text from character 22 of msg to character -19 of msg
end try
end stringtoHex
so far it works, havenmt test ed it properly.
What does the text from character 22 do? will that cause problesm if the text i enter is alot larger or smaller???
As the text is always diferent. Has that got enough scope to account for it???
Thanks so far though!!!
I don’t know the limits, but works fine with 20000 bytes…