<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Popup for selection with sorting capability? in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963441#M67968</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I found out the FM ALV_LIST_SORTING_DEFINE, try to call it, you can see it should be the one you need.( I_TYPE = 'S')&lt;/P&gt;&lt;P&gt;But I'm still not clear how to fill its paramter. &lt;/P&gt;&lt;P&gt;Maybe you can reference the standard sap code.&lt;/P&gt;&lt;P&gt;I will continue the research when I'm free.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope my reply is helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 11 Aug 2005 16:57:33 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2005-08-11T16:57:33Z</dc:date>
    <item>
      <title>Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963439#M67966</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm looking for a functional module showing a pop up window where a user can choose among any number of items. Moreover the user can sort selected values. I mean a capability to define the selected values order. I need functionality similar to choosing ALV sort criteria (LVC_SORT_DIALOG).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 15:07:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963439#M67966</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-08-11T15:07:55Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963440#M67967</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Mikola - I don't know of any FM to help out here. But I did exactly this a while ago. It involved creating a new window with a new status when the user requested the sort and then making the sort order field input on. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When the user pressed enter in the new window, I had to read in the report (from the new window), evaluate the input and pass it to a sort.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Not pretty, but it works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 16:25:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963440#M67967</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-08-11T16:25:26Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963441#M67968</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I found out the FM ALV_LIST_SORTING_DEFINE, try to call it, you can see it should be the one you need.( I_TYPE = 'S')&lt;/P&gt;&lt;P&gt;But I'm still not clear how to fill its paramter. &lt;/P&gt;&lt;P&gt;Maybe you can reference the standard sap code.&lt;/P&gt;&lt;P&gt;I will continue the research when I'm free.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope my reply is helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 16:57:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963441#M67968</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-08-11T16:57:33Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963442#M67969</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, there is some code in FM LVC_FILTER_990927, should how to call ALV_LIST_SORTING_DEFINE.&lt;/P&gt;&lt;P&gt;I paste parts of them as following:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
          DATA: LS_CONTROL_KKBLO TYPE KKBLO_CONTROL.
          DATA: LT_FIELDCAT_KKBLO TYPE KKBLO_T_FIELDCAT.
          DATA: LT_SORT TYPE KKBLO_T_SORTINFO.
          LS_CONTROL_KKBLO-LISTTYPE = 'S'.
          IF LS_CONTROL_KKBLO-LISTTYPE = 'S'.
            LS_CONTROL_KKBLO-HEADER_TEXT  = 'H'.
          ELSE.
            LS_CONTROL_KKBLO-HEADER_TEXT  = 'H'.
          ENDIF.

          CALL FUNCTION 'LVC_FILTER_TO_SORT'
               EXPORTING
                    IT_FILTER = CT_FILTER[]
               CHANGING
                    CT_SORT   = LT_SORT.
          CALL FUNCTION 'LVC_TRANSFER_TO_KKBLO'
            EXPORTING
                 IT_FIELDCAT_LVC           = IT_FIELDCAT
*            IT_SPECIAL_GROUPS_LVC     = GT_GROUPS
            IMPORTING
                 ET_FIELDCAT_KKBLO         = LT_FIELDCAT_KKBLO
*            ET_SPECIAL_GROUPS_KKBLO   = LT_KKBLO_GROUPS
*        TABLES
*             IT_DATA                   =
*        EXCEPTIONS
*             IT_DATA_MISSING           = 1
*             IT_FIELDCAT_LVC_MISSING   = 2
*             OTHERS                    = 3
                  .

          CALL FUNCTION 'ALV_LIST_SORTING_DEFINE'
            EXPORTING
                I_CONTROL       = LS_CONTROL_KKBLO
                IT_FIELDCATALOG = LT_FIELDCAT_KKBLO
                I_TYPE          = 'F'
*       IMPORTING
*            E_EXIT          = G_MEMO
            CHANGING
                CT_SORT         = LT_SORT[]
            EXCEPTIONS
                NO_CHANGE       = 1
                OTHERS          = 2.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think write you code simulatively, your problem will be solved. If further problem, make me know.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 17:05:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963442#M67969</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-08-11T17:05:51Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963443#M67970</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here is some sample coding for the mentioned function module.  It works as far as returning the users inputs, but if you try to move fields to the other column, it breaks.   Give it a try.  By the way,  Nice work Zhenglin.  If i knew this was out there, i would have used it many times already.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

