Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
880
Why is this not working?
posted

Hello: I am programmatically setting the stye and the value list in my application:

ugBED.DisplayLayout.Bands(0).Columns("Status_CD_C").Style = ColumnStyle.DropDownList

ugBED.DisplayLayout.Bands(0).Columns("Status_CD_C").ValueList = fvlStatus

But the second statement is raising an error, "ValueList.Appearances must be the same as the grid's layout.Appearances

 

fvlStatus is valid with 4 valueitems.

 

What am I doing wrong?

venki

 

  • 469350
    Offline posted

    Hi Venki,

    How are you creating 'fvlStatus'? My guess is that this ValueList belongs to some other control, and you are trying to use it for that other control and also for the grid. I don't think that will work. You can't share the same ValueList between multiple controls.

  • 715
    posted

    Hello vvenk,

    I tried this and it always works fine for me, so I attached my sample to this post for you. Please review it and If you experience different behavior, could you please attach a sample of your own, reproducing this issue or modify my sample in such way that your issue is reproducible and attach it back to the thread.

    Please feel free to let me know if I misunderstood you or if you have any other questions.

     

    WinGridValueList.zip