JohnC Expert Licensed User Longtime User Aug 2, 2016 #1 I am using this cool grid from thedesolatesoul: https://www.b4x.com/android/forum/threads/msdynamicgridview-library.49331/ Am I am trying to make a popup menu to pop up over the cell that the user long-clicks on. But if I use the ACMenu popup menu: Code: Copy Sub DG_ItemLongClick(Position As Int) Dim Pop As ACPopupMenu Pop.Initialize("Popup", DG ) Pop.AddMenuItem(1, "Delete", Null) Pop.AddMenuItem(2, "Rearrange", Null) Pop.Show End Sub The menu will popup near the grid's top left corner and not above the cell being long-clicked. This must be because I passed "DG" (the datagrid) as the view for the popup menu. So, it there a way to detect the view under the user's finger that I can pass to the popup routine so it will make the menu appear over the cell the user is touching?
I am using this cool grid from thedesolatesoul: https://www.b4x.com/android/forum/threads/msdynamicgridview-library.49331/ Am I am trying to make a popup menu to pop up over the cell that the user long-clicks on. But if I use the ACMenu popup menu: Code: Copy Sub DG_ItemLongClick(Position As Int) Dim Pop As ACPopupMenu Pop.Initialize("Popup", DG ) Pop.AddMenuItem(1, "Delete", Null) Pop.AddMenuItem(2, "Rearrange", Null) Pop.Show End Sub The menu will popup near the grid's top left corner and not above the cell being long-clicked. This must be because I passed "DG" (the datagrid) as the view for the popup menu. So, it there a way to detect the view under the user's finger that I can pass to the popup routine so it will make the menu appear over the cell the user is touching?
Erel B4X founder Staff member Licensed User Longtime User Aug 2, 2016 #2 I'm not familiar with this library. However can't you get the view that is inside the clicked cell? Upvote 0
JohnC Expert Licensed User Longtime User Aug 2, 2016 #3 I've been trying and I can't figure out how to get any view from the selected grid. "Sender" returns a "non android.view.view" case error, so that won't work either. Upvote 0
I've been trying and I can't figure out how to get any view from the selected grid. "Sender" returns a "non android.view.view" case error, so that won't work either.