Solved

Passing parameters to an ActiveX  Form (ocx)

Posted on 2003-11-13
3
1,276 Views
Last Modified: 2012-05-04
Hi ,

  can one pass parameters to an ActiveX Form (ocx) when it's embeded in a web page ?

  i.e.
     ActiveXApplication.ocx /myparam1


  so when you embed the app in the web page and when the page loads up you can pass the ocx specific parameters ?
 
  <OBJECT ID="Test" WIDTH=32 HEIGHT=32
    CLASSID="CLSID:F9043C85-F6F2-101A-A3C9-08002B2F49FB"
    CODEBASE="http://localhost/ActiveXApplication.ocx
    #Version=1,0,0,0 /myparam">
</OBJECT>

 I need to dynamicly pass the ocx parameters to initialise it with settings every time the web page is executed. I do not know if the above
 is possable or if there is a different solution ??

  thanks

   

 
 
0
Comment
Question by:zeroimpact
3 Comments
 
LVL 9

Accepted Solution

by:
tkalchev earned 125 total points
ID: 9747231
The only way to pass parameters to the object is :

<OBJECT ID="Test" WIDTH=32 HEIGHT=32
    CLASSID="CLSID:F9043C85-F6F2-101A-A3C9-08002B2F49FB"
    CODEBASE="http://localhost/ActiveXApplication.ocx">
<PARAM NAME="P1" VALUE="100">
<PARAM NAME="P2" VALUE="15">
<PARAM NAME="P3" VALUE="abc">
</OBJECT>

The above code is setting the initial values of the parameters P1,P2 and P3 to 100, 15 and abc
0
 
LVL 5

Expert Comment

by:TRUENEUTRAL
ID: 9747811
You could write the vlues out to a text file that the ocx looked for and ran each time it was initialized.  Not the best solution, but it might work.
0
 
LVL 1

Author Comment

by:zeroimpact
ID: 9748035
Thanks   tkalchev,

  That did the trick, by Creating a P1, P2 and P3  as Published Interfaces as set properties in the code and then passing in the params
 



0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
bunnyEars challenge 6 100
WMI, model #, retrieving information 10 114
tvirtualstringtree freeze when load too manny images 10 52
C# application error "Parameter Is Not Valid". 3 79
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

910 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now