--- I wrote:
> Perhaps I could poll the parameters string for one ASCII character
> that simply isn't used in the string, but what if by some chance this
> string actually uses all 256 ASCII characters?
> I suppose that this is a very far-fetched scenario. Even though, is
> that the only choice I have�� searching the string for a character
> that does not occur, and then wrapping that character around the
> string and prepending a question mark?
Assuming that it is, here's the code for it:
; ---
Local ScriptName = ?_ARB_
Local Alias = ?_ProcessThisText_
Local Parameters = ?_Do I have a "hamburger" of sorts? |'`/\*_
For(Local DelimCode = 2; DelimCode < 256; DelimCode = DelimCode + 1)
If(Not(Index(?" 10 13 19 32 ", ?" " ++ DelimCode ++ ?" "))) Do
Local DelimChar = Esc(?"\D" ++ Fill(?"000", DelimCode), ?"\")
If(Not(Index(Parameters, DelimChar)))
Break
EndIf
EndFor
; --- all one line below
Win.Debug(?"String does not contain character", DelimChar, ?"(ASCII code", DelimChar
++ ?")")
; --- all one line above
; --- all one line below (would actually be Do() and not Win.Debug())
Win.Debug(?"." ++ ScriptName ++ ?"@" ++ Alias ++ ?"(?" ++ DelimChar ++ String ++
DelimChar ++ ?")")
; --- all one line above
; ---
I'll use this code for now unless someone can offer a more aesthetic
piece of code that is as reliable.
I do understand that a script is much more valuable when it is easy to
understand, but I'm afraid I will always value reliability over
ease-of-understand...ment, and so I will probably leave it at that. I
will of course comment the code as much as possible.
--
Alex Peters / Melbourne, Australia
PowerPro v4.1.00 / Windows XP
------------------------ Yahoo! Groups Sponsor --------------------~-->
$9.95 domain names from Yahoo!. Register anything.
http://us.click.yahoo.com/J8kdrA/y20IAA/yQLSAA/JV_rlB/TM
--------------------------------------------------------------------~->
Attention: PowerPro's Web site has moved: http://www.ppro.org
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/power-pro/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/