NISUS Archives

April 2011

NISUS@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
"William F. Maddock" <[log in to unmask]>
Reply To:
Date:
Sun, 3 Apr 2011 21:00:24 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (39 lines)
-----Original Message-----
>From: Þorvarður Davíðsson <[log in to unmask]>
>Sent: Apr 3, 2011 6:27 PM
>To: [log in to unmask]
>Subject: Was something found, yes or no?
>
>Hello,
>
>I make a search in a macro and need to know whether something was found or not. How can I do that?
>
>This tells me whether some text is selected in the document
>
>$textExpression = Read Selection
>if $textExpression == ''
>	prompt "You need to select some text."
>	exit
>End 
>
>
>It works fine, so why does *this* not work?
>
>$textFound = Read Selection
>if $textFound == ''
>	prompt "Nothing found."
>	exit
>End 
>
>
>I have also tried 
>
>if $textFound >1
>or
>if $textFound >0
>
>
>but that does not make any difference.

I'm not a coder, so maybe I'm missing something, but, where did you actually tell it to perform the search? I'm not seeing it above.

ATOM RSS1 RSS2