2
votes

When opening a visual basic 6 project, it automatically updates the activeX control to the latest version.

I saw a post saying that this line must be added in the vbp file NoControlUpgrade=1 for this not to happen, but it doesn't work for me. When saving the project in vb6, it updates the control in the vbp.

1. How can I have this work?

2. How can I have vb6 not to upgrade the activeX controls as a default behaviour?

Strangely, I tried to create a new project with a form and a few imagelists (from mscomctl.ocx), I saved the project then opened the vbp file in notepad, changed the version of the ocx to an older one, saved the vbp file and opened it in vb6; then I closed vb6 and it didn't even ask me to save the project, even though I did not add the line NoControlUpgrade=1.

But with my older projects, doing the same thing to the vbp file then opening it in vb6 and closing it will result in vb6 prompting me to save the project (and if I save it, the ocx will be updated).

1
Project + Properties, General tab, "Upgrade ActiveX Controls" checkbox.Hans Passant
@HansPassant, this just does the same thing as adding NoControlUpgrade=1 in the vbp project...GianT971
AFAIK, the "version" this "upgrading" refers to is the COM interface version, not a "file version" at all. When Microsoft updates these libraries they do not normally break binary compatibility, so you can only have one registered at a time.Bob77

1 Answers

1
votes

Upgrade ActiveX Controls Property In Visual Basic 6.0, the Upgrade ActiveX Controls project property automatically updates any ActiveX controls if you have installed a newer version of them on your machine since the last time you opened the project.

Project>Properties>General tab>Upgrade ActiveX Controls

Source - http://msdn.microsoft.com/en-us/library/cdfc7fza(v=vs.80).aspx