I'm creating my first gantt chart project, and I'm trying to have functionality such that when you right click on a taskbar element in the chart, a context menu comes up and you can change things about the task. I know it can be done, because it's similar to the tooltip for a given task bar element. I just dont know how.
thanks
Hello clgroce,
Could you please review the sample attached to this post and see if it meets your requirements.Please feel free to let me know if I misunderstood you or if you have any other questions.
That Is exactly what I was looking for, thank you. However, this does not work if there is text inside the bar element.
Thank you for noticing this. Please try using 'TaskBarTextUIElement' instead of 'TaskBarUIElement' in all the places in the code where I am using it, I will be waiting for your feedback.
How do I get the 'TaskBarUIElement' associated with the 'TaskBarTextUIElement'? I'm trying to create different options in the context menu based on the color of the 'TaskBarUIElement'.
Hello again,
No worries. We might have had some misunderstandings here and I am glad to hear that you were able to solve this. Please feel free to let me know if a question about our toolset comes up on your mind.
I'm not sure what I was missing before, but it works now. Thank you for your help and patience.
Hello,
I tested getting this 'BackColor' from the 'TaskBarTextUIElement' and it works fine for me. What other color do you want?
RIght. If i get the TaskBarUIElement, then everything works great and I can check the color, but if the element the mouse enters is a TaskBarTextUIElement, then I dont have the TaskBarUIElement only the TaskBarTextUIElement. So how do I get the TaskBarUIElement associated with the TaskBarUITextElement when all I have is the TaskBarUITextElement?
I am not sure that I am following you here. You might be looking for:
'currentTask.Task.TimelineSettings.BarSettings.BarAppearance.BackColor'
Is that right? Ot you need something else, please let me know.