Script for the selection of consecutive paragraphs - can someone help me?
Hello
I have this script that works very well. He then applied following a Style to the paragraphs I selected with the keyboard in Indesign CS5:
var style_name = "cabecalho."
var doc = app.documents [0];
var first_pstyle = doc.paragraphStyles.item (style_name);
var cur_sel = app.selection [0] .paragraphs;
cur_sel [0] .appliedParagraphStyle = first_pstyle;
If (cur_sel.length > 1)
{
for (n = 1; n < cur_sel.length; n ++)
{
cur_sel [n] cur_sel [n - 1].appliedParagraphStyle.nextStyle = .appliedParagraphStyle;
}
}
But before you run it, I use the keyboard to select the 3 paragraphs for the script. I know that it is possible to add code at the beginning to do the script select the paragraph where the cursor and the next 2 paragraphs and avoid manual selection because it's always 3 paragraphs.
I don't know how to do this. Can someone help me?
Thank you in advance. Greetings from Madrid
It's a little rough, but you get the picture:
var style_name = "cabecalho"var doc = app.documents[0];var first_pstyle = doc.paragraphStyles.item(style_name);var story = app.selection[0].parentStory; var cur_sel = app.selection[0].paragraphs[0];cur_sel.appliedParagraphStyle = first_pstyle; var nextpar = story.paragraphs.nextItem (cur_sel);nextpar.appliedParagraphStyle = cur_sel.appliedParagraphStyle.nextStyle; cur_sel = nextpar;var nextpar = story.paragraphs.nextItem (cur_sel);nextpar.appliedParagraphStyle = cur_sel.appliedParagraphStyle.nextStyle;
Peter
Tags: InDesign
Similar Questions
-
Old macbook pro drive dead... need to reinstall Design & Web Premium CS6 MAC EU on my new macbook pro... I have my serial number for my adobe ID... can someone help... Please?
Please see the applications download Creative Suite 6
Hope this will help you.
Kind regards
Hervé Khare
-
I find it difficult to upgrade the apex 4-5. Can someone help me?
have installed the database 11g (Express Edition). And trying to upgrade to the apex 5, using slobaray.com, but I'm stacked along the way; Please can someone help me? Here is the script, and I have indicated where I stacked by selection, the problem:
c:\oraclexe\app\oracle\product\11.2.0 > cd c:\oraclexe\app\oracle\product\11.2.0\server\apex
c:\oraclexe\app\oracle\product\11.2.0\server\apex > sqlplus
SQL * more: Production of the version 11.2.0.2.0 on Sat Feb 13 20:52:57 2016
Copyright (c) 1982, 2014, Oracle. All rights reserved.
Enter the user name: sys as sysdba
Enter the password:
Connected to:
Oracle Database 11 g Express Edition Release 11.2.0.2.0 - 64 bit Production
SQL > select TABLESPACE_NAME from dba_tablespaces where nom_tablespace like '% APEX %';
no selected line
SQL * more: Production of the version 11.2.0.2.0 on Sat Feb 13 21:01:30 2016
Copyright (c) 1982, 2014, Oracle. All rights reserved.
Enter the user name: sys as sysdba
Enter the password:
Connected to:
Oracle Database 11 g Express Edition Release 11.2.0.2.0 - 64 bit Production
SQL > home
Microsoft Windows [Version 10.0.10240]
(c) Microsoft Corporation, 2015. All rights reserved.
c:\oraclexe\app\oracle\product\11.2.0\server\apex > exit
SQL > show user
The USER is "SYS".
SQL > @apexins APEX is TEMP
Enter the value 4:
My confusion are:
(1) in the application of slobaexpet the
SQL > select TABLESPACE_NAME from dba_tablespaces where nom_tablespace like '% APEX %';
has given an answer to
TABLESPACE_NAME
------------
APEX
Mine is;
no selected line.
I don't know what was wrong with my work.
(2) SQL > @apexins APEX TEMP is
Enter the value 4:
I don't understand what the "enter the value of 4:" means and what to enter to continue on.
I suspended the process that I am waiting for the solution.
I'd appreciate someone's help.
Kind regards
GODIS-Tei
Hi Godis-Tei,
It is easy to explain.
(1) I don't know what are the instructions you follow, but it seems to suggest that you create a separate tablespace for APEX. Not a bad suggestion, but in your case, since you are new, you should be able to simply use the existing SYSAUX tablespace.
(2) you are prompted for an additional argument because you have not specified all necessary parameter values when calling apexins.sql. I suggest that you run again, and with the following arguments:
sysaux sysaux @apexins is temp
That's all! Good luck.
Joel
-
Hello, I am trying to send an email when the recipient opens the PDF with a password, can someone show me how to do
Hi Line,
Password protect a PDF file, you must use Acrobat. If you do not have Acrobat, you can try it free for 30 days. See www.adobe.com/products/acrobat.html for more information.
In Acrobat, choose file > properties when the document is open, and then click the Security tab allows you to set up a password.
Please let us know how it goes.
Best,
Sara
-
I have a laptop hp dv5t-1000 CTO. I tried all my USB ports, uninstall the driver and plug the unit again and searching for a driver online. So far, no luck.
The device is plug-and-play with Vista x 64. I can't find a driver online for Vista either.
Hello
Try to check the drive for the case:
Right-click on the drive-> properties-> tools-> error checking/Check now All the answers and suggestions are provided by an enthusiastic amateur and are therefore no explicit or implicit guarantee. Basically, you use my suggestions at your own risk.
-
I lost all the photos, files and programs, can someone help me please?
I did a system restore (I think) and lost all the photos, files and programs. Can someone tell me please how do I get back them?
LillieLooks like your user profile has been corrupted in some way and XP connected to a new profile. This means that when you connect, you see one of your stuff and can be also lack all the other programs you may have installed previously.
Note that the system restore do not know or care about the personal files on your system.
Unless there's a disaster or instead of a system restore you done a system recovery files would be still on your system somewhere - you just find them... and when you find them, you can correct what happened. If you have made a recovery of the system instead of a system restore, then all is lost and you need to recover from a backup.
Have you performed a search of Windows to see if you can find some of these photos and files? For example, you could search for something like "Resume.doc" or a file name that you remember exactly to see if it is anywhere on your system and where it is.
Why don't you get in Windows Explorer and (assuming that XP is installed on your C drive), navigate to this folder:
C:\Documents and Settings
Below, you will see that each user on your system has their own folder for their personal belongings. You will see also some folders listed user that you do not recognize, but that's normal.
Under the folder of each user, there is another folder, as "Documents of Jose" and under this 'Jose music' and «De Jose Pictures» Dig a little and check them all to see if you can find your missing stuff.
Just take a look in the Control Panel, add/remove programs to see if "missing" programs are still installed, but all not available when you are logged in (you don't have to 'do' something - just look at).
Assuming that you can find your missing stuff, determine where we (which will make feel you better knowing that it is not really gone), then report back and someone can help you straighten things.
-
Uninstall all the os of your pc. Then install 4.6 os first and then copy the input of the policy module. Then paste it somewhere else. Install the 5.0 os and paste the module into the exactsame folder where you copied previously. And then upgrade your operating system what Chinese input you need? Stroke or pinyun? I'll try to pick you up later
-
I try to download OverDrive Media Console to sync with the ipod of the omega software.
Jmcarroll,
Thank you for your question.
What version of Media Player do you use?
This problem may occur when the following conditions are met:
· The file you are trying to play is a protected requiring an individualization of digital rights (DRM) of management 2.5.
· You use the Player Windows Media 7.1 on a Microsoft Windows 2000-based computer.
Player Windows Media 7.1 on a Microsoft Windows 2000-based computer does not support DRM 2.5 individualization.
You can download the latest version of Windows Media Player which is the Download of Windows Media Center.
I hope this helps!
Lisa
Microsoft Answers Support Engineer
Visit our Microsoft answers feedback Forum and let us know what you think. -
My PC which I am the administrator does not accept my password. I have tried everything that he and am desperate. I think maybe that Microsoft made this for my PC when some PC hacked my Microsoft Hotmail Account outside and sending spam him. I thought that the problem was solved when I informed the technical support by e-mail to stop the account all together. All I want is to be able to reuse my labtop. Please any help will be sent by God!
Sincerely,
Steve J Malysz III M.S.
There are a lot of options built into Windows to help you out of this situation:- Restart the computer with your Windows repair CD, then use system restore to set Windows in a few days (only works if you have recently changed the password).
- Log on to your account admin to spare, and then reset the password for your existing account (works only if you set up an alternative admin account).
- Log in as administrator mode without failure, then reset the password for your existing account (the password is usually empty).
- Insert your flash drive USB with the password key file (only works if you have taken the time to create such a key file).
- Use the password indicator (works only if you have created a hint and if it's good enough to allow you to guess the password)
- Check your paper files (works only if you threw down the password somewhere)
-
script for the murder of session
Hello
I prepare a script for the murder of session and I use the following command to generate the script for large number of users. The syntax for the murder of the session is ALTER SYSTEM KILL SESSION * "SID, SERIAL #" * IMMEDIATE. I want my output with SID, SERIAL # values within the single quots *('SID,SERIAL#') *. can someone help me on this?
Select "ALTER SYSTEM KILL SESSION ' |" SID | «, » || SERIES # | ' IMMEDIATE '. « ; » FROM V$ SESSION WHERE BLOCKING_SESSION IS NOT NULL
Thanks in advance
Published by: 793097 on December 14, 2010 05:53select 'ALTER SYSTEM KILL SESSION '''||SID||','||SERIAL#||''' IMMEDIATE'||';' FROM V$SESSION WHERE BLOCKING_SESSION IS NOT NULL
Nicolas.
-
Hi, my problem is my video tag dimensionnera not the width of my browser, can someone help me. I use it as a background for my first page. His sat inside a container. Here's the code.
I tried etc. 100% width and height nothing seems to be letting me do this video the browser all the scale and be reactive. Can someone help me?
< div id = "fullpage" >
<! - Here are the sections of the page - >
< div class = "section" id = "section0" >
< div class = "container" >
< div id = "video-container" >
< video id = "BackgroundSection1" class = "Container1" preload = 'auto' autoplay muted loop >
< src = "source file.mp4' type =" video/mp4">"
<! - Videobackground - >
does not support.
< / source >
< / video >
< / div > <!--end of video container-->
I think that I misread your question the 1st time.
Maybe that's what you really want:
Background of the Page video fullscreen HTML5
Nancy O.
-
When I run our CSS by the validator I get the following errors can someone help please?
Our Web site is running in compatibility mode, so I crossed the our CSS validator and I got the following errors and warnings can someone help me solve this problem? Thank you in advance.
Sorry! We found the following errors (7)
202 UL. MenuBarVertical iframe try to find a point comma before the name of the property. Add 0 UL. MenuBarVertical iframe Parse Error null 202 UL. MenuBarVertical iframe Parse Error 0.1); 203 Without serif, Helvetica Parse Error [: Arial] 203 Without serif, Helvetica Parse Error, sans-serif; 211 projection Parse Error [: 16px; make-weight: normal; color: #000; text-decoration: #000; background-color: #FFF ;} / * HACK for IE: to stabilize the appearance of the menu items; the slash in the float is to keep IE 5.0 analysis * / @media screen] 223 projection Parse Error ul. MenuBarVertical li. MenuBarItemIE {display: inline; f\loat: left; background: #FFF; do-family: Arial, Helvetica, without serif; do-size: 16px; color: #000; text-decoration: #000; outline-color: #FFF ;} } Cautions (8)
114 UL. MenuBarVertical Same color for the background color and border-bottom-color 114 UL. MenuBarVertical Same color for the background color and border-right-color 114 UL. MenuBarVertical Same color for the background color and border-bottom-color 114 UL. MenuBarVertical Same color for the background color and border-left-color 124 UL. MenuBarVertical ul Same color for the background color and border-bottom-color 124 UL. MenuBarVertical ul Same color for the background color and border-right-color 124 UL. MenuBarVertical ul Same color for the background color and border-bottom-color 124 UL. MenuBarVertical ul Same color for the background color and border-left-color Sorry, I was talking about the code that is on the home page of your site to www.foxscientific.com.
When you look at the source code of this page, you will see what I mean.
To force him out of the compatibility view, you can add the following just before your end tag in the source code...
But fixing the odd coding mentioned methods can disable compatibility mode too.
-
I'm having a problem of syntax. JS, can someone help me?
I'm having a problem in the issue of line 3, and I know it's a rookie mistake, but I don't see the problem with that. Can someone help me?
Sorry for my bad English, it is not my mother tongue.
Either way, it isn't JavaScript. It is Java.
Java is a programming language completely different from JavaScript.
- Dreamweaver does not support Java.
- Dreamweaver supports web technologies - HTML, CSS, and JavaScript.
Nancy O.
-
BlackBerry smartphones can not change 'Sounds for the selected profile' or create new ones
I can't change any of the other sounds in my profiles or create new profiles. I can switch between them and change notifications as expected from fort to vibrate to silence. When I select 'Sounds for the selected profile' I get a transition of the screen as he opens the new screen, but then disappears. I tried to create a new one, but the new profile button and menu option do nothing. I upgraded to 6.0.0.246 in hope, he could solve the problem, but it didn't. Can I change the ringtone and sounds for contacts only. When I arrived at the torch, I could change and I even created a new. Any ideas?
delete nimbuzz, berrybuzz or any other instant messaging applications, and then restart the device
-
Can someone help me create a script to repeat to simply open the dialog box to create a link?
Can someone help me create a script to repeat to simply open the dialog box to create a link?
the "Connect" command uses the same dialog box as the command to "Place", except for the option "Replace" verified... so, use Ctrl + Shift + P to bring up the place dialog box, select your new image and select the checkbox "replace".
If check 'Replace' with the mouse slow you down, after you have selected your image, the tab key 'press' 3 times to change the focus, and then press the SPACEBAR to check it out, then ok to place.
Maybe you are looking for
-
Skye was working fine until yesterday, I took out for a meeting, came back and have since been unable to connect. The app status keeps rolling "signature", and after about 5 minutes, error that says "Skype cannot connect. I completely uninstalled and
-
Change of MAC address each time
A colleague has a Jade S55 liquid Acer.Whenever the S55 connects to a wireless accespoint - wifi MAC address change.Is this a known issue or bug (Android)? Whe needs a MAC address for MAC filtering.
-
How can I change my wep to a wpa key
-
Connect Speedstream 6520 with EA6300
Hello I am currently a few problems with the help of my modem/router SpeedStream 6520 of Bell and my new LinkSys EA6300. I'm trying to use the modem for the internet and the EA6300 to control the flow of bandwidth. My goal is to have connections wire
-
Slide down from the top edge of the screen no longer shows the option of moving/closing for windows. In addition, the right shot is not bring up the menu of charms. The only feature that seems to work is the left to switch from windows. The problem s