.net - delete contents of multiple selected cells datagridview in C++/CLI -


i'm trying delete string contents of selected cells when click on button in windows form. button event hook calls following function:

code:

    void deletehighlightedrows(datagridview^ dgv)      {           if (dgv->selectedcells->count > 0)          {              (int = 0; < dgv->selectedcells->count; i++)              {                  dgv->selectedcells[i]->value = "";              }          }      } 

this function called whenever button clicked, whenever there multiple rows selected, count of selected rows zero.

any help/pointers appreciated!


Comments

Popular posts from this blog

java - HTTP Status 500 - An exception occurred processing JSP page /second.jsp at line 15 -

php - Using str_replace to translate a MySQL Table in html -

SQL Server - MyCTE query based on 24 hour period (next day) -