Selected TextFrame contains a dashboard?

Is it possible that I can browse the selected text items and if the text block contains a dashboard button all the contents of the text block in a table?

If it does not contain a hyphen, it would just blow up.

Thus, for example:

The following would be selected...

SNJ1-UP RYT245-587 WRX1-107 J:37

There are 4 items in the selection...

and he would push the contents of a table dashFrames [---] who would have the 3 elements of text inside frame...

dashFrames [0] = SNJ1-UP

dashFrames [1] = RYT245-587

dashFrames [2] = WRX1-107

Do you mean something like this?

// 4 textFrames should be selected

var tF = app.activeDocument.selection;
if (tF.length == 4) {
    var count = 0;
    var dashFrames = new Array ();
for (i = 0; i < tF.length; i++) {
    if (tF[i].typename == "TextFrame") {
        if (tF[i].contents.match ("-")) {
            dashFrames[count] = tF[i].contents;
            count++;
            }
        }
    }
}
// alert (dashFrames)
// result: RYT245-587,WRX1-107,SNJ1-UP

Have fun

Tags: Illustrator

Similar Questions

  • How to select username contains only 7 strings

    from dba_users, how to select username contains only 7 channels?

    Select decode (length (username)?) Please help. I just need to print the users whose name is exactly 7 charactars.

    Try something like
    SELECT username FROM dba_users WHERE LENGTH (username) = 7;

  • Selected pass contains a string indicator combo box when you press the Enter key

    Hello

    How to pass selected contains a string indicator combo box when you press the enter keyboard key?

    Right now I use a button to send the command selected in the combox to string indicator.

    The photos shows a combo box with the button that I use to send to the indicator as example.

    After the user selects the text to pass, "send the cmd" button must be pressed to pass the string.

    I need to pass the selected string when the user press enter on the keyboard rather than press the button 'send cmd '.

    Kindly to you needing help.

    Hello

    You can use a structure of the event to capture keystrokes and filter, transmit only the drop-down list box "value of the indicator of channel when you press the return or enter key."

    Let me know it the joint allows an example (in LV 8.6).

  • Select textframe based on textFrame.id

    Dear all,

    I want to assign a myFrame variable to one of the textFrame present in a page of textFrame.id.

    myDoc var = app.documents.item (0);

    var i;

    for (i = 0; i < myDoc.textFrames.length; i ++) / / three blocks of text I have in myDoc (only one page)

    {

    myFrame var = myDoc.textFrame [i]

    alert (I + "" + myFrame.id);   Here I get number 845, 869, 205

    If (myFrame.id is 845)

    {

    myFrame.select ();

    }

    }

    So now, I knew then, how can I assign / select which frame to a variable, which has the id 869 id three of three linked text frames.

    myFrame1 = myDoc.textFrames.id (869);  entitlement does not work here //need code for it

    myFrame1.select)

    Marie rosine

    Here's another solution:

    var myItemId = 869;

    myTest = tryIt (myItemId)

    myTest.id; must return the same value as myItemId

    function tryIt (myItemId) {}

    docRef var = app.documents.item (0);

    frameCount var = docRef.textFrames.count ();

    var frameVar;

    for (var i = 0; i)< framecount;="">

    If (docRef.textFrames.item (i) user.user == myItemId) {}

    Return docRef.textFrames.item (i);

    }

    }

    }

    Put the code inside a function allows the result to return when the match is made, eliminating unnecessary iterations.

  • How to paste a text in a selected textframe

    Hi, a new script I want to paste text into a textFrame.

    I would choose my text, copy and execute my script.

    My script locate a textframe, select it.

    I don't know how to paste the selected contents of the textframe.

    App.Paste ();

    The dough is OK, but it creates a new textframe while the block is selected.

    Can you help me?

    THX!

    If it works the same as it does in the interface itself. Try it: copier copy text, select (but do not enter) a block of text, tap on paste. A new block of text appears.

    To get what you want, you must put the text inside your selected image cursor. This is not a function but fortunately this weird-looking command works:

    app.selection[0].insertionPoints[-1].select();
    app.paste();
    
  • How to filter data for quick selection of 'All choice' dashboard?

    Hello gurus,

    I have obligation where I need to create buckets based on the codes to work.

    for example Job code in('1',''2','3') = 'ABC '.

    Labour code in ('4 ', '5','6 ') = 'XYZ '.

    The labour code now has LOVs 1 to 10 and we use all the codes work to create buckets.
    I use instruction box in the formula of the column to create buckets in command prompt and remove null as additional values in the selection options.

    now the problem occurs when I gave the options "All options" user for quick selection, which returns all the codes work.
    Is there a way to restrict "All options" to render only 'ABC' + 'XYZ '.

    Srini Hey,.

    I got it by twisting a lil bit.

    good answer I guess

    (' @{JOB_CODE} "="ABC"AND"Job"". "") Job"("1"))

    OR

    (' @{JOB_CODE} "="XYZ"AND"Job"". "") Job' ('2'))

    OR (' @{JOB_CODE} "=" AND "Task" ".) (The task' in ('1 ', ' 2'))

    Mark Helpful if you feel...

    Thanks a lot for your help.

  • How to get textFrame contained in the file ".txt"?

    Hi all

    I want to write my text frame content in a ".txt" file Right now, I have my content of PMString text frame.

    And I use regular C++ file manipulation.

    To write to the file, I used it-> "std::string string_name = PMString_name. GetPlatformString(); "

    But it returns me a single line string and writes it to the file...

    for example.

    If PMString is->

    "ABCD".

    EFGHIJK

    LMN.

    then give me platformstring->

    "ABCDEFGHIJKLMN".

    But I need an exact replica of the content of my text frame in my file ".txt", with all line breaks and empty spaces.

    Can anyone please suggest me something?

    PMString::GetPlatformString() works very well.

    See your text by MS Word or Wordpad.

  • Select by StoryID textFrame

    Hello.

    I know that the textFrame has a unique ID.

    And I can implement using the SDK.

    But I want to select a block of text using JavaScript by StoryID.

    Any ideas?

    Thank you.

    Hello

    As I wrote above - it of which one of the containers story will you choose?

    A first?

    This line selects textFrame 1st overall of containers of history ==> what ID == StoryID:

    app.activeDocument.stories.itemByID(StoryID).textContainers[0].select();
    


    Jarek

  • A link problem, conflict between hyperlink and textframe

    Hi all

    I noticed erratic behavior after the creation of a hyperlink text in a textframe. Although the link seemed ok when previewing (both in Muse preview mode, as in a browser (Chrome) Preview), she had abruptly changed his State when I was about to click on it. After a few perplexed attempts, I noticed that the hyperlink is transformed into the 'pointed' state once the mouse is over the textframe containing the link and not the link itself. When I click on the link, the behavior is as expected, but moving out of the textframe and reintegrating gives the same effect. Somehow the textframe intercepts the mouseover, instead of the link event. Is there a way to disable this behavior and the target of the hyperlink instead? Thanks in advance. (I searched this question in the forum and had similar problems with menus, but not with executives of related, if I forgot an answer, my apologies in advance.

    Hello

    Please select the text frame and click the States window and let me know what you see. It would be better if you can share a screen like this,

    Kind regards

    Abhishek Maurya

  • Select an object from a selected text.

    The use of Javascript:

    First selects the textframe containing selected text?

    Second how to select the anchored object of a selected anchor marker character?

    First question:

    Property 'parentTextFrames' is the one you are looking for. It returns a table of blocks of text (or text paths). Explanation: If your selected text is threaded between two or more frames for text (or text paths), "parentTextFrames" contains more than one block of text or text paths.

    If your selected text is a single character "parentTextFrames [0] ' will do. If your selected character is part of a traced text parentTextFrames property returns a textPath object.

    The second question is more slightly more complicated:

    To loop through the collection 'pageItems' in the "parentTextFrames [0] ' of your selected character.
    Check if their parents (Yes, it is a character!)  The index number is the same as the index number of your selected character.
    End the loop then. You have found your object.
    Select it then. Or do you like to do with him.

    See the code example:

    //A single character is selected:
    var mySelIndex = app.selection[0].index;
    var myPageItems = app.selection[0].parentTextFrames[0].pageItems;
    
    for(var n=0;n
    

    Uwe

  • TextFrame properties question

    Hi all

    Can someone please identify/describe the differences between TextFrame.controlBounds, TextFrame.geometricBounds and TextFrame.visibleBounds?

    Thank you

    NOT

    Hi, the problem is that you try to read the width of the textframe container, in this case containing "Text box", it will always be around 400 in your example. If your textframe was 'Point text' then you will get what you need by calling the width property of the textframe 'Text of Point', in this case 323.5

    because you can not convert text to point text box, you can select the content of it and assign it to a new text frame friendly aiPointText then read the width property.

    Carlos

  • offline media, the file does not contain audio media...

    Hello

    I have reopened my project today and a lot of my clips say offline media. When I tried to link media, search for, and click ok, another message appears saying this:

    " The selected file contains no audio recording media used by clip references in one or more sequences. The reference of the audio clip will be deleted and cannot Ωtre annulΘe. Do you want to continue? »

    I also tried to clean my cache files of media and also handed over my computer laptop, reopened of PP, and I still have the same problem. Any help with this would be much appreciated and I thank you in advance!

    Kind regards

    Chris

    Claire on the media cache, rename topfolder in that the images is and recreate a link, see how it goes.

  • Look And Feel to the dashboard

    Hello

    I've developed reports obiee lately as part of my training activity. I came across a few examples of reports from google, and I find them very professional and much better than what I have created. I enclose several images here, the first 3 images contains the dashboard I created and the fourth example of google report. Can anyone help me design dashboards that seems very professional?

    query1.JPGquery3.JPGquery2.JPG

    7973.png

    Hello

    Firstly, it is good to say that "professional research" is subjective, that it is better to look for is probably not uniformity.

    You're not too far honestly...

    First point is that you use a lot of sections. If you use many sections of your page uncheck the option 'Folding', it will hide the upper area of the sections with the icon to the left. If you don't need 3-4 sections just use a unique, not need a section by element. Hide borders of your sections, so you don't see all the blocks in your page.

    These few things will do it look better already.

    Another point is style: keep the colors, fonts, size uniform etc. in your objects.

    You have a blue, black, yellow, grey background on some of your lines, you really need different colors? Really have a meaning? If this is not the case, just use a single.

    Start there and don't forget to make things uniform.

  • Selection list cascading in the dialogue window

    Hello

    I'm developing in Apex 4.2.5.

    I have an Apex with a classic report region, in which a link edit page opens a dialog window (in the same page apex) to edit the selected line. The same dialog window is used to create a new line. The dialog window contains a cascading pick list. Two selection lists are defined to display NULL values and correctly fill in mode 'create '. My problem is that mode "Modify" the list of the second selection is not good value. The second selection list contains it however the right subset of values according to the parent, select the list and therefore don't does not contain the correct value, but it is not selected.

    I use a javascript function to fill in the fields in the dialog.

    ....

    $s ("P3_EVENT_TYPE", arguments [1]);

    $s ("P3_EVENT_SUBTYPE", [2] arguments);

    ....

    Then the display of the dialog window

    openDialog ('editEvent');


    The population of P3_EVENT_SUBTYPE list seems to happen but sometime after that all the fields in the dialog were assigned and the dialogue window displays.

    I see that I need to somehow update the list of selection in cascade, P3_EVENT_SUBTYPE, before assigning the value. My problem is how can I do this in the same javascript function?

    Kind regards

    Derek

    Eventually answered my own question-

    I created a hidden field in which to store the value of the event subtype.

    Created a dynamic of Action, after refresh of affected P3_EVENT_SUBTYPE subtype value = hidden field event.

  • Trying to import mov a folder selected in the first.

    I have a script that prompts the user to select a folder containing some mov files to import. Once the selected folder first passes through the import process, but at the end of import, an error message appears saying "Unsupported format or corrupted file.»

    I know that the mov is good because I can drag them into the project very well.

    Here is my code:

    var app.project = proj;

    var binName = "batch files";  Find or create a target location.

    var targetBin = searchForBinWithName (binName);

    If (targetBin == 0) {}

    app.project.rootItem.createBin (binName);

    }

    If (proj! = null) {}

    targetBin = searchForBinWithName (binName);

    targetBin.select ();

    var movLocation = Folder.selectDialog ("Select folder containing the files to import", 0, true);

    var filesArray = movLocation.getFiles ("mov");

    If (movLocation! = null) {}

    var import_these = new Array;  We have an array of file objects; importFiles() takes an array of paths.

    for (var i = 0; i < movLocation.length; i ++) {}

    filesArray [i] is movLocation [i] .fsName;.

    }

    proj.importFiles (filesArray);

    }

    }

    function searchForBinWithName (name) {}

    var numItemsAtRoot = app.project.rootItem.children.numItems;

    var foundBin = 0;

    for (var i = 0; i < numItemsAtRoot & & foundBin == 0; i ++) {}

    currentItem var = app.project.rootItem.children [i];

    If (currentItem! = null & & currentItem.name == binName) {}

    foundBin = currentItem;

    }

    }

    Return foundBin;

    }

    Thanks Bruce...

    I realized what the problem was. When I used getFiles(), he got the path of the object but lacked "/ Volume /" since the beginning of the path for a reason any. I had to scroll down the table of files and use .fsName to get the full path. To do this, I changed the code and it worked:

    var movLocation = Folder.selectDialog ("Select folder containing the files to import", 0, true);

    var filesArray = movLocation.getFiles ("mov");

    If (movLocation! = null) {}

    var filesToImport = new Array();

    for (var i = 0; i)< filesarray="" .length;="" i++)="">

    filesToImport.push (filesArray [i] .fsName);

    }

    proj.importFiles (filesToImport);

    }

Maybe you are looking for

  • How do you get the new BBC Iplayer App on Apple TV

    Course, it is the new BBC Iplayer App for Apple TV. Have updated software, etc., but can not see the app on my home screen. Anyone know how to get it?

  • HP Pavilion G6 2310se: HARD SSD update drive

    HelloI'm running the disk HARD 500 GB 5400 RPM for the moment and it is slow for me. I want to update for Samsung (MLC) 128 GB sata III 6.0gbps 7 mm (Ultraslim). with a caddy HARD drive where I can place my HARD disk to store data and SSD is used onl

  • HP D4360 printer - alignment problem?

    My watch of the half cut letters (upper half), Headline is not yet printed on the page, a clear text than the rest of the text, white line crosses SOME of the lines of text, page #s top (right) not printed. Note: I have a new cartridge it works fine.

  • Create my own conversion to global channel

    I have global channels provided for in each of my kitchen, and they all have different thermocouples. Because TCs Platinel II are not in the options for thermocouple, I made my own equation of conversion using Chebyschev polynomials. Is it possible t

  • How to install spell check outlook express?

    How to get the spell checker in my outlook as re installed windows xp exspres