report zrich_0002 .

type-pools: kkblo.

data: begin of itab occurs 0,
      fielda(10) type c,
      fieldb(10) type c,
      fieldc(10) type c,
      end of itab.

data:
  kkblo_control type kkblo_control,
  it_fieldcat type kkblo_t_fieldcat,
  wa_fieldcat type kkblo_fieldcat,
  it_sort type  kkblo_t_sortinfo,
  wa_sort type kkblo_sortinfo.

clear wa_fieldcat.
wa_fieldcat-fieldname = 'FIELDA'.
wa_fieldcat-tabname = 'ITAB'.
append wa_fieldcat to it_fieldcat.

clear wa_fieldcat.
wa_fieldcat-fieldname = 'FIELDB'.
wa_fieldcat-tabname = 'ITAB'.
append wa_fieldcat to it_fieldcat.

clear wa_fieldcat.
wa_fieldcat-fieldname = 'FIELDC'.
wa_fieldcat-tabname = 'ITAB'.
append wa_fieldcat to it_fieldcat.


clear wa_sort.
wa_sort-spos = '1'.
wa_sort-fieldname = 'FIELDA'.
wa_sort-seltext   = 'Field A'.
wa_sort-tabname   = 'ITAB'.
wa_sort-up = 'X'.
append wa_sort to it_sort.

clear wa_sort.
wa_sort-spos = '3'.
wa_sort-fieldname = 'FIELDB'.
wa_sort-seltext   = 'Field B'.
wa_sort-tabname   = 'ITAB'.
wa_sort-down = 'X'.
append wa_sort to it_sort.

clear wa_sort.
wa_sort-spos = '2'.
wa_sort-fieldname = 'FIELDC'.
wa_sort-seltext   = 'Field C'.
wa_sort-tabname   = 'ITAB'.
append wa_sort to it_sort.




call function 'ALV_LIST_SORTING_DEFINE'
  exporting
    I_CONTROL             = kkblo_control
    it_fieldcatalog       = it_fieldcat
    i_type                = 'S'
* IMPORTING
*   E_SAVE                =
*   E_EXIT                =
  changing
    ct_sort               = it_sort
 exceptions
   no_change             = 1
   program_error         = 2
   others                = 3
          .
check sy-subrc  = 0.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 17:18:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963443#M67970</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2005-08-11T17:18:44Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963444#M67971</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Got it working..... I needed to set a field in the field catalog.  Check out this code.  Here you can move stuff from the one column to the other and back allow you to change the sequence and the sort order.  This is really working good.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

report zrich_0002 .

type-pools: kkblo.

data: begin of itab occurs 0,
      fielda(10) type c,
      fieldb(10) type c,
      fieldc(10) type c,
      end of itab.

data:
  kkblo_control type kkblo_control,
  it_fieldcat type kkblo_t_fieldcat,
  wa_fieldcat type kkblo_fieldcat,
  it_sort type  kkblo_t_sortinfo,
  wa_sort type kkblo_sortinfo.

clear wa_fieldcat.
wa_fieldcat-fieldname = 'FIELDA'.
&amp;lt;b&amp;gt;wa_fieldcat-seltext   = 'Field A'.&amp;lt;/b&amp;gt;
wa_fieldcat-tabname = 'ITAB'.
append wa_fieldcat to it_fieldcat.

clear wa_fieldcat.
wa_fieldcat-fieldname = 'FIELDB'.
&amp;lt;b&amp;gt;wa_fieldcat-seltext   = 'Field B'.&amp;lt;/b&amp;gt;
wa_fieldcat-tabname = 'ITAB'.
append wa_fieldcat to it_fieldcat.

clear wa_fieldcat.
wa_fieldcat-fieldname = 'FIELDC'.
&amp;lt;b&amp;gt;wa_fieldcat-seltext   = 'Field C'.&amp;lt;/b&amp;gt;
wa_fieldcat-tabname = 'ITAB'.
append wa_fieldcat to it_fieldcat.


