• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 797
  • Last Modified:

Change DataGridViewButtonColumn Text

Can someone tell me if it is possible to change the text on a DataGridViewButtonColumn if the table has a datasource.  I am using the following code and it does nothing.  I do have the UseColumnTextForButtonValue set to true.

        For i As Integer = 0 To DataGridView1.RowCount - 1
            DataGridView1(0, 1).Value = "ReAssign"
        Next
0
pat_cunningham
Asked:
pat_cunningham
  • 5
  • 3
1 Solution
 
jpaulinoCommented:
Change it to this

For i As Integer = 0 To DataGridView1.RowCount - 1
   DataGridView1(0, 1).Value = "ReAssign"
Next
0
 
jpaulinoCommented:
Sorry

For i As Integer = 0 To DataGridView1.RowCount - 1
   DataGridView1(0, i).Value = "ReAssign"
Next
0
 
pat_cunninghamAuthor Commented:
I am sorry that is what I had. I changed the i to a 1 to see if I could get any of the text to change.  There are actually about 10 rows in this table.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
jpaulinoCommented:
But the DataGridViewButtonColumn  is unbound right ?
0
 
pat_cunninghamAuthor Commented:
yep
0
 
jpaulinoCommented:
>> I do have the UseColumnTextForButtonValue set to true

I miss that! Do not use this. Change UseColumnTextForButtonValue = False and try the code.
0
 
pat_cunninghamAuthor Commented:
thanks for the help.
0
 
jpaulinoCommented:
Thanks for the grade!

Good work
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 5
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now