>create cursor csrExchanges (Exchange C(40)) >insert into csrExchanges (Exchange) values ('All Exchanges') >insert into csrExchanges (Exchange) >select Exchange from SearchReport where Exchange IS NOT NULL >GROUP BY Exchange > >this.RowSouceType = 2 >this.RowSource = "csrExchanges" >>>I am trying to populate a combo box using the following code in COMBO INT() Method.
>>SELECT Distinct Exchange FROM SEARCHREPORT WHERE !ISNULL(Exchange) GROUP BY EXCHANGE INTO CURSOR EXCHANGEWISEOUTSTANDING >>This.RowSourceType= 0 >>WITH This >>.AddItem('All Exchanges') >> >>GO Top >>SCAN >>Browse >>.AddItem(Searchreport.exchange) >>ENDSCAN >>ENDWITH >>This.Requery() >>Thisform.Combo1.Refresh >>Thisform.combo1.ListItemId=1 >>>>
>>*Combo Valid >>IF ALLTRIM(Thisform.combo1.Value)='All Exchanges' >>SELECT searchreport >>SET FILTER TO >>ELSE >>SELECT searchreport >>SET FILTER TO Exchange=ALLTRIM(UPPER(thisform.combo1.Value)) >>ENDIF >> >>SUM PREVBAL TO Total_PREVBAL >>SUM LASTPAYAMT TO Total_LASTPAYAMT >>SUM ADJAMT TO Total_ADJAMT >>SUM CURCHARGE TO Total_CURCHARGE >>SUM ACNTBAL TO Total_ACNTBAL >>SUM AMTPAYABLE TO Total_AMTPAYABLE >>COUNT FOR DELETED()#.T. >>GO TOP >>Thisform.grdsorting1.Setfocus >>Thisform.Refresh >>***************** >>* Form INT() >>Select Searchreport >>SUM PrevBal TO Total_PrevBal >>SUM lastpayamt TO Total_lastpayamt >>SUM adjamt TO Total_adjamt >>SUM curcharge TO Total_curcharge >>SUM acntbal TO Total_acntbal >>SUM amtpayable TO Total_amtpayable >>SUM OSAMT TO Total_os >>Locate >>Thisform.grdsorting1.Refresh >>Thisform.Refresh >>****** >>*Form Setfilter() >>LPARAMETERS exchange >>SET FILTER to >>SET FILTER TO Exchange=ALLTRIM(UPPER(thisform.combo1.Value)) >>GO top >>Thisform.grdsorting1.Refresh >>thisform.Refresh >>>>.