Revit API Forum
Welcome to Autodesk’s Revit API Forums. Share your knowledge, ask questions, and explore popular Revit API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

PickObjects() string argument as a "tooltip" balloon

2 REPLIES 2
Reply
Message 1 of 3
sroswurm4GJQU
339 Views, 2 Replies

PickObjects() string argument as a "tooltip" balloon

sroswurm4GJQU
Advocate
Advocate

Anyone who has used the PickObjects() method to get multiple element selections from a user is probably familiar with the optional overload to write a string to the Revit status bar (https://www.revitapidocs.com/2020/ee21d076-057b-f334-70a6-e0dab1d2ac4e.htm )

 

 

public IList<Reference> PickObjects(
	ObjectType objectType,
	string statusPrompt
)

 

 

When you provide a string in this method, it gets written to the Revit status bar in the lower left of the main Revit window, as expected. 

 

However I also notice that on only the first use in a given Revit session, the string also appears in a balloon next to the cursor while awaiting user selection:

 

sroswurm4GJQU_0-1636053601851.png

 

I'm actually a big fan of this behavior, because it helps give the user instructions directly in the view without having to rely purely on the status bar.  I'd love to take advantage of it, but it doesn't seem to be stable.  After one use of the method in a given session, the string populates only in the status bar for subsequent uses.

 

I'd love to hear from Autodesk or from anyone else who has worked extensively with this method.

 

Is the "tooltip" balloon on the cursor an intended behavior?  If so, is there anything we can do to make it work reliably/consistently when repeatedly triggering PickObjects() actions?

PickObjects() string argument as a "tooltip" balloon

Anyone who has used the PickObjects() method to get multiple element selections from a user is probably familiar with the optional overload to write a string to the Revit status bar (https://www.revitapidocs.com/2020/ee21d076-057b-f334-70a6-e0dab1d2ac4e.htm )

 

 

public IList<Reference> PickObjects(
	ObjectType objectType,
	string statusPrompt
)

 

 

When you provide a string in this method, it gets written to the Revit status bar in the lower left of the main Revit window, as expected. 

 

However I also notice that on only the first use in a given Revit session, the string also appears in a balloon next to the cursor while awaiting user selection:

 

sroswurm4GJQU_0-1636053601851.png

 

I'm actually a big fan of this behavior, because it helps give the user instructions directly in the view without having to rely purely on the status bar.  I'd love to take advantage of it, but it doesn't seem to be stable.  After one use of the method in a given session, the string populates only in the status bar for subsequent uses.

 

I'd love to hear from Autodesk or from anyone else who has worked extensively with this method.

 

Is the "tooltip" balloon on the cursor an intended behavior?  If so, is there anything we can do to make it work reliably/consistently when repeatedly triggering PickObjects() actions?

Tags (1)
2 REPLIES 2
Message 2 of 3

jeremy_tammik
Autodesk
Autodesk

Cool observation, very valid question. Looks strange and not completely intentional to me. I asked the development team for you.

 

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
0 Likes

Cool observation, very valid question. Looks strange and not completely intentional to me. I asked the development team for you.

 

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
Message 3 of 3

sroswurm4GJQU
Advocate
Advocate

Thanks, Jeremy! 

I'll look forward to hearing what you find out.

0 Likes

Thanks, Jeremy! 

I'll look forward to hearing what you find out.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report