Skip to Content
avatar image
Former Member

how to assign one ALV component to different view container

Hi experts,

how to assign one ALV TABLE control to different viewContainerUIelement

my problem is I have a tab strip with 3 tab's , each have one viewContainerUIelement , now I want to use the same ALV TABLE compenet for the three tab's

is it possible to embed the alv compenent dynamically to the viewcontainer element ?

I am using salv_wd_table

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Feb 19, 2010 at 02:28 PM

    are all tabs showing the same set of data, if yes then it doesn't makes sense to create 3 diff views, instead create one only

    If all the 3 diff tabs are supposed to show diff set of data then you have to create 3 diff ALV usages..

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi Akash,

      One thing you can do with seperate ALV usages to improve performance is that only on change of tab you call the method of that particular ALV to fill data and set an extra flag to check only when some selection criteria is changed then you only you call the method to fill data again otherwise not.

      So, only when tabs are loaded first time it should take time..and that too the load is for filling data and not for ALV configuration.

      Check you domodifyview method and debug it.

  • avatar image
    Former Member
    Feb 22, 2010 at 06:50 AM

    Hi Akash,

    It is possible to achieve this. have a single node which is mapped to the data node of ur ALV used compoenent.

    Now on the tab select u can fetch the data and bind ur data to the node.

    but using a single ALV will leads to lot of problem, like when u are selecting any value from the ALV output then it would not be possible to know which tab's row is selected.

    Preferred solution is to use the different ALV for different tab's.

    If u are just displaying tha data and want to use basic functionality of ALV then only go for single ALV.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi,

      Follow these steps:

      1. Create 3 views - V1 , V2, V3.

      2. In all the three views embed Viewcontianere.

      3. Inside these vieContainer , embed ALV view.

      4. Now create a tabstrip with threee tabs T1 T2 T3.

      5. Inside T1 create a viewcontainer VC1 .

      6. And similarly for other tabs , Vc2 , VC3.

      7. Embel V1 into tab T1's ViewContainer VC1 and others also in a similar way.

      I hope now it is clear.

  • avatar image
    Former Member
    Feb 22, 2010 at 08:28 AM
    Add comment
    10|10000 characters needed characters exceeded