I managed to register the IGRID OCX on win7. Problem is Win7 not 10tec OCX
The problem was that since i was logged in as admin i could use cmd.exe and regsvr32
Anyway i did following:
1. create a shortcut to c:\windows\system32\cmd.exe
2. copy the shortcut to desktop
3. rightclick on the shortcut and choose "Run as administrator"
Yes, that's right. We confirm that to register any OCX (not only iGrid) in Win7/Vista you need to launch cmd.exe and regsvr32 from it using the admin rights. Even if you logged in as administrator, you also need to run cmd.exe with the admin rights explicitly.
So, my next question is how to deploy using innosetup is there a register ocx option there anyone?
Yes, the answer is positive again. We use InnoSetup (BTW, an excellent tool) to build our demo installations, and it allows you to register OCX's automatically. here is the corresponding line from the setup script:
Source: ..\OCX\Demo\iGrid460_10Tec.ocx; DestDir: {app}\OCXs_and_Help; Flags: regserver
As you can see, you just need to use the 'regserver' flag.
When you launch the setup package built with InnoSetup, the rights are elevated (and you see the corresponding UAC request), and after that the installation process has the admin rights and registers the OCX's without any problems.