TADVStringgrid Dropdown a TFrame?

I have been requested to make a TFrame that is quite interactive.

They want it to be a drop down item from the grid on certain cells.

So click drop down arrow, TPanel/TFrame pops up ( above, below, left, right where ever to keep it in view and not over top of the active row your on )

Then click around in the TFrame, do whatever and click away from the TFrame and/or X button in the frame to signify the close.

I see types of edControlDropDown and edCustom but not 100% sure if these are related to what I need if what I need to do is even doable.

Any ideas? Any of the examples show this usage?

Ignore the uglyness of the mock up I was given, but this is the idea I was told to do.

I would suggest following:

  1. Use a TAdvControlDropDown as inplace editor for the grid. You can configure the TAdvControlDropDown to use any control as dropdown, so this could be a TPanel that hosts your fame.

  2. You can set this inplace editor type via edControlDropDown. It could be setup globally via:

  grid.DefaultEditor := edControlDropDown;
  grid.ControlDropDown.Control := yourpanel;

or dynamically via the OnGetEditorType / OnGetEditorProp events

I like the idea of OnGetEditorType and OnGetEditorProp events as I need to run code to do work before it shows the drop down, to stage up the frame.

I tried this and it did work. But some "issues" ive been trying to figure out

  1. the drop down arrow does not show for edControlDropDown until I click in the cell twice.
    First click does a text edit type edit? then 2nd click shows the drop down arrow to now click on.

  2. I need a button to "approve" / "ok" / "whatever" the action to do some work on the TFrame and close this edControlDropDown. Don't see a clean way to do this? Also clicking outside the drop down auto closes it. Which maybe ok, but I may need to do some work when that happens to the TFrame.

Little demo program I have to play around.

Grid.ControlLook.DropDownAlwaysVisible := true;
Grid.ControlLook.NoDisabledButtonLook := true;

Can see a column with drop down arrows visible. this is edComboList i set.
The far right column is the edControlDropDown. No drop down arrow visible on each cell.