🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #8670

How to check string contents and screen refresh: 2 questions (VBScript)

#8670
From: Ariel Walden
Date: Thu, 28 Sep 2006 20:51
26 lines
1691 bytes
Hello,

Using VBScript...

So far the response here has been really great for me, so I'd like to ask a
couple more questions:

(1) myCharacter is a string. I want to check if it is not a capital letter.
What I did, and it worked, is:
if asc(myCharacter) < asc("A") then xyz...
if asc(myCharacter) > asc("Z") then xyz...

However, I was wondering if there isn't a better way of doing this. I saw in
Word VB a function called Like, which would let you write: If myCharacter
Like ("[!A-Z]") Then xyz....

That's the first question.

(2) The script ends with highlighting a selection in the document.
(mydocument.selection = mycharacter). How can I get InDesign to goto this
highlighted character before the script ends? I thought something like:
myDocument.screenrefresh. But I can't find any way of doing this.

All help greatly appreciated,
Thanks,
Ariel
Technical Details
Message-ID: <DBB8AF7F817937C04F88CCE86B0C4CE9@in.webcrossing.la2eafNXanI>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news2.volia.net!news.germany.com!news.mb-net.net!open-news-network.org!news.isoc.lu!webcrossing

Show Full Headers
Complete Article Headers
X-Google-Thread: f939a,59668cea2252b3d2,start
X-Google-Attributes: gidf939a,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Ariel Walden" <tarielw@gmail.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news2.volia.net!news.germany.com!news.mb-net.net!open-news-network.org!news.isoc.lu!webcrossing
Newsgroups: adobe.scripting.indesign
Subject: How to check string contents and screen
 refresh: 2 questions (VBScript)
Message-ID: <DBB8AF7F817937C04F88CCE86B0C4CE9@in.webcrossing.la2eafNXanI>
Date: Thu, 28 Sep 2006 13:51:28 -0700
Lines: 28
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit