Some Foolish questions

Ken Ray kray at sonsothunder.com
Tue Oct 4 16:26:19 EDT 2005


On 10/4/05 3:10 PM, "Fred Giannetto" <fgiannet at hotmail.com> wrote:

> Hello Everyone,
> 
> 1) Absolute value question.  Here is a copy of the script.
> I want input values over 10 to create a deficit in the Consumer and Foreign
> fields.  Example, a user puts 15 into the Reserves field.  It is subtracted
> from 20 putting the remainder into tReserves.  tReserves is less then 10 so
> it has 10 subtracted from it, it is divided by 2 resulting in -2.5 into
> tConsumer but I only see 2.5.

Well, the script puts 'tShortfall / 2 into tConsumer', which would put -2.5
into tConsumer, but when it goes into the field, you have 'put -tConsumer
into field "Consumer"', which puts "2.5" into fld "Consumer" because:

    -tConsumer

is the same as 

    -1 * tConsumer

which is:

    -1 * -2.5  =  2.5

So I think if you set it to put "tConsumer" instead of "-tConsumer" you
should get what you're expecting.

> 2.  I am using the database property "move to previous record" for the
> previous record button and it is setup to access the correct query.  I have
> created two queries using Microsoft Access driver and Microsoft do Access
> driver.  I have attempted to connect with both of them and they exhibit the
> same symptoms.  I can only go forward and refresh.  The MySQL connection
> works without any problems.

What happens when you try to go to the previous record what happens - do you
stay on the current one? Or do you get some other result?


Ken Ray
Sons of Thunder Software
Web site: http://www.sonsothunder.com/
Email: kray at sonsothunder.com




More information about the use-livecode mailing list