Subject |
using a query as variable : question does anyone some opinions about |
From |
Dirk C <dirk@C.com> |
Date |
Thu, 30 May 2024 21:00:14 +0200 |
Newsgroups |
dbase.getting-started |
Hello
the following is working, but like to have som opinion about
using thh query build on form or create a variable of a query
both are working, but i am wondering if to catch the variable is more stable
thanks for some information
Dirk,
function knop_zoek_onclick()
local c_Ref1, c_Waarde1, q_Cross, c_Ref2, c_Ref3
c_Waarde1 = this.parent.veld_Zoek.value
q_Cross = this.parent.vraagbak_artCon
if empty(c_waarde1)
msgBox("data ingeven", "***** bci dataverwerking *****", 48)
elseif not empty(c_Waarde1)
//q_cross.active = false
// q_cross.sql = form.vraagbak_zoek
// q_Cross.active = true
c_Ref1 = "conartikel1 ='"+c_Waarde1+"'"
q_Cross.rowset.beginlocate()
q_Cross.rowset.LocateOptions := 0
q_Cross.rowset.Applylocate(c_Ref1)
if q_Cross.rowset.Applylocate(c_Ref1)= false
// q_cross.active = false
// q_cross.sql = form.vraagbak_zoek
// q_Cross.active = true
c_Ref2 = "conartikel2 ='"+c_Waarde1+"'"
q_Cross.rowset.beginlocate()
q_Cross.rowset.LocateOptions := 0
q_Cross.rowset.Applylocate(c_Ref2)
if q_Cross.rowset.Applylocate(c_ref1) = false and
q_cross.rowset.ApplyLocate(c_ref2) = false
// q_cross.active = false
// q_cross.sql = form.vraagbak_zoek
// q_Cross.active = true
c_Ref3 = "conartikel3 ='"+c_Waarde1+"'"
q_Cross.rowset.beginlocate()
q_Cross.rowset.LocateOptions := 0
q_Cross.rowset.Applylocate(c_Ref3)
endif
endif
endif
if q_Cross.rowset.Applylocate(c_ref1) = false and
q_cross.rowset.ApplyLocate(c_ref2) = false ;
and q_cross.rowset.ApplyLocate(c_ref3) = false //
oss.rowset.endofSet
msgbox("geen data gevonden")
endif
return
*****
|
|