[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

How to find public methods for third-party ActiveX control?

Posted on 2004-11-24
5
Medium Priority
?
397 Views
Last Modified: 2013-11-25
I am working with an ActiveX control that was already installed on my system, already used in code, and works great. However, the current usage of the control does not use every method. I now want to know what other methods are available to me.

I am using PERL and do not know the first thing about Visual Studio .NET (which I understand contains ActiveX viewers that may do what I need). I have .NET available to me.

Here a code snippet that I am using (PERL):
#!/usr/bin/perl -w
#use strict;

use Win32::OLE;
$imaging = Win32::OLE->new('IC.ICImagingControl') or die "oops\n";
$imaging->Device("DFK 31F03");
$imaging->VideoFormat("UYVY (640x480)");
$imaging->LiveStart();
$imaging->MemorySnapImage();
$imaging->MemorySaveImage("c:\\ocr\\test.bmp");


The activeX control acts as an interface to a FIREWIRE CAMERA that I have. You can see 6 different methods for the ActiveX control above. I only knew these existed because a previous programmer gave me code showing the methods. However, I know that there are at least 30 different methods for the ActiveX control from the product description. I do not have a password to read the online documentation from the supplier. How do I "see" or "expose" or "view" or "enumerate" the methods the activeX control provides to the programmer?

Thanks!
0
Comment
Question by:sapbucket
  • 2
  • 2
5 Comments
 
LVL 3

Expert Comment

by:weddell
ID: 12671045
I think if you add a reference to the activex control to your solution the methods and properties should then be visible using .net intellisense. So if you write the object name and a dot it should prompt you with the different public methods/properties... maybe create a vb.net application to do it as I know it has a more advanced intellisense
0
 
LVL 19

Accepted Solution

by:
RanjeetRain earned 2000 total points
ID: 12674312
There are two methods.

(1) Learn from documentation
(2) Explore yourself

For (1) see this: http://www.imagingcontrol.com/ic/docs/html/

For (2) You can temporarily install any ActiveX Viewer/Explorer such as Visual Basic/Delphi/Visual Studio .Net etc
0
 
LVL 19

Expert Comment

by:RanjeetRain
ID: 12674327
0
 
LVL 3

Author Comment

by:sapbucket
ID: 12678498
The docs and manuals at the above links are written for VB and C. While the methods are the same, etc., the procedures for initializing the camera interface are different. The examples do not illiustrate the initialization routine: they rely upon autogenerated code specificaly tailored for VB6 or C.

I am trying to implement the ActiveX control using PERL. I have searched through the documentation for an initialization explanation but can't find one.

Basically I thought if I could find out all the methods for the ActiveX I could piece together the init sequence.


Intellisense isn't very good because it lists ALL methods, even those inherited from abstract classes, so the ActiveX specific methods are obfuscated.

What would be cool is a program that shows the whole tree of methods and routines available, in some graphical setting. That way you could see the "big picture" much easier. If you could then highlight a node on the tree it and show a link to the documentation, that would be even better.



So, my question still stands. Is there a way to do it (without using Intellisense)?

0
 
LVL 3

Author Comment

by:sapbucket
ID: 12678788
Well,

  I was able to solve my problem using the online docs RanjeetRain pointed to.

  Here is what the test script looks like:
#!/usr/bin/perl -w
#use strict;

use Win32::OLE;
$imaging = Win32::OLE->new('IC.ICImagingControl') or die "oops\n";

#--------------------------------
# Use the Dialog to get settings:
#       If we want to change settings we need to use the dialog and and save
#       the state so we can load from file.
#$imaging->ShowDeviceSettingsDialog();
#$imaging->SaveDeviceStateToFile("c:\\ocr\\device_state.xml");
#--------------------------------

$imaging->LoadDeviceStateFromFile("c:\\ocr\\device_state.xml",1);
$imaging->MemorySnapImage();
$imaging->MemorySaveImage("c:\\ocr\\test.bmp");



However, this does not satisfy the general problem of viewing an ActiveX control, outside of Visual Studio Land.



If anyone can answer this in the future I would really appreciate it.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
Screencast - Getting to Know the Pipeline

872 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