Migration of MS-Grid control causing problems



I'm in the process of migrating an application written in VB 6.0 to
VB.NET. This application uses the MS-Grid control extensively. I have
decided to use the MS-Grid Active-X control in my VB.NET project
instead of using the .NET DataGrid as the DataGrid control in .NET is
not supporting many of the required features like freezing of columns.
However I find that an exception is thrown when the AddItem method of
the Grid is called. The error message is "By ref value type parameter
cannot be null ".
The code snippet is as follows:

Grid1.AddItem("test", 1)

In VB 6.0 the Grid.AddItem method had the signature
Grid1.AddItem(Item As String,[index]) As Integer.
In VB.NET, the signature has been changed to
Grid1.AddItem(Item as String, index As Object), with the overload
Grid1.AddItem(Item As String)

Invocation of both the overloads throw the same exception.

Any help on this will be appreciated..
Thanks,
Arun

.



Relevant Pages

  • RE: add variable from outside table
    ... By saving this path for each doctor's signature, your code in your report ... First, I would not use an OLD control in the report, but use an Image control. ... Your sql statement would include the RACF, DoctorName, and the ImagePath ...
    (microsoft.public.access.formscoding)
  • RE: add variable from outside table
    ... The signature is the field with the image. ... First, I would not use an OLD control in the report, but use an Image control. ... Your sql statement would include the RACF, DoctorName, and the ImagePath ...
    (microsoft.public.access.formscoding)
  • ActiveX in doc
    ... I have written a "Signature" activex control for MS Word that allows users ... I think the message box may disappear if I set the macro security level to ...
    (microsoft.public.word.vba.general)
  • Re: CreateEventProc error
    ... Private Sub BuildDisplayForm(strPath As String, ... Dim qdf As QueryDef, qdfControls As QueryDef ... Dim ctl As Control, ctlLabel As Control, ctlParent As Control ... Dim strFilter As String, strSuffix As String, strParentName As String, ...
    (microsoft.public.access.forms)
  • Re: unable to load WinSocket dll in Excel Visual Basic Editor
    ... in my "com controls" list but as soon as I try to add the winsock control I ... may or not need the alias portion of the library definiation. ... Public Declare Function FtpSetCurrentDirectory Lib "wininet.dll" Alias ... (ByVal hFtpSession As Long, ByVal lpszCurrentDirectory As String, ...
    (microsoft.public.excel.programming)

Quantcast