Author Topic: Dynamic Find Request in Script  (Read 3341 times)

0 Members and 1 Guest are viewing this topic.

JAbbott

  • Member
  • Posts: 1
    • View Profile
Dynamic Find Request in Script
« on: December 02, 2008, 12:12:33 PM »
Having problems writing a script that will find records between 2 dates.

1) Establish global fields "Start Date" & "End Date" using Show Custom Dialog ... Works fine.
2) Enter Find Mode []
From here on I have problems.  Using "Set Field" the calculations will not allow a criteria establishing a range between Start and End Dates.  Nor will the Calc. parameter in the Perform Find statement.

Any ideas?

Thanks for your help!

syntencoist

  • Member
  • Posts: 7
    • View Profile
Re: Dynamic Find Request in Script
« Reply #1 on: January 10, 2011, 05:26:08 PM »
syntax as follows
label:if:then

input ("1","1") ds " Start Date: "
input ("2","1") de " End Date: "
lookup short_name = some_table i=a -nx
lp01:not short_name:goto lblnext
short_name lt ds: getnext short_name; goto lp01
short_name gt de: getnext short_name; goto lp01
msgbox ""{short_name(1)
getnext short_name; goto lp01
lblnext::

simplest and probably least efficient method, but it gets the job done.