update a button to have multiple words on it, and column with another background color

Hello and good morning Expert Exchange users and elite helpers.

I would like to update two things for this file to have.

---Have also a button that shows the Name on the button every time i press it for "H" column
---Have Column "K","L" and "M" have a color of (Orange, Accent 1, lighter 40%) on those column

Please for more thorough information on what is it to be done for this file, please click on the following link and if there is any inconvenience or question feel free to ask. Thanks again Expert Exchange.

https://www.youtube.com/watch?v=E5dm5nw7Udw&feature=youtu.be
28977912a.xlsm
Omar HernandezAsked:
Who is Participating?
 
Martin LissConnect With a Mentor Older than dirtCommented:
Is this is?
28978276c.xlsm
0
 
Martin LissOlder than dirtCommented:
In module9 replace the RectangleBeveled6 sub with this.
Sub RectangleBeveled6_Click()

'new
If ActiveCell.Row < 6 Then
    Exit Sub
End If

Select Case UCase(Cells(ActiveCell.Row, "H"))
    Case ""
        Cells(ActiveCell.Row, "H") = "1PRIORITY"
    Case "1PRIORITY"
        Cells(ActiveCell.Row, "H") = "2PRIORITY"
    Case "2PRIORITY"
        Cells(ActiveCell.Row, "H") = "LAST P"
    Case "LAST P"
        Cells(ActiveCell.Row, "H") = "ZDONE"
    Case "ZDONE"
        Cells(ActiveCell.Row, "H") = ""
End Select

'new
With ActiveSheet.Shapes("Bevel 10").TextFrame
    .Characters.Text = Cells(ActiveCell.Row, "H")
End With
With Range(Cells(ActiveCell.Row, "K"), Cells(ActiveCell.Row, "M")).Interior
    .Pattern = xlSolid
    .PatternColorIndex = xlAutomatic
    .ThemeColor = xlThemeColorAccent1
    .TintAndShade = 0.4
    .PatternTintAndShade = 0
End With

End Sub

Open in new window

0
 
Martin LissOlder than dirtCommented:
Note that the above will affect any row that you click. Do you want to restrict it to rows that have something in K through M?
0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
Omar HernandezAuthor Commented:
Hello there Martin Liss, i change the module but i believe it is Module11 not module9. Is it module11
0
 
Martin LissOlder than dirtCommented:
Yes, you're right.
0
 
Omar HernandezAuthor Commented:
It is working great, can we get this option to show that when i click on a row to show the actual priority that rows has.

For Example if i give a priority (last) to row 22,  Instead of it showing what was the last row given priority being (last), once i click on another row, if other row has a different priority or none have the button showing actual row priority.
0
 
Martin LissOlder than dirtCommented:
Give this a try.
28978276.xlsm
0
 
Omar HernandezAuthor Commented:
Looks great, now what it needs is the column K, L, and m to have a different color than the column before K
0
 
Martin LissOlder than dirtCommented:
I don't understand what you mean. When you click any cell, that row becomes yellow. If you then click the button we've been modifying, columns K:M become orange. and that's "a different color than the column before K".
0
 
Omar HernandezAuthor Commented:
ok let me further explain, the background is white on the file,

Keep the color white for the background of column "A" through "J"

what i want it to do is, due to column "K", "M" and "L" being there for a different purpose is the following

-Have these column have the background with the color (Orange)

What i mean by saying yellow

keep the function that when i click on a row.
-Have the color yellow distinguishing the row i have selected.
0
 
Omar HernandezAuthor Commented:
0
 
Martin LissOlder than dirtCommented:
In the RectangleBeveled6_Click code you''ll find this:
    With Range(Cells(ActiveCell.Row, "K"), Cells(ActiveCell.Row, "M")).Interior
        .Pattern = xlSolid
        .PatternColorIndex = xlAutomatic
        .ThemeColor = xlThemeColorAccent1
        .TintAndShade = 0.4
        .PatternTintAndShade = 0
    End With

Open in new window

Just before it or after it add this:
    With Range(Cells(ActiveCell.Row, "A"), Cells(ActiveCell.Row, "J")).Interior
        .Pattern = xlNone
        .TintAndShade = 0
        .PatternTintAndShade = 0
    End With

Open in new window

0
 
Omar HernandezAuthor Commented:
where would i find the rectanglebeveled6

Module  or others ?
0
 
Omar HernandezAuthor Commented:
I have found it, but i want the same color you have created to stay put on the whole column "K" through "M"


Look at this pic just like this

row.png
0
 
Martin LissOlder than dirtCommented:
Is this what you want?

If I click on a cell in, say, row 20
I press the button
o Range K5:M105 (or whatever the last row is) changes color to orange
o Range A20:J20 turns white
o I click a cell in any other row, say, row 30
o Range A30:J30 turns yellow and range K30:M30 stays orange
0
 
Omar HernandezAuthor Commented:
I hope this work Martin Liss

The file when i open it looks like this, without me clicking on any cell.

---Notice how the column all has a "Fill Color" of white.

The-file-when-i-open-it-looks-like-t.png
I want the file to look like this when i open it.

---Notice now how the "K", "L" and "M" has a "Fill Color" of (Orange, Accent 1, Lighter 60%

the-way-i-want-the-file-looking-like.png
I want the file to look like this when i click on it.

The-way-i-want-the-file-to-look-when.png
0
 
Martin LissOlder than dirtCommented:
It would be a lot ester for me to understand what you want if you would describe your requirements like I did in post ID: 41856291, but take a look at this.
28978276b.xlsm
0
 
Omar HernandezAuthor Commented:
Please check out this video it will be much clearer.

https://www.youtube.com/watch?v=yv_VIfrz7Us&feature=youtu.be
0
 
Martin LissOlder than dirtCommented:
OK I think I understand, but I have a new question. Once columns K:M are orange, how do they get back to normal? In other words if clicking row 20 makes range K20:M20 orange (along with most of the other cells in those columns), do they ever get back to being white, and if so, how?
0
 
Omar HernandezAuthor Commented:
Can we create a new Button to be right next to the button you have recently created.

Button ta say "ON" when having those three column in (ORANGE)

and

Button to say "OFF" when having all column in (WHITE)

button-where-it-goes.png
0
 
Omar HernandezAuthor Commented:
Thanks a mill Martin Liss, the file is working great.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.