我的 WF 上有 c1FlexGrid,有 7 列和 10 行。双击时,我想打开另一个 WF,它类似于该行的详细信息,但我想将 userId 值发送到该表单。我不知道如何获得该ID。我的代码如下所示:
private void c1FlexGrid1_DoubleClick(object sender, System.EventArgs e)
{
int rowIndex = c1FlexGrid1.Row;
if (rowIndex != -1)
{
int userId = I need value from column "UserId" on this rowIndex.
frmUser userForm = new frmUser(userId);
userForm.ShowDialog();
}
}
有什么建议吗?