Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MSFlexGrid: The subject is not trusted for the specified action 9

Status
Not open for further replies.

ettienne

Programmer
Oct 29, 2005
3,388
US
When I add an MSFlexGrid to a VBA form I get an error message: The subject is not trusted for the specified action.

This has worked perfectly before and now a lot of customers are reporting the same error, so I suspect a Microsoft updated has something to do with it.
 
I may have missed something in my hurry to get my application back up and running, but I believe I tried all kinds of re-installations of the new components, but fixing the 'could not load component' error turned into license errors if I remember correctly. This is the biggest screw up by MS in my 15 years of programming in VB. Please let us know if you definitively solve this issue on PC's without VB6.
 
My PC doesn't have VB6 installed, I do all my work in Excel 2003 connected to a MySQL server.

I downloaded the VB6 update VB60SP6-KB957924-x86-ESN.EXE, then using 7-zip (any decent zipping app would do) opened the file as if it were a zip file, inside it there is a Product.CAB, extract it and then open it, to find there the .OCX files you need, in my case MSFLEXGRID.OCX.

Then put the .OCX files in System32 and register them with regsvr32.exe. I don't get neither the license nor the untrusted error. Before the problem arise, obviously I didn't have the license error to begin with.
 
I didn't realize you wouldn't have to have VB6 to get the VB6 update, that's good to know. Still, I'd rather not have to force my end users to do that, even though it seems like the best fix suggested so far that doesn't tamper with the users' registries. Thanks.
 
If you download the update in your PC and extract the OCX files, I don't think it would be illegal to distribute them to your clients, and you could do it with a batch file that registers them, so it won't look that "unprofessional".
 
I followed ettienne's below fix and everything worked as it should:

CODECreateObject("WScript.Shell").RegWrite "HKLM\SOFTWARE\Microsoft\Internet Explorer\ActiveX Compatibility\{6262D3A0-531B-11CF-91F6-C2863C385E30}\Compatibility Flags", 0, "REG_DWORD"

"Thanks ettienne
 
I just ran into this problem as well.. I used the line of code Etienne suggested. I had to start the VBA macro once (which set the flag in the registry) then I was able to add the flexgrid to the form and the macro worked perfectly. Thanks Etienne.
 
I suddenly started getting this again! KB960715 is uninstalled and my app had been working for a few weeks now it is dead again.

Any ideas?

Software Sales, Training, Implementation and Support for Macola, Synergy, and Crystal Reports. Check out our Macola tools:
 
Below is the code to create a .reg file that will turn the Richedit and Flexgrid on.

Make sure you backup the registry first.

I ran it on my computer and it worked.

Does anybody know the GUID number for the MaskEditBox or any others to add to the .reg file?

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\ActiveX Compatibility\{3B7C8860-D78F-101B-B9B5-04021C009402}]
"Compatibility Flags"=dword:0

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\ActiveX Compatibility\{6262D3A0-531B-11CF-91F6-C2863C385E30}]
"Compatibility Flags"=dword:0

Make sure the Key line is one long line.
Save as a VBAFix.reg file.

Run it and it will fix the 2 registry entrys.

I am using Windows XP

HTH
 
You can find all the GUID #s in the KB960715 document, or in one that is linked. I found it there once....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top