-
Manipulating Excel cell comments in VBA and with DB Data
Hi Guys,
Is there a way I can programmatically manipulate Excel individual Cell comments with VBA Code? If so, I also want then to be able to put Notes (loaded from an ADO Recordset Field) into such Cells' comments and even sometimes upload data/text in such Cell comments into the database.
Looking forward to your assistance!
Deyken
DeezineTek
South Africa
-
To add comment
[vba]
Range("a1").AddComment "hai"
[/vba]
To get Comment text
[vba]
Dim T_Str As String
T_Str = Range("a1").Comment.Text
[/vba]
Note:I f you add comment to particular cell which has already comment that will raise error in such case delete the comment (Range("a1").ClearComments) and add the new comment
-
It really depends what you want to do.
You can add to existing comments, extract all the comments from a group of cells and store them somewhere
Both of which, and more, could be combined with ADO to work with external data.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules