Balloons

G

Greg

Hi,

Is there a way to input text into a Balloon similiar to
the Office Assistant Search?

Thanks
 
C

Chad DeMeyer

Greg,

In a VBA project, insert a reference (Tools>References) to 'Microsoft Office
x.0 Library' where x is your version of office. Now open the Object Browser
and select the Office library. You can select Balloon in the list of
classes and press F1 for a starting point.

Regards,
Chad
 
B

Bryan

Dim nBalloon As Shape
Set nBalloon = ActiveDocument.Shapes.AddShape(msoShapeBalloon, 20, 20,
100, 100)
nBalloon.TextFrame.TextRange.Text = "Testing Text"

HTH!
....Bryan
 
G

Greg Maxey

Bryan,

Neat trick, but I was looking for a way to open and Office Assistant
balloon, type in text, and that text then be used as a variable in my macors
(I not even sure it is a macro now that I have learned about functions,
procedures, etc.) :)
 
G

Greg Maxey

Chad,

I have read heaps in the Help file. Maybe I am missing it. I am trying to
display a Balloon, type in some text to use in a search, then close the
balloon. This is similiar to finding help topics with the Office Assistant.
 
B

Bryan

Perhaps an inputbox can help...

dim aVar as String
aVar = Inputbox("Enter your value", "Title here", "Default Value")
'...Do Something with aVar
 
C

Chad DeMeyer

Greg,

If you'd already been through the help, then you were already ahead of me,
but I looked into it for curiosity's sake. It seems the only controls
supported on an office balloon created using VBA are labels and checkboxes.
There is no text entry control that could be used for getting string input.
Not willing to leave it at that, I did a test to see if
Assistant.AssistWithAlerts would cause the normal InputBox function to
display as a balloon, but no joy.

Regards,
Chad
 
G

Greg Maxey

Chad,

I had to use a UserForm for the text input. Seems logical that if the
technology is there to have a text input in the Assistant Search then it
could be available to VBA. Oh well.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top