Imports System.Collections.Generic
Imports System.Linq
Imports System.Net
Imports System.Windows
Imports System.Windows.Controls
Imports System.Windows.Documents
Imports System.Windows.Input
Imports System.Windows.Media
Imports System.Windows.Media.Animation
Imports System.Windows.Shapes
Imports Telerik.Windows.Controls
Imports Telerik.Windows.Controls.GridView
Imports System.Windows.Data
Imports System.Collections

Namespace multiColumnCombo_SL
	Public Partial Class MultiColumnCombo
		Inherits UserControl
		Public Sub New()
			InitializeComponent()
			AddHandler Me.Loaded, New RoutedEventHandler(AddressOf MultiColumnCombo_Loaded)
		End Sub

		Private Sub MultiColumnCombo_Loaded(sender As Object, e As RoutedEventArgs)
			Dim parentColumn As GridViewComboBoxColumn = TryCast(Me.ParentOfType(Of GridViewCell)().Column, GridViewComboBoxColumn)

			Me.RadCombo1.ItemsSource = parentColumn.ItemsSource
			Me.RadCombo1.SelectedValuePath = parentColumn.SelectedValueMemberPath
			Me.RadCombo1.SelectedValue = Me.ParentOfType(Of GridViewCell)().Value
		End Sub
	End Class
End Namespace
