Share this page

# Example: sapgui_grid_set_column_order

The following example shows the use of sapgui_grid_set_column_order.

        // Run the sample

        sapgui_set_ok_code("/nme51n", LAST );
        sapgui_press_button("ENTER",
            "tbar[0]/btn[0]", LAST );

        // Drag a column to a new position

        sapgui_grid_set_column_order("(CtrlGrid)", "usr/subSUB0:SAPLMEGUI:0016/subSUB2:SAPLMEVIEWS:1100/subSUB2:SAPLMEVIEWS:1200/subSUB1:SAPLMEGUI:3212/cntlGRIDCONTROL/shellcont/shell",
            "STATUSICON",
            "BNFPO",
            "MENGE",
            "KNTTP",
            "EPSTP",
            "MATNR",
            "TXZ01",
            "MEINS",
            "ELPEI",
            "EEIND",
            "WGBEZ",
            "NAME1",
            "LGOBE",
            "EKGRP",
            "AFNAM",
            "BEDNR",
            "LIFNR",
            "FLIEF",
            "RESWK",
            "EKORG",
            "KONNR",
            "KTPNR",
            "INFNR",
            "EMATN",
            BEGIN_OPTIONAL,
                "AdditionalInfo=sapgui1013",
            END_OPTIONAL);
    sapgui_grid_set_column_order("(CtrlGrid)",
    "usr/subSUB0:SAPLMEGUI:0016/subSUB2:SAPLMEVIEWS:1100/subSUB2:SAPLMEVIEWS:1200/subSUB1:SAPLMEGUI:3212/cntlGRIDCONTROL/shellcont/shell",
            "STATUSICON",
            "BNFPO",
            "MATNR",
            "MENGE",
            "KNTTP",
            "EPSTP",
            "TXZ01",
            "MEINS",
            "ELPEI",
            "EEIND",
            "WGBEZ",
            "NAME1",
            "LGOBE",
            "EKGRP",
            "AFNAM",
            "BEDNR",
            "LIFNR",
            "FLIEF",
            "RESWK",
            "EKORG",
            "KONNR",
            "KTPNR",
            "INFNR",
            "EMATN",
            LAST );

Tips to improve your search results... VuGen Function Reference Version 25.1-25.3 Function Reference 25.1-25.3 All View Local Help Center View Online Help Center Version: