After Upgrading 1.1 Project to 2.0 --> _Class is not CLS-Compliant

Giganews Newsgroups
Subject: After Upgrading 1.1 Project to 2.0 --> _Class is not CLS-Compliant
Posted by:  Whiskey Romeo Lima
Date: Sat, 14 Nov 2009

After Upgrading 1.1 to 2.0 using VS 2008 I get following warnings in the
Reference.vb file of webservice the project is referencing.

_Class is not CLS-Compliant
_ClassColumn is not CLS-Compliant
_Select is not CLS-Compliant

Here is an example of the first error:

        '''<summary>
        '''Represents strongly named DataRow class.
        '''</summary>

<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")>  _
        Partial Public Class tblCompClassRow
            Inherits Global.System.Data.DataRow

            Private tabletblCompClass As tblCompClassDataTable

            <Global.System.Diagnostics.DebuggerNonUserCodeAttribute()>  _
            Friend Sub New(ByVal rb As Global.System.Data.DataRowBuilder)
                MyBase.New(rb)
                Me.tabletblCompClass = CType(Me.Table,tblCompClassDataTable)
            End Sub

            <Global.System.Diagnostics.DebuggerNonUserCodeAttribute()>  _
            Public Property _Class() As String '<--WARNING HERE
                Get
                    Return CType(Me(Me.tabletblCompClass._ClassColumn),String)
                End Get
                Set
                    Me(Me.tabletblCompClass._ClassColumn) = value
                End Set
            End Property
        End Class

Since there is no recommended fix for this via Intellisense, what I am
expected to do here.  This auto generated code.

WRL

Replies