Page 1 of 1

Bug in Combobox

Posted: Sun Dec 18, 2005 9:45 pm
by Enrico Maria Giordano
In the following sample:

Code: Select all

#include "Fwce.ch"


FUNCTION MAIN()

    LOCAL oWnd, oCbx

    LOCAL aVar := { "A", "B", "C" }

    LOCAL cVar := ""

    DEFINE WINDOW oWnd

    @ 1, 1 COMBOBOX oCbx VAR cVar;
           ITEMS aVar

    oCbx:SetFocus()

    @ 3, 1 BUTTON "Change";
           ACTION ( oCbx:VarPut( "B" ), oCbx:Refresh() )

    ACTIVATE WINDOW oWnd

    RETURN NIL
if you click on the button you get the following error:

Message not found TCOMBOBOX:VARPUT

EMG

Posted: Sun Dec 18, 2005 10:22 pm
by Antonio Linares
Enrico,

This method was missing from Class TControl:

Code: Select all

   METHOD VarPut( uVal ) INLINE  If( ValType( ::bSetGet ) == "B",;
                                 Eval( ::bSetGet, uVal ),)
Already implemented for the next build.

Posted: Mon Dec 19, 2005 7:41 am
by Enrico Maria Giordano
Thank you!

EMG