F
Fritjolf
Hi.
I have a winform and a few texteditfields. These are bound to the
result from a linq query:
var person = ProjectGlobal.rd.ER_Persons.Single(c => c.LogonId ==
ALogonId.ToUpper());
The query gets the person of the entered logon-id. Next, the persons
departments are feched:
var sections = from s in ProjectGlobal.rd.ER_Person_Sections
where s.Person_Id == person.Person_Id
select s;
The results from this query is databinded to a DataGridView. The
result columns is Person_Id and Section_Code. And these two columns
are then shown in the grid.
the problem is: when I add a new record to the grid, I need to set the
Person_Id automatically and let the user choose a section code from a
drop down list in section_code.
#1:
How do I set a value to a grid cell?
#2:
How do I get the person-id from the first query - the active object -
and put it into the cell in the grid?
Thanx in advance,
Fritjolf
I have a winform and a few texteditfields. These are bound to the
result from a linq query:
var person = ProjectGlobal.rd.ER_Persons.Single(c => c.LogonId ==
ALogonId.ToUpper());
The query gets the person of the entered logon-id. Next, the persons
departments are feched:
var sections = from s in ProjectGlobal.rd.ER_Person_Sections
where s.Person_Id == person.Person_Id
select s;
The results from this query is databinded to a DataGridView. The
result columns is Person_Id and Section_Code. And these two columns
are then shown in the grid.
the problem is: when I add a new record to the grid, I need to set the
Person_Id automatically and let the user choose a section code from a
drop down list in section_code.
#1:
How do I set a value to a grid cell?
#2:
How do I get the person-id from the first query - the active object -
and put it into the cell in the grid?
Thanx in advance,
Fritjolf