Archive

Archive for the ‘Legacy Systems’ Category

Grid32: License information for this component not found

June 17, 2009 amiraryani Leave a comment

Nothing is more annoying that a problem with legacy development environments. In last 12 years using Visual Basic that is the first time that when I opened a project and tried to use Microsoft Grid Control it raised a license error:

License information for this component not found. You do not have an appropriate license to use this functionality in the design environment.”

The following article in Microsoft support websites explain the solution: http://support.microsoft.com/kb/177799

CAUSE: When a control is installed for run time use only (such as those installed by an application created with Visual Basic), if the Visual Basic Development Environment is installed onto the same machine afterwards and the existing control is of equal or higher version than that from the CD, the license key for that control is not updated.

RESOLUTION:

If the control in question is any of the ones listed below, then find and double-click on the file Vbctrls.reg on the Visual Basic CD-ROM:

  • AniBtn32.ocx
  • Gauge32.ocx
  • Graph32.ocx
  • Grid32.ocx
  • KeySta32.ocx
  • MSOutl32.ocx
  • Spin32.ocx
  • Threed32.ocx

This will update the design-time licenses for these controls. For Visual Basic 5.0, Vbctrls.reg is found in the \Tools\Controls folder. For Visual Basic 6.0, it is found on Disk 1 in the \Common\Tools\Vb\Controls folder, and for Visual Studio 6.0, it is in the same folder of Disk 3. The Visual Basic 6.0 CD-ROM also contains these files for the Visual Basic 5.0 Custom Controls that were discontinued in Visual Basic 6.0:

  • Dbgrid.reg
  • Mschart.reg

For more information, please refer to the Readme.txt file in the same folder.

If the control in question is not among the controls listed above, please do the following:

  1. Locate Regsvr32.exe on your machine. Note its path.
  2. Locate the offending OCX file(s), usually found in the Windows\System folder for Windows 95, Windows 98, and Windows Me, or the Windows\System32 folder for Windows NT and Windows 2000.
  3. On the Start menu, click Run.
  4. In the Run dialog box, type the following:

    <Path to RegSvr32>\REGSVR32.EXE /u <Path to OCX>\OCXFILE.OCX

    For example:

    C:\Devstudio\VB\REGSVR32.EXE /u C:\Winnt\System32\COMCTL32.OCX

    NOTE: If Regsvr32.exe is in the System or System32 folder, the path is optional.

  5. If you are reinstalling an older version of the control, you should delete/remove the .OCX, .OCA and .DEP files so they will be replaced.
  6. Repeat the previous 3 steps for each offending OCX.
  7. On Control Panel, click Add\Remove Programs.
  8. Select Visual Basic, and click Add\Remove.
  9. Click Reinstall when the options (Add\Remove, Remove All, Reinstall) dialog box appears.

Reapply the latest Visual Studio Service Pack, which can be obtained from:

http://msdn2.microsoft.com/en-us/vstudio/aa718359.aspx (http://msdn2.microsoft.com/en-us/vstudio/aa718359.aspx)

If the problem persists, click the article numbers below to view the articles in the Microsoft Knowledge Base:

181854 (http://support.microsoft.com/kb/181854/EN-US/ ) FILE: VB5cli.exe Fixes Visual Basic 5.0 Control Installation Problem
194751 (http://support.microsoft.com/kb/194751/EN-US/ ) FILE: VB6Cli.exe Fixes License Problems with Visual Basic 6.0
195353 (http://support.microsoft.com/kb/195353/EN-US/ ) FILE: VBUSC.EXE Provides Licensing for Discontinued Controls
Categories: Legacy Systems, VB Classic Tags:

ASP Classic: debug COM object

In the legacy web-based systems (ASP Classic) it was common to use COM object as part of the website implementation. If you need to maintain such a system ( I assume no one develop a new system in ASP Classic) then you will need know how to debug the COM object.

If the COM object is a ActiveX developed using VB6  then you can follow these steps to debug its code:

1. Run the ActiveX VBP project in the Visual Studio (using F5) on the same machine that the website is running.

2. Put a breakpoint on one line of VB code.

3. This step is bases on XP operating system. Go to IIS Manager and get the property of the website. On the [Directory Security] click on the Edit [Anonymous access and authentication control] button.   Untick the Anonymous Access.

iissecurity

4. Restart the IIS. You can type “iisreset” in the command line or use IIS manager.

5. Run your website and navigate to a page which executes the code you want to debug. Once the code get to the breakpoint it will stop and the related code in the Active X will be highlighted.

This process is described in “How To Debug Visual Basic COM Components That Are Used Within Active Server Pages” Microsoft support article.