Thanks for the reply but it seems i still got a problem...see comments
below...What i'm asking for now is the try and catch code in
javascript to be used in vbscript...
<SCRIPT LANGUAGE=vbscript>
> <!--
> function isOffice2003()
>
> dim p
> on error resume next
> p = createobject('OWC11.spreadsheet') -- this is a
> comment...tried changing it to double quotes then the second error
> appears...and this error got nothing to do with the added codes meaning it is
> working before so i guess "On Error Resume Next" is not the best way cause it
> will disregard all the errors found.
> If Err.Number<>0 THEN
> isOffice2003="office2000XP"
> ELSE
> isOffice2003="office2003"
> end if
> end function
> //-->
> </SCRIPT>
On Thu, 24 Feb 2005 03:44:51 -0500, Charles Carroll <[EMAIL PROTECTED]> wrote:
> <SCRIPT LANGUAGE=vbscript>
> <!--
> function isOffice2003()
>
> dim p
> on error resume next
> p = createobject('OWC11.spreadsheet')
> If Err.Number<>0 THEN
> isOffice2003="office2000XP"
> ELSE
> isOffice2003="office2003"
> end if
> end function
> //-->
> </SCRIPT>
>
>
> On Thu, 24 Feb 2005 08:00:27 -0000, goriojuan
> <[EMAIL PROTECTED]> wrote:
> >
> > Could somebody transform this javascript into vbscript...Help is
> > greatly appreciated.
> >
> > <SCRIPT LANGUAGE=javascript>
> > <!--
> > function isOffice2003()
> > {
> > var p;
> > try {
> > p = new ActiveXObject('OWC11.spreadsheet');
> > }
> > catch (e) {
> > {
> > hidOfcVersion.value ="office2000XP";
> > }
> > }
> > if (p)
> > {
> > hidOfcVersion.value="office2003";
> > }
> > }
> > //-->
> > </SCRIPT>
> >
> >
> >
> >
> >
> > Yahoo! Groups Sponsor
> >
> >
> > Get unlimited calls to
> >
> > U.S./Canada
> >
> > ________________________________
> > Yahoo! Groups Links
> >
> > To visit your group on the web, go to:
> > http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/
> >
> > To unsubscribe from this group, send an email to:
> > [EMAIL PROTECTED]
> >
> > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
>
> Yahoo! Groups Sponsor
> ADVERTISEMENT
>
> ________________________________
> Yahoo! Groups Links
> To visit your group on the web, go to:
> http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/
>
> To unsubscribe from this group, send an email to:
> [EMAIL PROTECTED]
>
> Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/AspClassicAnyQuestionIsOk/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/