Telerik UI for WPF
Overview
Demos
Roadmap
What's New
Roadmap
Release History
Docs & Support
Pricing
Search
Shopping cart
Login
Contact Us
Try now
close mobile menu
Telerik Forums
/
UI for WPF
This is a migrated thread and some comments may be shown as answers.
How to set GridView.SelectedItem?
1 Answer
55 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Mehmet Akturk
Top achievements
Rank 1
Mehmet Akturk
asked on
09 Sep 2009,
10:58 AM
How to set GridView.SelectedItem in Example below?
Gridview.ItemSource is setted datatable that includes Vendors(Vendor class)
public void setSelectedItem(Vendor handledVendor)
{
GridView.SelectedItem = (object)handledVendor; //What must code be?
}
Add a comment
Submit comment
Cancel
1 Answer
, 1 is accepted
Sort by
Score
Date
0
Milan
Telerik team
answered on
09 Sep 2009,
03:33 PM
Hello Mehmet Akturk,
If your grid is bound to a list of vendor you just have to assign the handled vendor to te SelectedItem property:
public
void
setSelectedItem(Vendor handledVendor)
{
GridView.SelectedItem = handledVendor;
}
All the best,
Milan
the Telerik team
Instantly find answers to your questions on the new
Telerik Support Portal
.
Watch a
video
on how to optimize your support resource searches and
check out more tips
on the blogs.
Add a comment
Submit comment
Cancel
Answer this question
Drag and drop files here or
browse
to attach...
Browse
for files to attach...
Supported file types: PNG, JPG, JPEG, ZIP, RAR, TXT. Max total file size - 20MB.
Submit answer
Cancel
Tags
GridView
Asked by
Mehmet Akturk
Top achievements
Rank 1
Answers by
Milan
Telerik team
Share this question
or
Copy link