🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #14887

Re: JS beginners help

#14887
From: Roy_Marshall
Date: Thu, 15 Jan 2004 14:25
25 lines
1607 bytes
Using my limited knowledge, and a great deal of help, here is a draft of what I want to achieve.
I had a quick look at that page Dave, and i will study it tonight when i am not at work.

I know there is a lot wrong with this script, not least the line to get the index!!!!!

myIndex = app.selection[0].parentStory.search.index("�");
myLength=myIndex.length();
for (i=1, i=myLength , i++)
	{
	myline = myIndex[i].parentLine();
	if (myline.search("1TAB")) == true
		{
		myline.search("�", false, false, "�",{appliedParagraphStyle:"right indent"},{appliedParagraphStyle:"body text"});
		}
	else();
	}

1) What i need to do is work on text that has a right indent already set (Style sheet:right indent),
2) Make a list/index/reference to all the "�" signs
3) work on the line of text containing the "�", looking for a string "1TAB"
4) If that is found, I need to apply a style sheet that takes off the right indent.

dont laugh, any ideas?

Roy
Technical Details
Message-ID: <2ccf45cf.21@webx.la2eafNXanI>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!webx
References: <2ccf45cf.-1@webx.la2eafNXanI>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: f939a,613db9f5b5ffc527
X-Google-Attributes: gidf939a,public
X-Google-ArrivalTime: 2004-01-15 06:38:16 PST
From: Roy_Marshall@adobeforums.com
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!webx
Newsgroups: adobe.scripting.indesign
Subject: Re: JS beginners help
Message-ID: <2ccf45cf.21@webx.la2eafNXanI>
Date: Thu, 15 Jan 2004 06:25:45 -0800
References: <2ccf45cf.-1@webx.la2eafNXanI>
Lines: 32
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit