function word find_last by desc ( string char, source ) ! Written by Michael W. Wheeler (mww@tntech.bitnet) ! VAX Basic V3.1 ! Copyright (c) by Michael W. Wheeler, September 1987 ! This program is intended for Public Domain, and may not be sold or ! marketed in any form without the permision and written consent ! from the author Michael W. Wheeler. I retain all copyrights to ! this program, in either the original or modified forms, and no ! violation, deletion, or change of the copyright notice is ! allowed. Futhermore, I will have no liability or responsibilty ! to any user with respect to loss or damage caused directly or ! indirectly by this program. ! Labels ! none. ! Constants ! none. ! Types ! none. ! Variables declare word char_pos ! Procedures ! none. ! Functions ! none. char_pos = len(source) ! Find the last occurance of a character in a string. while (mid(source, char_pos, 1%) <> char) and (char_pos <> 0%) char_pos = char_pos - 1% next find_last = char_pos end function