Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / JScript / November 2005

Tip: Looking for answers? Try searching our database.

How to affect a boolean argument defined as a reference

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ivan - 04 Nov 2005 11:04 GMT
Hello.

I have a HTML page with an ActiveX. I have defined and attached an event
handler with a boolean argument:
function eHandler( ... enable_default)

Event in ActiveX object:
event(.... VARIANNT_BOOL* enable_default)

So in a Win32 developing engitnes, if I want to disable default execution of
the event, I set the enable_default to FALSE in a Win32 developer engines (It
works). But when I want to use it in script, nothing happens (argument is of
the boolean type and it works like local variable).

How can I stop the event execution using script?

Thanks for any suggestions.
Bruce Barker - 04 Nov 2005 19:06 GMT
you need to a property to the control the script can set. client script does
not support passing value types by ref.

-- bruce (sqlwork.com)

> Hello.
>
[quoted text clipped - 16 lines]
>
> Thanks for any suggestions.
Ivan - 07 Nov 2005 08:55 GMT
Unfortunatelly, I did't write the control. So I don't have any chance (how I
supposed) to affect default event behavior by script?

> you need to a property to the control the script can set. client script does
> not support passing value types by ref.
[quoted text clipped - 21 lines]
> >
> > Thanks for any suggestions.
Bruce Barker - 07 Nov 2005 17:11 GMT
your only option is to use vbscript which supports byref.

-- bruce (sqlwork.com)

> Unfortunatelly, I did't write the control. So I don't have any chance (how
> I
[quoted text clipped - 30 lines]
>> >
>> > Thanks for any suggestions.
Ivan - 08 Nov 2005 06:06 GMT
I tried something like this:

Sub Ctrl_DoNavigateToURL(url, window_name, ByRef enable_default)
 ... code
 enable_default=False
End Sub

But with no effect. But I use VBScript very rarely and I'm not sure code is
OK.

Thanks.

> your only option is to use vbscript which supports byref.
>
[quoted text clipped - 34 lines]
> >> >
> >> > Thanks for any suggestions.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.