Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Searching by two fields
Message
From
20/09/2000 09:56:59
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Searching by two fields
Miscellaneous
Thread ID:
00418492
Message ID:
00418492
Views:
62
Hi Im am fairly new to vfp i am working on searching the table by two fields the first field is the date the second field is the shift .iam using a table view and i am able to make it search by the first field but it wont search by the second field. any suggestions here is the code i have been using

if LOOKUP (shift_form.sr_shift_date,thisformset.Form1.SR_SHIFT_DATE1.value,;
shift_form.sr_shift_date) = thisformset.Form1.SR_SHIFT_DATE1.value
if LOOKUP(shift_form.sr_shift_time,thisformset.Form1.SR_SHIFT_TIME1.value,;
shift_form.sr_shift_time) = thisformset.Form1.SR_SHIFT_TIME1.value
thisformset.form2.SR_SWITCH_TYPE1.value = shift_form.sr_switch_type
thisformset.form2.SR_SHIFT_DATE1.value = shift_form.sr_shift_date
thisformset.form2.SR_SHIFT_TIME1.value = shift_form.sr_shift_time
thisformset.form2.tech1.value = shift_form.sr_tech1
thisformset.form2.tech2.value = shift_form.SR_tech2
thisformset.form2.tech3.value = shift_form.SR_tech3
thisformset.form2.tech4.value = shift_form.SR_tech4
thisformset.form2.tech5.value = shift_form.SR_tech5
thisformset.form2.tech6.value = shift_form.SR_tech6
thisformset.form2.action.value = shift_form.SR_action
thisformset.form2.parties_cont.value = shift_form.SR_contacted
thisformset.form2.down_time.value = shift_form.SR_down_time
thisformset.form2.trouble.value = shift_form.SR_trouble
thisformset.form2.pro.value = shift_form.SR_Procedure
thisformset.form2.misc.value = shift_form.SR_misc
thisformset.form2.training.value = shift_form.SR_training
thisformset.form2.work_per.value =shift_form.SR_wrk_perfomed
thisformset.refresh()
thisformset.Form2.show
thisformset.Form1.hide
endif
else
Messagebox("No Records That Match,Enter New Record or Exit",48,"Message")
Thisformset.Form1.SR_SHIFT_DATE1.setfocus

endif
Next
Reply
Map
View

Click here to load this message in the networking platform