Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 416
  • Last Modified:

VB6 ActiveX Control Design-Time Events

I need to create an ActiveX control to support a legacy VB6 application.

I am wondering if it is possible to catch the design-time click event?

Regards,

Rawden.
0
JedNebula
Asked:
JedNebula
  • 6
  • 4
  • 2
1 Solution
 
Martin LissRetired ProgrammerCommented:
I don't believe so.
0
 
JedNebulaAuthor Commented:
I am struggling to find any sensible suggestions to it out there. Perhaps that is because you can't.

I was hoping to create a nicer looking version of the Microsoft Tabbed Dialog Control.

All I need to do, is allow the developer to change the current tab, by clicking in the control. The rest I can do in property pages.
0
 
Martin LissRetired ProgrammerCommented:
I just read through part of my copy of Developing Visual Basic Add-ins and it says in the Menus and Toolbars chapter that
The VBE object has an Events child object, which in turn has a CommandBarEvents child object. This object receives the Click event of a menu or toolbar button. As we will see, this gives us the ability to place event code in a Click event for a menu or toolbar item.

Does that help at all?
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
JedNebulaAuthor Commented:
I don't think so. An add-in is different from an ActiveX control. I have written add-ins in the past to extend the functionality of the IDE, but they must be installed via the add-in menu.
0
 
Martin LissRetired ProgrammerCommented:
Then the answer is definitely no since ActiveX controls are a part of VB6 code and not the IDE.
0
 
JedNebulaAuthor Commented:
It's not that I don't think you are right because, as much as I don't want to believe it, I doubt I am going to find a solution.

It's more curiosity now, than anything. I wonder how companies like Teebo and Arcadia are able to produce tab controls at all if they cannot respond to design-time click events.

Here is a video of a my dev environment.
Design-Time-Events

One of the control is a Combo box from Arcadia Controls which responds to Design-time Clicks to the down arrow.

My personal opinion is that it is possible to use the Windows API to intercept the messages, look out for click events and then match up the Handles. If they match, fire the control's event. I haven't got time to look into that myself, but I would be nice to know the method they use.
0
 
Martin LissRetired ProgrammerCommented:
Sorry but I can't help and would have no objection if you closed this thread.
0
 
JedNebulaAuthor Commented:
Looks like there was an MS article out there all along. Just had a hard time finding it:

http://support.microsoft.com/kb/179398

I've attached my sample project. The site didn't want to accept the project as a zip file so you'll have to download the text file and rename it to a 7z file. The password for the archive is K8KBRRUk34NH
sub-class-testing.txt
0
 
dwe0608Commented:
I dont know that deleting this question is correct - the answer has been found and answered a query of mine about sub-classing.
0
 
JedNebulaAuthor Commented:
Is that what I've done? That wasn't my intention if I have. I was just trying to accept my own comment. Does that delete the question?
0
 
dwe0608Commented:
I actually dont know - it says "close Request Pending" - and I cant download the example project you uploaded as a txt ... hopefully moderator will sort it out and leave as is ... I answer my own questions periodically and I hope they weren't deleted ...

FYI I only logged the comment so if it were marked for deletion then it wouldnt be deleted ...
0
 
JedNebulaAuthor Commented:
Good old Google (eventually)
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 6
  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now