This is a migrated thread and some comments may be shown as answers.

How to get the ItemsSource of DataGrid in Silverlight 3

2 Answers 80 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Kiran
Top achievements
Rank 2
Kiran asked on 23 Jul 2010, 05:44 AM
Hi,

I am using WebAii 2.0 for automating Silverlight 3 application.

I have a datagrid in which i have binded  an ObservableCollection of Student objects.
So in my test can i get the ItemsSource from the datagrid and manipulate by any means in my test case.

<data:DataGrid Name="StudentGrid" ItemsSource="{Binding StudentList}" >
 </data:DataGrid>


Thanks
Kiran

2 Answers, 1 is accepted

Sort by
0
Accepted
Konstantin Petkov
Telerik team
answered on 23 Jul 2010, 08:00 AM
Hello Kiran,

No, unfortunately that is not possible currently. We have no way to expose the object the Silverlight control is bound to yet.

So your goal is to test that custom objects, correct? I believe this goes to the scope of the Unit instead of the UI testing though. Have you considered cover that part of the test scenarios via unit tests?

Kind regards,
Konstantin Petkov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Kiran
Top achievements
Rank 2
answered on 23 Jul 2010, 10:33 AM
Hi,

Ok i got you. What i really wanted was that after lets say updating the properties of user. I wanted to verify whether all the properties are updated Correctly.

The grid contains mininmum information only so i needed the collection.

Thanks
Kiran
Tags
General Discussions
Asked by
Kiran
Top achievements
Rank 2
Answers by
Konstantin Petkov
Telerik team
Kiran
Top achievements
Rank 2
Share this question
or