If I dump that block of code into a cmd file, it works perfectly.

Here is the code:

============================================================
pause 1 using 'start'
set var vService text
set var vFund text
set var vCondition Text
set var vFullService Text
set var vBDate date
set var vEDate date
set var vBDateT text
set var vEDateT text

pause 1 using 'a'

DIALOG 'Enter Start Date||!99/99/0000;1;_' vBDateT=10 whtemp 1+
CAPTION 'Start Date' ICON Question at Center Center

DIALOG 'Enter End Date||!99/99/0000;1;_' vEDateT=10 whtemp 1+
CAPTION 'End Date' ICON Question at Center Center

-- Null Responses for service or funding source find all
DIALOG 'Enter The Service to Report On ' vService=10 whtemp 1+
CAPTION 'Service to Report' ICON Question at Center Center

DIALOG 'Enter The Funder' vFund=10 whtemp 1+
CAPTION 'Funder' ICON Question at Center Center

IF vService is null THEN
set var vCondition = 'All Services'
set var vService = '*'
set var vFullService = 'All Services'
ELSE
set var vFullService = DESCRIPTION from CODES_LISTS where +
ACTUAL_CODE = .vService
set var vCondition = .vFullService
set var vService = .vService + '*'
ENDIF
IF vFund is null THEN
set var vCondition = .vCondition + 'for All Funders'
set var vFund = '*'
set var vFullFund = 'All Funding Sources'
ELSE
set var vFullFund = DESCRIPTION from CODES_LISTS where +
ACTUAL_CODE = .vFund
set var vCondition = .vCondition + ' for ' + .vFullFund
set var vFund = .vFund + '*'
ENDIF
SET VAR vCondition = .vCondition + ' between ' + .vBDateT + ' and ' + .vEDateT
set var vBdate = .vBDateT
set var vEDate = .vEDateT


-- Should the report be based on Registration or Service provision
set var vWhichType = 'Registration'
edit using RegistOrService

if vWhichType = 'Registration' then
print Demographics where +
clientid in (select clientid from regist where +
servcode like .vService and fundsrce like .vFund and +
servreg bet .vbdate and .vedate)
Else
print Demographics where +
clientid in (select clientid from ir where +
REG_CODE like .vService and fundsrce like .vFund and +
DATE_SERV bet .vbdate and .vedate)
endif

--clear variables
clear var vService
clear var vFund
clear var vCondition
clear var vFullService
clear var vBDate
clear var vEDate
clear var vBDateT
clear var vEDateT


===========================================================
The pauses were put in for troubleshooting purposes. In the application, the database is opened at the beginning, and for the command file, I connected before I ran the file.


A. Razzak Memon wrote:


Kayza,

Are you able to run that block of code as an independent
ASCII file without -ERROR-s at the R> Prompt?

Could you post the *exact* code? If the file is too big,
send me a private e-mail at mailto:[EMAIL PROTECTED]

Very Best R:egards,

Razzak.


At 01:07 PM 10/18/2004 -0400, Kayza Kleinman wrote:

The rest of the application works just fine, even with
this block. It is JUST this one call that does not work,
when running in normal mode, as opposed in trace.

A. Razzak Memon wrote:

At 11:59 AM 10/18/2004 -0400, Kayza Kleinman wrote:

Tried it. Doesn't work


Kayza,

What happens if you take out the *new* code you have
inserted. Does your application work as it should
without it?

Very Best R:egards,

Razzak.




--

Kayza Kleinman

Director, Nonprofit Helpdesk

Jewish Community Council of Greater Coney Island, Inc.

3001 West 37th Street

Brooklyn, NY 11224

Tel. 718 449-5000

Fax 718 946-8240

[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>

www.nphd.org <http://www.nonprofithelpdesk.org/>

“Putting Technology to Work For You”



Reply via email to