Wrox Home  
Search P2P Archive for: Go

  Return to Index  

aspx_professional thread: Re Datagrid Drop Down List Problems


Message #1 by "Paul Riley" <paul.riley@s...> on Wed, 12 Feb 2003 23:58:18 -0000
Sorted it myself. After adding a ondatabind event to the datagrid to
point to the below sub it works. 

public sub databound ( sender as object, e as datagriditemeventargs )
	If xmlfile.EditItemIndex <> -1 And xmlfile.EditItemIndex 
e.Item.ItemIndex Then
	With CType(e.Item.Cells(3).FindControl("ddl1"), DropDownList)
	
.Items.FindByValue(e.item.dataitem("DataType")).Selected = True
		End With
	End If
End sub


  Return to Index