This is a migrated thread and some comments may be shown as answers.

ContextMenu position changes

0 Answers 80 Views
TreeListView
This is a migrated thread and some comments may be shown as answers.
Manishkumar
Top achievements
Rank 1
Manishkumar asked on 12 Sep 2011, 02:24 PM
Hi,
I am using context menu in my page. I have defined in following way.

<

 

telerik:RadTreeListView x:Name="rtlvPeopleInfo" >

 

 

 

<!--Context Menu-->

 

 

 

<telerik:RadContextMenu.ContextMenu>

 

 

 

<telerik:RadContextMenu x:Name="radPeopleContextMenu" Opened="radPeopleContextMenu_Opened" >

 

 

 

<telerik:RadMenuItem x:Name="rmiAssign_Engineer" Header="Assign Engineer"/>

 

 

 

</telerik:RadContextMenu>

 

 

 

</telerik:RadContextMenu.ContextMenu>

 

 

 

<telerik:RadTreeListView.Columns>

 

 

 

<telerik:GridViewDataColumn Header="Future Hrs" TextAlignment="Right"/>

 

 

 

<telerik:GridViewDataColumn Header="Previous Hrs" TextAlignment="Right"/>

 

 

 

</telerik:RadTreeListView.Columns>

 

 

 

</telerik:RadTreeListView>

Whenever I normally right click on any cell then it opens correctly and that is fine. But my requirement was if there is any unsaved data on page by cell edit, then when user right click on other cell it should show a message that "User changes will be lost, do u want to continue?". If yes then open the context menu as it is. So when there is any change on page then I show a messagebox with above confirmation message. Now if user selects "Yes" then the context menu opens on the top most left corner of the TreeListView, not on the cell right clicked. Please help me how I will open on same position the user mouse clicked, not the topmost left corner.

So the problem arises only when i open the messagebox confirmation.

 

No answers yet. Maybe you can help?

Tags
TreeListView
Asked by
Manishkumar
Top achievements
Rank 1
Share this question
or