Hello,
I can't find a good solution for creating and filling an array like filling a table with records where each record has the same structure but has different variable types like each record containing an 'int' and a 'string' and a 'Panel object'
//I used a structure like...
struct stuRecord{
private int i;
private string s;
private Panel pnl;
//constructor
stuRecord('args')(
//store args in privates
)
}
//...and an array of myRecord objects...
stuRecord[] myTable = new stuRecord[12];
//... each filling with a record...
myTable[0] = new stuRecord(123,"test1",myPanelObject1);
myTable[1] = new stuRecord(456,"test2",myPanelObject2);
I also used an ArrayList to store these structure objects but both methods somehow 'dont feel good'...
I feel that there should be a nicer solution.
All tips welcome,
regards,
Henk