|
-
Apr 7th, 2004, 07:47 AM
#1
Thread Starter
Retired VBF Adm1nistrator
The great thing about variants
I never liked variants, until I just tried writing out a piece of javascript and it worked perfectly
Code:
function doProductAreaChange() {
var strSelectedItem = document.search.elements['selProductArea'];
strSelectedItem = strSelectedItem.options[strSelectedItem.selectedIndex];
strSelectedItem = strSelectedItem.text;
alert(strSelectedItem );
}
Quite please with myself
-
Apr 7th, 2004, 07:53 AM
#2
-
Apr 7th, 2004, 07:56 AM
#3
Thread Starter
Retired VBF Adm1nistrator
I think both JavaScript and VBScript support only variants...
-
Apr 7th, 2004, 08:00 AM
#4
Frenzied Member
should .text not be .value??
also, you can define variables in JS (not sure about VBscript)
bool = new Boolean
ar = new Array()
etc.
Yeah, it is handy though.
Have I helped you? Please Rate my posts. 
-
Apr 7th, 2004, 09:37 AM
#5
You can define variables in vbScript, and you can even give them types, they are just ignored.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|