VBA Question (Automate Ctrl + F, Ctrl + Copy, Ctrl + Paste)

FirmanHassan

New Member
Joined
Mar 28, 2022
Messages
1
Office Version
  1. 365
Platform
  1. Windows
Hi All

I have a workbook, and I have included comments throughout the workbook symbolised with "xxxFH: comment", in which the comment varies depending on what I'm trying to comment on in that specific row. I've got a lot of them throughout the workbook.

I've basically included an additional sheet called "COMMENTS" and what I'd like to do is to build a Macro that would search all cells that contain the value (including but not exclusively) "xxxFH" and paste the cells into this sheet. There are a lot of xxxFH comments at the moment, so I would like to be able to paste all of these xxxFH comments in a column (consecutive row order) in the COMMENTS sheet. If possible, it would also be really great if instead of just pasting the values, I would be pasting the cell which links directly to the referenced xxxFH cell, so I can CTR: + [ to the relevant xxxFH cell in the relevant worksheet.

I've added a mini sheet to show what exactly I'm looking for.

Comment.xlsx
ABCDEFGHIJKLMNOPQRSTUVWX
1
2Comments
3Paste below
4xxxFH: please deleteMy idea is to be able to find xxxFH comments throughout the workbook, and paste it like this, not just cell values, but also referencing/linking the cell on where it is currently located.
5xxxFH: replicateI have kept these comments in the same sheet at the moment only for example purposes, but in a realistic environment, these comments would be in another sheet
6xxxFH: check
7
8
9
10
11xxxFH: please delete
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26xxxFH: replicate
27
28
29
30
31xxxFH: review
32
33
34
35
36
37
38
39xxxFH: check
40
41
42
43
44
45xxxFH: workin in progress
46
47
48
49xxxFH: please delete
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64xxxFH: replicate
65
66
67
68
69xxxFH: review
70
71
72
73
74
75
76
77xxxFH: check
78
79
80
81
82
83
COMMENTS
Cell Formulas
RangeFormula
B4B4=COMMENTS!H11
B5B5=COMMENTS!R26
B6B6=COMMENTS!P77



Any help would be really great!
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest

Forum statistics

Threads
1,223,227
Messages
6,170,848
Members
452,361
Latest member
d3ad3y3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top