Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
add comment to object
i never heard of a 'comment' property and you don't say what kind of object.
what i'll assume is you want to associate some sort of permanent text string? depending on the object, i sometimes i hijack another property for what I want. the TAG property (e.g., userforms, toolbar buttons) as easy when available sometimes its easy to use a custom document property, a name, a cell on a hidden sheet, or a registry entry (check out savesetting and getsetting fuctions) you can attach to any existing object model if you could create your own object: Public Type objWS sht As Worksheet myComment As String End Type Sub x() Dim s As objWS Set s.sht = Sheet1 s.myComment = "some text" Debug.Print s.sht.Name & " " & s.cmt End Sub HTH - voodooJoe "Ronbo" wrote in message ... How can I add a comment to an object? As always thanks for any help. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
add comment to object
How can I add a comment to an object?
As always thanks for any help. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
add comment to object
Not really following. Objects have properties (describe the object or an
attribute of the object) and methods (things the object can do). What do you mean by a comment. Additionally is this object one of the existing Objects from Excel (such as a sheet or a range) or is this a custom object you created by instantiating a class that you wrote? -- HTH... Jim Thomlinson "Ronbo" wrote: How can I add a comment to an object? As always thanks for any help. |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
add comment to object
If you mean a shape on the worksheet, maybe you can widen the column, increase
the row height and put a comment on that cell that is below that object. You'll see the comment when your mouse is over the cell, but not over the shape. Ronbo wrote: How can I add a comment to an object? As always thanks for any help. -- Dave Peterson |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
add comment to object
Sorry for the bad question.
Thanks for the help. I want to find a way that I can create a help button (a text box named "rectangle 13") so that if the user needs help on the tem, they can click on the help object and a help screen like a comment will popup. I have an Object = Rectangle 13. To it i added a macro "a" macro "a" = ActiveSheet.Shapes("Rectangle 13").Comment.Text Text:="Test" & Chr(10) & "" I hope this helps some. Again, Thanks for the help "Dave Peterson" wrote: If you mean a shape on the worksheet, maybe you can widen the column, increase the row height and put a comment on that cell that is below that object. You'll see the comment when your mouse is over the cell, but not over the shape. Ronbo wrote: How can I add a comment to an object? As always thanks for any help. -- Dave Peterson |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
add comment to object
You could assign a macro to that rectangle (just rightclick on it and choose
assign macro). If the amount of words is small, you could use a message box: option explicit sub testme() msgbox "Your help text here" end sub If the amount of words is large, you could create your own user form and show that. John Walkenbach has done lots of the work for you: http://j-walk.com/ss/excel/tips/tip51.htm Ronbo wrote: Sorry for the bad question. Thanks for the help. I want to find a way that I can create a help button (a text box named "rectangle 13") so that if the user needs help on the tem, they can click on the help object and a help screen like a comment will popup. I have an Object = Rectangle 13. To it i added a macro "a" macro "a" = ActiveSheet.Shapes("Rectangle 13").Comment.Text Text:="Test" & Chr(10) & "" I hope this helps some. Again, Thanks for the help "Dave Peterson" wrote: If you mean a shape on the worksheet, maybe you can widen the column, increase the row height and put a comment on that cell that is below that object. You'll see the comment when your mouse is over the cell, but not over the shape. Ronbo wrote: How can I add a comment to an object? As always thanks for any help. -- Dave Peterson -- Dave Peterson |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
add comment to object
Dave: Thanks for your responses. The first response would work, in a round
about way. The MsgBox was an option, however I have not made professional looking MsgBoxes (long ones) and it is a large amount of words. In my initial research I started with Walkenbach's Chapter 23 "Providing Help for Your Applications" from his book Excel 2000 Power Programming w/ VBA. I thought there would be easier ways such as attaching a comment to a object/shape. I will go from here, to the site you led me to. Again thanks you and the others for your time and help. "Dave Peterson" wrote: You could assign a macro to that rectangle (just rightclick on it and choose assign macro). If the amount of words is small, you could use a message box: option explicit sub testme() msgbox "Your help text here" end sub If the amount of words is large, you could create your own user form and show that. John Walkenbach has done lots of the work for you: http://j-walk.com/ss/excel/tips/tip51.htm Ronbo wrote: Sorry for the bad question. Thanks for the help. I want to find a way that I can create a help button (a text box named "rectangle 13") so that if the user needs help on the tem, they can click on the help object and a help screen like a comment will popup. I have an Object = Rectangle 13. To it i added a macro "a" macro "a" = ActiveSheet.Shapes("Rectangle 13").Comment.Text Text:="Test" & Chr(10) & "" I hope this helps some. Again, Thanks for the help "Dave Peterson" wrote: If you mean a shape on the worksheet, maybe you can widen the column, increase the row height and put a comment on that cell that is below that object. You'll see the comment when your mouse is over the cell, but not over the shape. Ronbo wrote: How can I add a comment to an object? As always thanks for any help. -- Dave Peterson -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Inserting word object - Missing the comment feature in ribbon | New Users to Excel | |||
How can I edit a comment w/o first having to select Show Comment | Excel Discussion (Misc queries) | |||
What is the deal with Comment Object Positioning? | Excel Discussion (Misc queries) | |||
Attach comment to object | Excel Worksheet Functions | |||
a comment plugin & copy paste directly from excel to comment ? fr. | Excel Worksheet Functions |