clear wa_sort.
wa_sort-spos = '1'.
wa_sort-fieldname = 'FIELDA'.
wa_sort-seltext   = 'Field A'.
wa_sort-tabname   = 'ITAB'.
wa_sort-up = 'X'.
append wa_sort to it_sort.

clear wa_sort.
wa_sort-spos = '3'.
wa_sort-fieldname = 'FIELDB'.
wa_sort-seltext   = 'Field B'.
wa_sort-tabname   = 'ITAB'.
wa_sort-down = 'X'.
append wa_sort to it_sort.

clear wa_sort.
wa_sort-spos = '2'.
wa_sort-fieldname = 'FIELDC'.
wa_sort-seltext   = 'Field C'.
wa_sort-tabname   = 'ITAB'.
append wa_sort to it_sort.

call function 'ALV_LIST_SORTING_DEFINE'
  exporting
    i_control             = kkblo_control
    it_fieldcatalog       = it_fieldcat
    i_type                = 'S'
* IMPORTING
*   E_SAVE                =
*   E_EXIT                =
  changing
    ct_sort               = it_sort
 exceptions
   no_change             = 1
   program_error         = 2
   others                = 3
          .
check sy-subrc  = 0.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Rich Heilman&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Rich Heilman&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 17:25:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963444#M67971</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2005-08-11T17:25:01Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963445#M67972</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If these answers have helped you, please award points accordingly.  Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 18:57:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963445#M67972</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2005-08-11T18:57:36Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963446#M67973</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mikola&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please check the follwing links:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="515790"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="104504"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ashish Jain&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Aug 2005 20:10:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963446#M67973</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-08-11T20:10:32Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963447#M67974</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi, Rich.  Thanks for you supply for my former reply.&lt;/P&gt;&lt;P&gt;As the time difference, I read your code just now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Glad to hear it works good.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Aug 2005 02:57:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963447#M67974</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-08-12T02:57:39Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963448#M67975</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for own sorting in lists use fm &amp;lt;b&amp;gt;RKE_SORT_ELEMENTS&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Andreas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Aug 2005 05:44:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963448#M67975</guid>
      <dc:creator>andreas_mann3</dc:creator>
      <dc:date>2005-08-12T05:44:41Z</dc:date>
    </item>
    <item>
      <title>Re: Popup for selection with sorting capability?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963449#M67976</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i think you need to use FM &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; CALL FUNCTION 'POPUP_TO_CONFIRM'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;            TITLEBAR              = TB&lt;/P&gt;&lt;P&gt;            TEXT_QUESTION         = TQ&lt;/P&gt;&lt;P&gt;            TEXT_BUTTON_1         = TB1&lt;/P&gt;&lt;P&gt;            ICON_BUTTON_1         = IB1&lt;/P&gt;&lt;P&gt;            TEXT_BUTTON_2         = TB2&lt;/P&gt;&lt;P&gt;            ICON_BUTTON_2         = IB2&lt;/P&gt;&lt;P&gt;            DEFAULT_BUTTON        = DB&lt;/P&gt;&lt;P&gt;            DISPLAY_CANCEL_BUTTON = ''&lt;/P&gt;&lt;P&gt;            START_COLUMN          = 25&lt;/P&gt;&lt;P&gt;            START_ROW             = 6&lt;/P&gt;&lt;P&gt;            POPUP_TYPE            = PTYPE&lt;/P&gt;&lt;P&gt;       IMPORTING&lt;/P&gt;&lt;P&gt;            ANSWER                = ANSWER1.&lt;/P&gt;&lt;P&gt;  IF SY-SUBRC &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;HERE YOU WILL GET THERE BUTTON , THEY RETURN VALUE 'Y'...&lt;/P&gt;&lt;P&gt;JUST CHECK IT BY DOING&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WRITE SY-UCOMM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REGARDS&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Aug 2005 06:03:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/popup-for-selection-with-sorting-capability/m-p/963449#M67976</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-08-12T06:03:04Z</dc:date>
    </item>
  </channel>
</rss>

