Solved

ActiveX - <param name...>

Posted on 2000-03-28
5
802 Views
Last Modified: 2013-11-18
How can I use, within an ActiveX Control, the data introduced with <param name...> from the HTML document?

thanks
crisoft
0
Comment
Question by:crisoft
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 

Expert Comment

by:TheFly
ID: 2664641
crisoft,

the <param name...> will pass a value to a public property within the ActiveX control.

In your ActiveX control -
  declare a public Let/Get property

  within the Let property assign the argument value to a modular level variable.

Hope this helps.

Toodle pip.
0
 

Author Comment

by:crisoft
ID: 2664766
Can you give me a small example? I can´t understand your explanation.
0
 

Author Comment

by:crisoft
ID: 2664992
Can you give me a small example? I can´t understand your explanation.
-----------------------------7d0262164f8
Content-Disposition: form-data; name="qid"

10318689
-----------------------------7d0262164f8
Content-Disposition: form-data; name="Submit"

Submit
-----------------------------7d0262164f8--
0
 

Accepted Solution

by:
TheFly earned 50 total points
ID: 2668372
crisoft,

If your main concern is how to pass a value into an ActiveX control from HTML then try the following instead -

{activeX name}.{property name}= value

heres an example of HTML that i wrote recently that makes use of activex property and event

<p><object name="AssetCom" ID="usr_AssetTV" classid="clsid:9F871D8A-E9F4-11D3-B4AD-0080C7335CA6"
CODEBASE="AssetTV_001.CAB#version=1,0,0,41"
 width="180" height="382">
</object></p>
<body bgcolor="#D9F0ED"></body>
<SCRIPT LANGUAGE="VBScript">
AssetCom.SetIP="10.4.170.70/"
Sub AssetCom_SelectedAsset(AssetId)
parent.frames("Main").location.href="dcs.asp?astrpage=Main&astrAssetId=" & Assetid
End Sub
</SCRIPT>

In this example there is a property in the activeX control called SetIP and the value of "10.4.170.70/" is passed in.


In the activex control itself use the following code -

Option Explicit
Private mstrIPAddress As String

Public Property Get SetIP() As String
    SetIP = mstrIPAddress
End Property

Public Property Let SetIP(astrIP As String)
    mstrIPAddress = astrIP
End Property


If this doesnt help can you give me more info about your problem or concerns.

Good Luck
0
 

Expert Comment

by:botikklopik
ID: 22326226
Thanks, TheFly. Your solution also helps me in sorting out the problem. Cheers :)
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses
Course of the Month5 days, 22 hours left to enroll

627 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question