VB.NET 2005 and JsonConvert

Aug 19, 2009 at 4:35 PM

I am importing the Newtonsoft.Json namespace but when I try to utilize JsonConvert, it is acting like it doesn't even exist.  I know I am probably doing something wrong as I am new to this but any help that is provided is greatly appreciated.

 

 

Imports CMSSecurity
Imports Newtonsoft.Json
<System.ComponentModel.DataObject()> _
Public Class Test
    Private _myAdapter As CMSSecurityTableAdapters.coidTableAdapter = Nothing
    Protected ReadOnly Property Adapter() As CMSSecurityTableAdapters.coidTableAdapter
        Get
            If _myAdapter Is Nothing Then
                _myAdapter = New CMSSecurityTableAdapters.coidTableAdapter()
            End If
            Return _myAdapter
        End Get
    End Property
    <System.ComponentModel.DataObjectMethodAttribute _
        (System.ComponentModel.DataObjectMethodType.Select, False)> _
    Public Function getCoidList() As CMSSecurity.coidDataTable
        Dim jsonString As String
        jsonString = 
        Return myConverter.WriteJson(myWriter, Adapter.GetData)
        'Adapter.GetData()
    End Function
End Class

 

 

Imports CMSSecurity

Imports Newtonsoft.Json



 _

Public Class Test

    Private _myAdapter As CMSSecurityTableAdapters.coidTableAdapter = Nothing

    Protected ReadOnly Property Adapter() As CMSSecurityTableAdapters.coidTableAdapter

        Get

            If _myAdapter Is Nothing Then

                _myAdapter = New CMSSecurityTableAdapters.coidTableAdapter()

            End If



            Return _myAdapter

        End Get

    End Property

     _

    Public Function getCoidList() As CMSSecurity.coidDataTable

        Dim jsonString As String

        jsonString = JsonConvert

        'Adapter.GetData()

    End Function

End Class


 

 

 

Coordinator
Aug 20, 2009 at 7:03 AM

JsonConvert use to be called JavaScriptConvert in old versions of Json.NET.