By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,027 Members | 1,206 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,027 IT Pros & Developers. It's quick & easy.

datagrid Get "F3" function

P: n/a
My purpose is When the user press "F3" in specified column, i need to put
specified data in that column
Now, I can get "F3" by using [Protected Overrides Function
ProcessCmdKey(ByRef msg As System.Windows.Forms.Message, ByVal keyData As
System.Windows.Forms.Keys) As Boolean ]

BUT I don't know how to put the data in that textbox,
I try Dim xx As DataRow =
dtInvCharges.Rows(dgInvCharges.CurrentRowIndex)
xx.Item("remark") = "F3 Command process"

it returns error.
Anybody got some idea ? Thanks a lot


Nov 21 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Hi,

DataGrid1.Item(DataGrid1.CurrentCell) = "Test"

Ken

------------------------

"Agnes" <ag***@dynamictech.com.hk> wrote in message
news:eZ*************@TK2MSFTNGP11.phx.gbl...
My purpose is When the user press "F3" in specified column, i need to put
specified data in that column
Now, I can get "F3" by using [Protected Overrides Function
ProcessCmdKey(ByRef msg As System.Windows.Forms.Message, ByVal keyData As
System.Windows.Forms.Keys) As Boolean ]

BUT I don't know how to put the data in that textbox,
I try Dim xx As DataRow =
dtInvCharges.Rows(dgInvCharges.CurrentRowIndex)
xx.Item("remark") = "F3 Command process"

it returns error.
Anybody got some idea ? Thanks a lot

Nov 21 '05 #2

P: n/a
Ken, It doesn't work ar.
Do I need to declare something first ?
dim xx as datarow = ctype( DataGrid1.Item(DataGrid1.CurrentCell),datarow) ??
xx.item("remark") = "Test"
"Ken Tucker [MVP]" <vb***@bellsouth.net> 在郵件
news:%2******************@TK2MSFTNGP15.phx.gbl 中撰寫...
Hi,

DataGrid1.Item(DataGrid1.CurrentCell) = "Test"

Ken

------------------------

"Agnes" <ag***@dynamictech.com.hk> wrote in message
news:eZ*************@TK2MSFTNGP11.phx.gbl...
My purpose is When the user press "F3" in specified column, i need to put
specified data in that column
Now, I can get "F3" by using [Protected Overrides Function
ProcessCmdKey(ByRef msg As System.Windows.Forms.Message, ByVal keyData As
System.Windows.Forms.Keys) As Boolean ]

BUT I don't know how to put the data in that textbox,
I try Dim xx As DataRow =
dtInvCharges.Rows(dgInvCharges.CurrentRowIndex)
xx.Item("remark") = "F3 Command process"

it returns error.
Anybody got some idea ? Thanks a lot


Nov 21 '05 #3

P: n/a
I solve my stupid problem
dgInvCharges.Item(dgInvCharges.CurrentCell.RowNumb er, 2) =
Me.objChgResult.pchgName

"Agnes" <ag***@dynamictech.com.hk> 在郵件
news:uI**************@TK2MSFTNGP09.phx.gbl 中撰寫...
Ken, It doesn't work ar.
Do I need to declare something first ?
dim xx as datarow = ctype( DataGrid1.Item(DataGrid1.CurrentCell),datarow) ?? xx.item("remark") = "Test"
"Ken Tucker [MVP]" <vb***@bellsouth.net> 在郵件
news:%2******************@TK2MSFTNGP15.phx.gbl 中撰寫...
Hi,

DataGrid1.Item(DataGrid1.CurrentCell) = "Test"

Ken

------------------------

"Agnes" <ag***@dynamictech.com.hk> wrote in message
news:eZ*************@TK2MSFTNGP11.phx.gbl...
My purpose is When the user press "F3" in specified column, i need to put specified data in that column
Now, I can get "F3" by using [Protected Overrides Function
ProcessCmdKey(ByRef msg As System.Windows.Forms.Message, ByVal keyData As System.Windows.Forms.Keys) As Boolean ]

BUT I don't know how to put the data in that textbox,
I try Dim xx As DataRow =
dtInvCharges.Rows(dgInvCharges.CurrentRowIndex)
xx.Item("remark") = "F3 Command process"

it returns error.
Anybody got some idea ? Thanks a lot



Nov 21 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.