On Mon, 2006-01-09 at 20:25 -0500, Ampere K. Hardraade wrote: > On January 9, 2006 04:19 pm, Curtis L. Olson wrote: > > In nasal, I would like to check if a string ends in '.wav'. Is there an > > easy way to do this? > > > > Thanks, > > > > Curt. > > You can try this: > > substr(foo, size(foo) - 5) == ".wav" > > Ampere
Ampere, should that be substr(foo, size(foo) - 4) == ".wav" as - 5 will compare the last five characters in the string? Anyway, I'm sure that it is just a typo but bound to confuse someone reading email or the archive. Regards George ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click _______________________________________________ Flightgear-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/flightgear-devel

