what i am trying a do is that if the user clicks for example a button placed in the "random" row then a new row appears at run time in between the "random" and the "string" in the [stringtext] column..the user can add only the "stringtext" and after adding the row each datagridview row is increased by one row..any ideas?
PPUTDG.Rows.Insert(rowIndex, count);
可能是您要找的东西吗?
To insert the row :
dataGrid.Rows.Insert(indexWhereToInsertTheRow, values, toPopulate, theRow);
To make it appear at runtime :
dataGrid.Refresh();
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.