|
-
Nov 22nd, 2016, 10:10 AM
#1
Thread Starter
New Member
[RESOLVED] Multiple control OCX giving version trouble despite using Binary Compatibility
I have an ocx, let's call it IHateThisThing.ocx, and inside are 2 user controls: ThisOneSucks.ctl and Golden.ctl.
Someone else wrote this originally, but I needed to make a change to Golden.ctl. I needed to change one "InStr" to "InStrRev" and that was it. Done, no problem. Compiled great, using Binary Compatibility matched to the existing ocx that is in production, deployed it and it worked. The problem, however, is when someone tries to do anything that uses ThisOneSucks.ctl, they now get an error message that says "Failed to activate control 'VB.UserControl'. This control may be incompatible with your application. Make sure you are using the version of the control the was provided with your application." To clarify, it does actually say "VB.UserControl" and not "IHateThisThing.ThisOneSucks" as I would expect.
The two things I made sure happened are:
1. Used Binary Compatibility and no warning message was displayed
2. Checked the .VBL file that was generated when the ocx was compiled, the ClsID and the license matched the previous build
I took these same steps when I updated ThingsAreGood.ocx, EverythingIsFine.ocx, and GreatSuccess.ocx, but they only had 1 user control inside. I haven't updated any others that have more than 1 user control so I don't know if it's specific to ThisOneSucks.ctl or if the problem stems from having multiple controls.
I assumed that using Binary Compatibility should have prevented this from happening. In the main project, the controls are used via CreateObject and are not referenced (late binding).
I'm hoping to not need to restart the "compatibility trail" because the main project has the license string hardcoded. I inherited this project from someone that left the company and the production executable is older than the code last checked into SourceSafe so we don't even know what code is compiled into the executable. We're also working on a rewrite so we don't want to spend too much time on the current production version but we do need to be able to push out this change for IHateThisThing.ocx. I do plan to create a setup package and try un/reinstalling over the next 5 days our building is closed, but I don't expect anything to come from that. The posts I've read on the internet for the past week of searching have all said to re-register the ocx (done), reinstall (doing in the next 5 days), and reset the compatibility and start from scratch (can of worms due to main executable).
Any additional advice is appreciated.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|