datagrid and getting all data

i have  a datagrid in silverlight   and i fill it with data . the problem is    i want to display cell row 1 col1 in a textbox but i cant get access to individual cells?



    Public Sub methodHandler_filldatacompleted(ByVal sender As Object, ByVal e As ServiceReference1.filldataCompletedEventArgs)
        Dim a As New List(Of datagrid.ServiceReference1.subject)
        Dim data2 As New List(Of Class1)

        dg1.ItemsSource = e.Result
        '   a = CType(dg1.ItemsSource, datagrid.ServiceReference1.subject)
        'tb.Text = a.Count


    End Sub


Public Class Class1
    Dim m_id As String
    Dim m_subject As String
    Dim m_test As String
    Dim m_comment As Boolean


.Error    1    Value of type 'datagrid.ServiceReference1.subject' cannot be converted to 'System.Collections.Generic.List(Of datagrid.ServiceReference1.subject)'.    D:\silverlight\datagrid2\datagrid\Page.xaml.vb    50    13    datagrid2
jagguyAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

gangwischCommented:
'the format for this is datagrid1.item(rowindex,columnindex)
textbox1.text=datagrid1.item(1,1)
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
jagguyAuthor Commented:
there is no such command in silverlight?

....=datagrid1.item(1,1)

I believe in silverlight i need to parse the data into xml but i dont know how to do this, and after 3 days of asking on forums not many people know this either.

b elow is something i was told with c# but i cant get vb.net code and i cant use
..XDocument.Parse(e.Result)? error

XDocument xmlDescription = XDocument.Parse(e.Result); 'error cant convert and .tostring has no effect
 
var ProjectInfo = from desc in xmlDescription.Descendants("Table")
 
select new
 
{
 
Description =desc.Element("A0").Value
 
};
foreach (var info in ProjectInfo)
 
{
 
         txtDescription.Text = info.Description;
 
}  

Open in new window

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Development

From novice to tech pro — start learning today.