Greetings,
I have a VB.NET program that I am trying to convert to C# (my office
decided that we are going to use C# from now on).
I've only been working with C# for about a month now, so this has been
quite the learning experience for me.
The following code is from my VB.NET program and it selects the Call Number
from my datagrid and then uses that information to populate another form.
I cannot seem to find the appropriate adjustment for the CurrencyManager
to reproduce the effect in C#.
Could someone please help me?
Thanks,
Kris
Private Sub btnSelect_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSelect.Click
Dim cm As CurrencyManager = CType(Me.BindingContext
(dgdContactInfo.DataSource, dgdContactInfo.DataMember), CurrencyManager)
' Retrieve the default DataView of the DataGrid
Dim dv As DataView = CType(cm.List, DataView)
Dim dr As DataRow
dr = dv.Item(cm.Position).Row
strCallNumber = dr("Call Number")
myForm.CallNumber = strCallNumber
myForm.Show()
Me.Hide()
End Sub
--
Message posted via http://www.dotnetmonster.com