I have this code below that copy to clipboard the selected cells.
I have 2 things i would like to add to the below script.
1- I would like to auto select all cells from the grid automatically
2- I would like to also copy to clipboard the row o with the headers.
How can i do that?
.Redraw = False 'Find range to copy
min_row = .Row: max_row = .RowSel
If min_row > max_row Then Tmp = max_row: max_row = min_row: min_row = Tmp
min_col = .Col: max_col = .ColSel
If min_col > max_col Then Tmp = max_col: max_col = min_col: min_col = Tmp
my_text = "" 'Get the text
For i = min_row To max_row
For j = min_col To max_col
my_text = my_text & .TextMatrix(i, j)
If j < max_col Then my_text = my_text & vbTab
If i < max_row Then my_text = my_text & vbCrLf
.Redraw = True
If my_text <> "" Then
MsgBox "Please select some text.", vbExclamation, "Nothing selected!"