[CS3][JS]Add Tag to text

hi,
   I need to apply tag to selected text in a layout.We can do it manually by selecting text in a layout and then choosing tag from 'Tags' window.The same thing needs to be done using Javascript.I have used the following code,but it adds tag to entire paragraph,not for selected text.The paragraph is already tagged. I need to add tag(sub tag) for selected text which is already tagged.
app.selection[0].associatedXMLElements[0].markupTag=myDoc.xmlTags.item("subtitle");
Please suggest me.
Regards
kumar

This tags any selected text:
app.activeDocument.xmlElements.item(0).xmlElements.add ("subtitle", app.selection[0]);
and adds this tag to the one containing the selection (despite adding it to the 'root' of the document). It seems not to care whether the selection already is tagged -- it always adds another one.

Similar Messages

  • How do add tags within text of another tag in xml...

    I have the following template I want to create in xml and read it to send out emails.... but in body i want to insert the tags <DATE> and <COUNT> in certain location of the text how is that possible this is what I have:
    <email>
    <from>[email protected]</from>
    <to>[email protected]</to>
    <cc>[email protected]</cc>
    <bcc>[email protected]</bcc>
    <subject>This is the subject</subject>
    <body>This is the body of an email message.As of <_DATE> there are <COUNT> outstanding items. Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text
    Text Text Text Text Text Text Text Text Text
    Text Text Text Text</body>
    </email>
    From: <_FROM>               
    To: <_TO>
    Cc: <>
    Subject: Hello
    As of <_DATE> there are <COUNT> outstanding items. Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text
    Text Text Text Text Text Text Text Text Text
    Text Text Text Text
    Thank you,
    Sys Admin

    In ur program
    Betweens = station.getChildren("between");here the "Between" is a List having "between" elements.
    if u want to traverse through all the <between> elements which are inside the<noservice>,.
    check with this,
    Betweens = station.getChildren("between");
    between = (Element)Betweens.get(0);
    bNames =between.getChildren("station");
    blineNames =between.getChildren("line");instead of this..
    java.util.List Between = station.getChildren("between");
    ListIterator iter = Between.listIterator();
    while(iter.hasNext())
    Element between = (Element) i.next();      
    bNames =between.getChildren("station");
    blineNames =between.getChildren("line");
    If the XMl document is something like this..
    <?xml version="1.0"?>
    <?xml-stylesheet type="text/css" href="style.css"?>
    <DisruptionsInfo>
    <Title>Disruptions on the London Underground</Title>
    <noService>
    <between>
    <description>The are no service between</description>
    <station>BAKER STREET</station>
    <description>and</description>
    <station>EUSTON SQUARE</station>
    <description>on the</description>
    <line>METROPOLITAN LINE</line>
    </between><between>
    <description> 2 The are no service between</description>
    <station>2 BAKER STREET</station>
    <description>2 and</description>
    <station>2 EUSTON SQUARE</station>
    <description>2 on the</description>
    <line>2 METROPOLITAN LINE</line>
    </between>
    <description>The following station(s) are closed due
    to engineering works:</description>
    </noService>
    <closed>
    <station> Green Park </station>
    <station> Maida Vale </station>
    </closed>
    <description>The following line(s) are closed due to
    flooding</description>
    <DelaysLine>
    <line>Jubilee line</line>
    </DelaysLine>
    </DisruptionsInfo>the above code will travel thro all the <between> children of the <noservice> element.
    i think this would help u.

  • Need help to develop app to remotely add tags to iTunes music from iPhone

    Hi
    I have recently developed a simple app that sits on my desktop and allows me to add specific tags/text to the 'comment' field of the currently playing track in my iTunes library, the text added depending on the item clicked in some drop-down menus.
    This is fine for when I am sitting at my Mac, but most of the time I would like to be able to add tags from a distance, i.e. remotely, using the iPhone, so I started to develop my first iPhone app for this purpose.
    I have succesfully designed a simple Tab Bar Application, with two views, which have all the buttons I need, but now I am stumped as to how to set up the remote part of the app. On the Desktop version I simply wrote some applescript with sections for each of the menu items. On the iPhone I am not sure how I would go about this.
    Any help with this, either with the procedure I need to follow, or pointing me in the right direction of a tutorial or some such thing, would be gratefully received.
    thanks
    nick.

    Do you mean write access to the iTunes library, rather than iPod library?
    If so, if I can accomplish my task with getting the iPhone app to interact with the Desktop app that would be fine. However, I have no idea of how to go about this. Can you give me any pointers?
    The desktop app basically consists of a few drop down menus with items that are linked to sections in the project's applescript, which tell iTunes to add specific text to the comments field.
    Thanks
    Nick

  • Tagging Moves Text in Tables

    I'm in the process of converting hundreds of PDFs to be 508 compliant and one of those steps includes adding tags to the document.  What I'm noticing is that the tagging is moving some of the text to the bottom of or outisde of some of the tables.  Does anyone know what is causing this or how I can prevent it?
    Thanks!

    The Add Tags to Document follows general rules for identification of an untagged PDF's logical hierarchy.
    For Tables, this presumes that, in the authoring file, the authoring application had an "insert table" feature and that this feature was used.
    If (as was done rather often "back in the day") a table was simulated by use of space and/or tab characters to position what was to represent a "table" then the PDF does not contain a "table" per se.
    If a "table" was inserted the cell input may have been positioned with space/tab characters rather than using the application's "style" configuration (for indents, white space & such).
    For simple tabular/data tables the Add Tags to Document does the job (even if the table in the authoring file was a "layout" table (no defined header row)).
    However, complex tables won't "fit" the general rules.
    Complex having something like:
    Multiple "header" rows (either vertical or horizontal or some of both)
    Spanned cells
    Aside from having to deal with what came from those old authoring files remember to add a Table Summary for each Table and for each header cell <TH> its requisite value for Scope.
    As well, for spanned cells the appropriate value for row or column Span.
    For "complex" tables you get into assigning the Table Attribute of "Header" and associate "ID" entries.  A neat exercise; but, better avoided when creating content by breaking tables out to simple tables rather than multiple tables mushed together into one.
    As you are working on "legacy" PDF the only spot on method of bringing the content to workable Accessibility may well be manual tagging as a "best guess" from Add Tags to Document has limitations (e.g., It cannot provide Alternate Text for content in a <Figure> element.).
    So, when climbing about in the structure tree (you'll have to go there to get it done) remember to save as and increment the file name (_01, _02, or some such) as there is no "undo".
    You've a "doable" task — it just takes time, a good chunk of time as you've a large population of PDFs.
    The PDF(s) for rosebird took somewhere between 70 to 100 hours.
    http://acrobatusers.com/forum/how-make-pdf-ramseyer-format-accessible
    So, you may want to address the level of effort/time reality.
    Of course, for $$ the you could out source the task to one of the several companies that do this sort of thing (would not be "me" - I'm not affliated with any of them ).
    Be well...
    Message was edited by: CtDave

  • Add Tags to Document removes spaces!

    Hi,
    I have an untagged PDF from which I am trying to copy the text. The text pastes into InDesign with a paragraph mark at the end of each line.
    If I add tags to document from Advanced>Accessibility, the copied text no longer has a paragrpah mark at the end of each line BUT all the spaces between words have been stripped out!
    Does anyone know why this happens and is there anyway around it?
    Thanks,
    Simon Kemp

    Content should not ever be deleted by adding tags, but it may appear so since - as you note - objects may go into hiding behind other objects. In theory you can bring them out of hiding by rearrange things in the Order pane, but I have much better luck using the Content pane - it provides a much finer level of control. If text is hidden behind a shaded box, for example, I will move the box above the text in the Content order, then usually convert the box to an artifact if it is not one already.
    Hope this helps.
    a 'C' student

  • Add Tags to Document tool put one object behind another or just deletes page content?

    Using Acrobat XI Pro to make documents 508 compliant PDF. I've had a number of issues went using Add Tags to document option, it’s put one object behind another or deleting it all together. Also had issues when trying to adjust the reading order, content is moved or deleted. This PDF is created from InDesing CS5
    Anybody know what I'm talking about or have any ideas about how to fix it? Thank

    Content should not ever be deleted by adding tags, but it may appear so since - as you note - objects may go into hiding behind other objects. In theory you can bring them out of hiding by rearrange things in the Order pane, but I have much better luck using the Content pane - it provides a much finer level of control. If text is hidden behind a shaded box, for example, I will move the box above the text in the Content order, then usually convert the box to an artifact if it is not one already.
    Hope this helps.
    a 'C' student

  • Is there a way in Pages to show and print all the added "comments?" (those you add by highlighting text)  I'd like students to be able to view my comments on printed version of their papers.

    Is there a way in Pages to show and print all the added "comments?" (those you add by highlighting text)  I am a teacher, and I would  like students to be able to view my comments on printed versions of their papers. I know word displays the comments off to the side of the document, and those comments can be viewed all at once and printed alongside the document.

    There doesn't appear to be a way to print conmments in either Pages or Numbers in the Mavericks versions.
    Jerry

  • Add or Edit Text Dialog Box Disappeared

    I am attempting to add text to my pdf using the add or edit text tool in Acrobat Pro X. However, the dialog box that allows me to change fonts, size, color, etc. has disappeared. Does anyone know how to make the dialog box come back?

    Hi,
    This is a new problem. It started about 2 days before I posted the question. I have not updated my Acrobat recently and I was previously able to use the dialog box with no problem. I have tried in several different documents and the dialog box is not showing up.
    Thanks for your assistance.

  • How to add tags to a number of pdfs?

    It seems that batch processing does not support adding tags. I'm wondering if there is an automatical way to add tags to multiple pdfs. Or I have to use javascript to do? Or there is a third party tool to do so?

    I have Acrobat 8.3 Professional and you can create a batch sequence, In documents there is an option "Make Accessible". This will add tags to a bunch of files.

  • How to customize the content set in text as part of tag cq:text property="text"/

    We use the tag <cq:text property="text"/> to get the content, which is set in the jcr property "text".  Text was set in Richtext component and it has hyper link.
    Now, we have to customize the text.
    Example:-
    Actual Text in 'text' property:-
    <p>Click <a data-action="Hyperlink" data-upc-tooltip-type="none" href="/content/www-abc-healthcare-ch/en/offer.html">here</a> for the link</p> <p></p>
    After customization in 'text' property:-
    <p>Click <a data-action="Hyperlink" data-upc-tooltip-type="none" href="/content/www-abc-healthcare-ch/en/offer">here</a> for the link</p> <p></p>
    i.e .html has been removed.
    I tried customizing and set back to text attribute using <c:set var="text" value="<CustomizedText>" /> but even after that tag <cq:text property="text"/> retrieves the old content i.e with .html
    Please suggest how to override text content, so that the tag <cq:text property="text"/> will print customized text.

      Which version of cq? Is Strict Extension Check enabled at  http://<host>:<port>/system/console/configMgr/com.day.cq.rewriter.linkchecker.impl.LinkCheckerTra nsformerFactory
    Thanks,
    Sham

  • How to add a scrolling text in portrait with iMovie

    how to add a scrolling text in portrait with iMovie

    This is how i was able to do it. Edit html source.
    <div align="center"><marquee id='scroll_news4' bgcolor=#ff9966 "><font color="#000000" size="+1" ><strong>Outlook is down! IT is working on it! </strong></font></marquee></div>
    <input type='Button' value='Stop' id ='b1' onClick='button_click()';>
    <SCRIPT LANGUAGE="JavaScript">
    <!-- Begin
    function button_click()
    if(document.getElementById('b1').value=="Start"){
    document.getElementById('b1').value="Stop";
    document.getElementById('scroll_news4').start();
    }else{
    document.getElementById('b1').value="Start";
    document.getElementById('scroll_news4').stop();
    // End -->
    </script>

  • How to add the long text in Production order through FM

    Hi,
    Iam having custom program which has BAPI (BAPI_PRODORD_CREATE) inside it and this program is used to create Production orders with the details of Sales order Number,Line item,Plant,Order type,Quantity and Start date. This program is scheduled in Background.
    Now client wants to add the Long text (seperate TAB in production order and they want to update the VC details of Sales order in the Long text area).
    One option is after creation of Production order, through BDC(calling CO02 and update the long text) we  can update the long text and client doesn't want this option.
    Another option is after creation of Production order, using Function module SAVE_TEXT, Update the Long text in Production Order and this is not working in Production order (already my ABAP consultant checked it ).
    If any one of you came across this requirement, pl share with me how you addressed it.
    Regards
    A.Sureshbabu

    Hi,
    The method is quite simple, i presume you're quite well versed with doing recording, so the key thing to keep in mind is how to prepare the input file.
    At my end i had about 5 lines of data which needed to be uploaded, hence i had a tab-delimited file with the order nos. in the first column & the five lines of text in five different columns (Refer format below)
    Order No.
    Line - 1
    Line - 2
    Line - 3
    Line - 4
    Line - 5
    12345
    txt - 1
    txt - 2
    txt - 3
    txt - 4
    txt - 5
    67890
    txt - a
    txt - b
    txt - c
    txt - d
    txt - e
    Now provide this input file for your lsmw or bdc program & it will work. You can work with your abaper if you're not so comfortable with LSMW or BDC programming he / she should be able to easily make it work for you.
    Regards,
    Vivek

  • How can I add dots after text to fill the remaining space in a table cell?

    What is the most efficient way to add dots after text to fill the remaining space in a table cell? I know it is possible using tabs but is this possible using a table?

    You can put a tab inside a table cell using Option+Tab
    Then just set the right-aligned tab stop and the right edge of the table cell and add the leader.

  • How do I add tag words to my website in iweb

    I need to learn how to add tag words to my website (in iweb).

    The title tag and meta description are added to the HTML doc for each page of your website. You need to do this after you have published to a local folder from iWeb using the second method shown here...
    http://www.iwebformusicians.com/iWeb/Publish-Website.html
    Its a lot easier to use the third party software iWeb SEO Tool...
    http://www.iwebformusicians.com/Search-Engine-Optimization/Tags.html
    More info about SEO here...
    http://www.iwebformusicians.com/Search-Engine-Optimization/SEO.html

  • How to add full screen text w/out losing audio. I have premier elements 12

    I am creating a language tutorial. Am trying to add full screen text without losing the audio explanation of the text. How do I make this edit and not lose the audio that coincides with the full screen text?

    Roberto
    Thanks for the details.
    Variable - Constant Frame Rate Explanation
    First, the variable frame rate mention and any problems that might be expected if your iPad video was recorded with a variable rather than constant frame rate. Some cameras (such a cell phone, iPod, probably iPad) record video not at one frame rate across the whole video recording. Instead, they record with a variable frame rate depending usually on the lighting conditions during video recording. One way to know what your recording device is using is to view the MediaInfo video audio properties readout. If you have a constant frame rate, you will see just one frame rate listed. If variable, you should see 3 frame rates listed minimum, maximum, and mid range frame rate.
    MediaInfo - Free download and software reviews - CNET Download.com
    This situation may or may not cause problems for you in Premiere Elements. The signs of problems are usually out of sync audio and you just cannot import the video into the project. If this type of problem, then you take your video into a program such as HandBrake to generate a file with a constant rather than variable frame rate. Then you import the file with the constant frame rate into your Premiere Elements project. http://handbrake.fr/
    Again, this may or may not create problems.
    The Generalized Project Workflow
    There is no problem to setup up your Timeline physically. The iPad video with go to Video Track 1 and Audio Track 1. The video is imported into the project linked to it audio portion. And, the Full Screen Text Files will be on Video Track 2 directly above the related content. Now here is the part that I am not yet clear on. Is the Full Screen Text for a given portion of video supposed to synchronize word for word with what you are saying in the audio on Audio Track 1? That will involve a mapping out part with regard to duration of each of the Full Screen Text files. Will these Full Screen Text files be readable against the video representing the background? Font style and size and color will be major considerations as well as getting the text file to be on screen long enough to be readable even with Font style, size, and color considerations.
    The fact that you focus on audio loss in all this makes me wonder if I am missing a vital part of what you want to do. The loss of audio concern that you mention does not seem like a prime factor unless you are referring to sync between the texts and what it is supposed to correspond to in the audio of the video.
    Please review and consider and then, based on your reply, I will offer a mini demo to see if we are OK on the details.
    Thanks.
    ATR

Maybe you are looking for

  • Writing blobs to files in 8.1.7

    (Duplicate post of a message in the SQL forum - I belatedly realized it might belong under Java...) I have got several thousand blobs in an Oracle 8.1.7 instance that I need to write to files. I found sample procedures for doing this listed below. I

  • How to disable the verbose mode in HTTPS ?

    Hello Everybody, I'd like to know how I can make an https connection in which the text of the transaction with the distant server doesn't show in the console here is my code : URL rawURL = new URL(url); if(rawURL.getProtocol().startsWith("https"))   

  • Where do I find drivers for my EliteBook 8740w CD drive

    I have an EliteBook 8740w, Windows 7 pro - 64. System indicates my CD is no longer recognized and that driver is corrupted."Windows cannot load the device driver for this hardware. The driver may be corrupted or missing. (Code 39)" CD is indicated in

  • Typewriter Tool

    Do you offer a download of Adobe Acrobat that is not read-only, but includes tools, such as the typwriter tool?

  • Problems with downloading software.

    I have just got an Mac and wanted to download software so that I am able to game online. When I have finished downloading the software an error message appears saying 'Unable to play video'. I'm obvisouly a new user and need some advice to what I nee