funtions on windows

Alex Tweedly alex at tweedly.net
Fri Jul 15 07:03:05 EDT 2005


Muaadh salih wrote:

> My apology for the typos of yesterday message .
>  Still upon further investigation  we found that  the following function:
> -----------------
>
> function plural count, textw
>   if count <> 1 then put "s" after textw
>   if count = 0 then put "no" into count
>   return  count && textw
> end plural
> -------------------
>   works perfectly on Rev 2.6 on Mac G4 with OSX 10.3.9. However it 
> does not work on Rev. 2.6 on Windows XP ( when called : Plural ( 3, 
> "Book") it returns  ( 3 s) only
> again is this a bug on the XP version ?!

I created a new Mainstack, created a button, copied the above lines from 
your email, pasted them into the button script - and it works just fine. 
2.6 on Win XP

If it were me, I'd add
   "put param(1) && param(2) & cr  after msg" in as the first line of 
the function
   "put textw & cr after msg"   immediately before and immediately after 
the line that should change textw

and then see what I learn.  (or, as I said off-list, send me a copy of 
the stack - but be sure to send it from the Windows machine in case 
there was some problem copying the script from the Mac to the PC - line 
endings etc.).

-- 
Alex Tweedly       http://www.tweedly.net



-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.323 / Virus Database: 267.8.14/48 - Release Date: 13/07/2005




More information about the use-livecode mailing list