Hello!
I have a scenario where the end-user clicks an activex button after they've finished entering values in the top part of the sheet. When the activex button is clicked it currently does this:
This gets the job done (copies the range, opens notepad and pastes the range into notepad using sendkeys), but it's not what I want it to do exactly.
I would like it to copy some specific cells in the whole range (and those always stay the same, so they can be "hardcoded" by me later), while also I need it to search all the cells and copy all the ones that have the letters "bf" in them. These are the two criterias for searching, then I need the code to paste these mentioned cells in order from top to bottom into notepad like before.
Some of these cells in range C8:C458 contains plain text, others contain formulas such as in C35: =CONCAT("add ";C4;"") where the value of C4 sometimes will either have "bf" in it or be completely empty.
Please let me know if you need more information, I might've missed something I'm pretty new to VBA.
Thank you very much for your time and help.
Have a good day!
I have a scenario where the end-user clicks an activex button after they've finished entering values in the top part of the sheet. When the activex button is clicked it currently does this:
VBA Code:
Private Sub CommandButton5_Click()
Range("C8:C458").Copy
Shell "notepad.exe", vbNormalFocus
SendKeys "^V"
End Sub
This gets the job done (copies the range, opens notepad and pastes the range into notepad using sendkeys), but it's not what I want it to do exactly.
I would like it to copy some specific cells in the whole range (and those always stay the same, so they can be "hardcoded" by me later), while also I need it to search all the cells and copy all the ones that have the letters "bf" in them. These are the two criterias for searching, then I need the code to paste these mentioned cells in order from top to bottom into notepad like before.
Some of these cells in range C8:C458 contains plain text, others contain formulas such as in C35: =CONCAT("add ";C4;"") where the value of C4 sometimes will either have "bf" in it or be completely empty.
Please let me know if you need more information, I might've missed something I'm pretty new to VBA.
Thank you very much for your time and help.
Have a good day!