cxgrid column customization

How do I show the popup window to drag and drop columns, on runtime?
Who is Participating?
Geert GConnect With a Mentor Oracle dbaCommented:
uh, finally got it
with a little magic:
uses cxGridPopupMenu;

  TcxGridPopupMenuHelper = class(TcxGridPopupMenu) end;

procedure TForm1.Button1Click(Sender: TObject);

Open in new window

Geert GOracle dbaCommented:
set customization to true
this will set enable a small button in the top left of the header
allowing you to hide/show columns

ColumnsMoving is to allow the columns to be reordered
danz67Author Commented:
I know this already, I am interested in seeing the window as the image attached, via runtime code
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Geert GOracle dbaCommented:
is it the grid popup menu / field chooser window you are referencing to ?
> add a cxGridPopupMenu
> set always fire on popup = true
> set grid to your grid

> right click on title column, field chooser
danz67Author Commented:
we're almost there, I saw that what I'm interested and Field Chooser, how do I open it at runtime?
danz67Author Commented:
no solution???
Geert GOracle dbaCommented:
use the way i described
and a cxGridPopUpMenu
and in those properties set grid to your grid

setting AllwaysFireOnPopup can also help

at runtime you right click on a column header and then select field chooser
danz67Author Commented:
I had already done this and understood, it is possible to display "field chooser" directly from code inside a button and not by right-clicking on the column?
Geert GOracle dbaCommented:
probably, i'd have to look in the source
hang on
danz67Author Commented:
ok, i wait, thanks
danz67Author Commented:
you really are a magician
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.