Modify the datatable column and the winformable able column in winform
1 var dt = dh. getPageTable ("tabelename"); 2 3 dt. columns ["TBLNO"]. columnName = "Business ID"; 4 5 dt. columns ["IDNO"]. columnName = "ID card number"; 6 dt. columns ["CHNSURNAME"]. columnName = "surname"; 7 dt. columns ["CHNGIVENAME"]. columnName = "name"; 8 9 dt. columns ["SEX_NAME"]. columnName = "gender"; 10 11 dt. columns ["NATION_NAME"]. columnName = "national"; 12 dt. columns ["BIRTHDAY"]. columnName = "Date of Birth"; 13 dt. columns ["BIRTHADDRESS"]. columnName = "Birthplace"; 14 dt. columns ["VALIDDATE"]. columnName = "validity period"; 15 dt. columns ["TELEPHONE"]. columnName = "phone number"; 16 dt. columns ["REGIAREACODE_NAME"]. columnName = "Household Registration"; 17 18 19 System. data. dataColumn dc = new System. data. dataColumn (); 20 dc. columnName = "status"; 21 dc. defaultValue = "to be reviewed"; 22 dc. dataType = typeof (string); 23 dt. columns. add (dc); 24 25 26 # region27 28 dt. columns. remove (dt. columns ["CheckType"]. toString (). trim (); 29 // dt. columns ["Teamnum"]. columnName = "team no."; 30 dt. columns. remove (dt. columns ["Teamnum"]. toString (). trim (); 31 dt. columns. remove (dt. columns ["REGIAREACODE"]. toString (). trim (); 32 dt. columns. remove (dt. columns ["SEX"]. toString (). trim (); 33 dt. columns. remove (dt. columns ["NATION"]. toString (). trim (); 34 35 dt. columns. remove (dt. columns ["HJPHOTOURL"]. columnName. toString (). trim (); 36 37 38 # endregion39 40 return dt;View Code