Scripting syntax to add a dash to a stroke?

I can't seem to figure out the syntax to add a dash to a stroke on a shape layer object.  For example, given the following "Dash 1" which I added interactively in the GUI, how would I have added that to the "Dashes" group programmatically instead?
app.project.item(1).layer("Shape Layer 1")("ADBE Root Vectors Group")("ADBE Vector Group")("ADBE Vectors Group")("ADBE Vector Graphic - Stroke")("ADBE Vector Stroke Dashes")("ADBE Vector Stroke Dash 1")
Also, is this information formally documented anywhere?  I couldn't find it in the CS3 Scripting Guide or in the posts detailing the updates to previous versions.

var dashGroup = app.project.item(1).layer("Shape Layer 1")("ADBE Root Vectors Group")("ADBE Vector Group")("ADBE Vectors Group")("ADBE Vector Graphic - Stroke")("ADBE Vector Stroke Dashes");
dashGroup.addProperty("ADBE Vector Stroke Dash 1");
for (x = 1; x <= dashGroup.numProperties; x++) {
          alert(dashGroup.property(x).matchName);
It appears that each Dash/Gap has a unique matchName, in that they have a different number at the end. There are a total of 7 properties in the Dash group, Dashes and Gaps 1-3 plus the Offset property.

Similar Messages

  • I used scripting brigde to add a movie that has size bigger than 5GB, exactly after two minutes iTunes return a failed, but the processing of the file is actually added to iTunes Library successfully. The copying take more than 5 minutes to complete. Why?

    I used scripting brigde to add a movie that has size bigger than 5GB, exactly after two minutes iTunes return a failed, but the processing of the file is actually added to iTunes Library successfully. The copying take more than 5 minutes to complete. Why the iTunes Scripting Brigde returned failed when it is actually success? It occurred exactly 2 minutes after submit the request to Scripting Brigde. Is this 2 minutes related to the Apple Event time out? if it does, how do I get around this problem? thx

    I can tell you that this is some of the absolutely worst customer service I have ever dealt with. I found out from a store employee that when they are really busy with calls, they have third party companies taking overflow calls. One of those companies is Xerox. What can a Xerox call center rep possibly be able to authorize on a Verizon account?  I'm Sure there is a ton of misinformation out there due to this. They don't note the accounts properly or so everyone can see them. I have been transferred before and have asked if they work for Verizon or a third party also and was refused an answer so, apparently they aren't required to disclose that information. I spent a long time in the store on my last visit and it's not just customers that get the runaround. It happens to the store employees as well and it's beyond frustrating.

  • ACF2 Scripted Host Adapter | Add groups to users

    I am exploring options to provision to ACF2. We need to assign ACF2 groups to users and the ACF2 resource (or mainframes) behave different from other resources. Users get assigned into groups rather than groups getting added to the user.
    To accommodate this we plan to use the ScriptedHost adapter and write a ResourceAction Update script to actually add the user to the group requested. The side effect to this approach is that we now need to code scripts for all other actions like create, delete, disable, enable etc.. Is this how everybody does it - or is there a better approach? I am thinking around the lines of after actions with an ACF2 adapter...
    Also - once you create the scripts as resource actions in the ScriptedHost adapter, do we have control to call them whenever we like - or are they automatically triggered - like the Create resourceaction script is called when a user is assigned the scriptedhost as a resource. So apart from configuring the different script names in the ScriptedHost resource wizard, nothing else needs to be done to make the provisioning work with the ACF2 resource?
    And is the order of script execution automatically maintained - like Login action is called first before the Create action and finally the Logoff action.
    Thanks in advance.

    Hey Anokun,
    I am reading up on how to create Scripted Host Adapters. I will be creating 13 of them soon. I have looked over all the docs I could find and am still a little bit lost. I think that the samplescreenactions can be used as a template. I'm still not quite sure how to go about creating these actual Adapters. I would was wondering if you had an example of a scripted host adapter you had that you could share with me.
    Thanks,
    Nik

  • Why does terminal \h add a dash-number

    I have noticed that mavericks has started to add a dash and a number to local machine names. For example, in a terminal window with a $PS1 \h prompt, "mymachine" has become "mymachine-4"
    Why is this?

    There are several possible causes for this problem.
    1. Two (or more) computers on the local network have the same Bonjour name, such as "X's-MacBook-Pro.local".
    2. You have two simultaneous connections to the same local network: probably Ethernet and Wi-Fi. If applicable, disconnect the Ethernet cable or turn off Wi-Fi.
    3. A Mac wakes from sleep due to network traffic. This is a bug in OS X that may only affect some models.
    4. A device that gets its network address from the router wakes from sleep, and the address it was using before has been assigned to another device.
    5. A third-party wireless router has incompatible settings or firmware. In that case, refer to the manufacturer or ISP for support. Restarting the router may help, temporarily.
    6. See also this support article.
    Rename the computer in the Sharing preference pane.

  • How do i add a gradient as the stroke to text instead of a solid color for PSE10

    I have PSE10 and i got thsi urge to add a gradient as the stroke to a text, but don't know  how...
    help!!!!

    Something like this might work for you:
    1. Ctrl or Cmd click on layer thumbnail in the layers panel with the text.
       That makes a selection of the text
    2. Add a new blank layer below the text layer and go to Edit>Stroke (Outline) Selection and choose Center and the size.
    3. Select>Deselect
    4. Go to Layer>New Fill Layer>Gradient and check Use Previous Layer to Create Clipping Mask
    5. In the Gradient Fill dialog you can experiment with different gradients and settings.

  • MaxL script syntax: How do I add comment lines?

    How do I add comment lines to MaxL scripts? REM didn't work, ' didn't work.
    http://download.oracle.com/docs/cd/E10530_01/doc/epm.931/html_esb_techref/maxl/ddl/utils/shell/syntax.htm

    Hmm, a url delimted by "!" on either side is supposed to allow me to embed a graphic.
    Apparently I am to stupid/impatient/all of the above to figure that out, so check out a code sample from my blog (I am on a roll today with references to this beast) to see what it looks like: Regards,
    Cameron Lackpour                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Script Syntax

    What is the syntax for the scripts in HTML DB? I have found out that it is not SQL*Plus.
    - It only appears to accept SQL commands.
    - It does not accept the semicolon ";". I had to replace semicolons with slashes "/".
    - It does not accept the double dash for a comment line.
    Is the script format documented anywhere? I checked the Help in HTML DB.
    Thanks,
    Michael A. Rife

    You are correct in saying that the SQL Workshop is not functionally equivalent to SQL*PLUS in that it doesn't understand SQL*PLUS commands such as
    column foo format a20
    etc.
    Use a new line and a / to terminate commands in the SQL Workshop. Double slash (//) I don't believe is a valid comment indicator in SQL or PL/SQL. I think that's a Java thing.
    Sergio

  • JS scripted needed to add custom text plus filename to file info in document title

    Would greatly appreciate any help with this one...
    JS script to add custom text plus filename to file info in document title
    many thanks

    Super :O)
    I have a folder of say 50 images and I want to run a JS script batch
    example in the document title :  image Nr 81205
    custom text is "image Nr" +  file name "81205"
    activeDocument.info.title =" image Nr" + decodeURI(activeDocument.name);
    would this be correct without seening the file ext
    many thanks

  • JavaScript script: How to add a DSP Interactive WebView to a page?

    Hi forums experts,
    I'm working on a project where we want to automate the insertion in a indesign (*.indd) of a DSP WebView using a JavaScript (*.jsx) script.
    I did an extensive research of the JavaScript API but i could NOT find any reference of the "DSP", "WebView".
    Is this possible?
    Is there a hidden API located somewhere?
    What is an alternative? IDML?
    Any help would be extremely appreciated.
    Regards

    What i was asking is how to create that "WebView" using JavaScript in InDesign,
    Laubender, i've noticed that XML too, by inspecting thr IDML saved file.
    So what i've done is create an javascript to create a rectangle and add in the exact labels specified in the IDML file (also reported in the previous post).
    AND IT WORKS.
    var myRectangle = myPage.rectangles.add({geometricBounds:[myPageMarginTop, myPageWidth-75-myPageMarginRight, myPageMarginTop+75, myPageWidth-myPageMarginRight]});
                    myRectangle.insertLabel("kAdobeDPSInteractivity_Type", "WebView");
                    myRectangle.insertLabel("kAdobeDPSInteractivity_URL", "/Magazine/codes/index.html");
                    myRectangle.insertLabel("kAdobeDPSInteractivity_UseTransparentBackground", "true");
                    myRectangle.insertLabel("kAdobeDPSInteractivity_ScaleContentToFit", "false");
                    myRectangle.insertLabel("kAdobeDPSInteractivity_IsTrustedContent", "true");
                    myRectangle.insertLabel("kAdobeDPSInteractivity_AutoStart", "true");
                    myRectangle.insertLabel("kAdobeDPSInteractivity_UserInteractionEnabled", "true");
    Regards

  • Script : How to add a progress bar to XMP Writing script ?

    Hi !
    I have this script that works flawlessly but when i execute it on big video files ( > 1GB) bridge doesn't repaint and it looks like it's stuck. I would like to have a progress bar showing % remaining on the task and the name of the file being treated. Can someone point me into the right direction as my adobe scripting knowledge is not that great.
    #target bridge  
    if( BridgeTalk.appName == "bridge" ) { 
    descToTitle = MenuElement.create("command", "Log Comment to Description", "at the end of Tools");
    descToTitle.onSelect = function () {
               if (ExternalObject.AdobeXMPScript == undefined) ExternalObject.AdobeXMPScript = new ExternalObject("lib:AdobeXMPScript");
               var thumb = app.document.selections;
               for(var s in thumb){
                         if(thumb[s].hasMetadata){
                                            var selectedFile = thumb[s].spec;
                                            var myXmpFile = new XMPFile( selectedFile.fsName, XMPConst.UNKNOWN, XMPConst.OPEN_FOR_UPDATE);
                                            var myXmp = myXmpFile.getXMP();
                                            var LogComment = myXmp.getProperty(XMPConst.NS_DM, "logComment");
                                            myXmp.deleteProperty(XMPConst.NS_DC, "description");
                                            myXmp.appendArrayItem(XMPConst.NS_DC, "description", LogComment, 0, XMPConst.ALIAS_TO_ALT_TEXT);
                                            myXmp.setQualifier(XMPConst.NS_DC, "description[1]", "http://www.w3.org/XML/1998/namespace", "lang", "x-default");
                                            if (myXmpFile.canPutXMP(myXmp)) {
                                            myXmpFile.putXMP(myXmp);
                                            myXmpFile.closeFile(XMPConst.CLOSE_UPDATE_SAFELY);
                                             } else {
                          xmpFile.closeFile();
    Thx in advance for helping me !

    I am using this progress bar on bridge. I don't remember who gave it to me time ago.
    Anyway I have adapt it to your script:
    #target bridge  
    if( BridgeTalk.appName == "bridge" ) { 
    descToTitle = MenuElement.create("command", "Log Comment to Description", "at the end of Tools");
    descToTitle.onSelect = function () {
        if (ExternalObject.AdobeXMPScript == undefined) ExternalObject.AdobeXMPScript = new ExternalObject("lib:AdobeXMPScript");
        var thumb = app.document.selections;
        var progBar = new createProgressWindow("Work in Progress", "Please wait", false);
        for (var s in thumb) {
            if(thumb[s].hasMetadata) {
                var selectedFile = thumb[s].spec;
                var myXmpFile = new XMPFile( selectedFile.fsName, XMPConst.UNKNOWN, XMPConst.OPEN_FOR_UPDATE);
                var myXmp = myXmpFile.getXMP();
                var LogComment = myXmp.getProperty(XMPConst.NS_DM, "logComment");
                myXmp.deleteProperty(XMPConst.NS_DC, "description");
                myXmp.appendArrayItem(XMPConst.NS_DC, "description", LogComment, 0, XMPConst.ALIAS_TO_ALT_TEXT);
                myXmp.setQualifier(XMPConst.NS_DC, "description[1]", "http://www.w3.org/XML/1998/namespace", "lang", "x-default");
            progBar.updateProgress (Math.floor((Number(s)+1)*(100/thumb.length)), "Waiting, " + Math.floor((Number(s)+1)*(100/thumb.length)) + "% completed.");
            if (myXmpFile.canPutXMP(myXmp)) {
                myXmpFile.putXMP(myXmp);
                myXmpFile.closeFile(XMPConst.CLOSE_UPDATE_SAFELY);
            } else {
                xmpFile.closeFile();
    function createProgressWindow(title, message, hasCancelButton) {
        var win;
        if (title == null) title = "Work in progress";
        if (message == null) message = "Please wait...";
        if (hasCancelButton == null) hasCancelButton = false;
        win = new Window("palette", "" + title, undefined);
        win.bar = win.add("progressbar", {x: 20,y: 12,width: 300,height: 20}, 0, 100);
        win.stMessage = win.add("statictext", {x: 10,y: 36,width: 320,height: 20}, "" + message);
        win.stMessage.justify = 'center';
        if (hasCancelButton) {
            win.cancelButton = win.add('button', undefined, 'Cancel');
            win.cancelButton.onClick = function() {
                win.close();
                throw new Error('User canceled the pre-processing!');
        this.reset = function(message) {
            win.bar.value = 0;
            win.stMessage.text = message;
            return win.update();
        this.updateProgress = function(perc, message) {
            if (perc != null) {
                win.bar.value = perc;
            if (message != null) {
                win.stMessage.text = message;
        return win.update();
        this.close = function() {
            return win.close();
        win.center(win.parent);
        return win.show();

  • Edit script syntax - Toggle bluetooth according to power setting

    Using a MBPr13 on OSX ML 10.8.4, needing to toggle Bluetooth based on Power source. Found a dated script, but I'm not script savvy so hoping someone could help me edit it:
    #! /bin/bash
    PREVIOUS_SOURCE=$(pmset -g ps | perl -ne '/(w+) Power/ && print $1');
    while [ 1 ]; do
      CURRENT_SOURCE=$(pmset -g ps | perl -ne '/(w+) Power/ && print $1');
      if [ $CURRENT_SOURCE != $PREVIOUS_SOURCE ]; then
        PREVIOUS_SOURCE=$CURRENT_SOURCE
        if [ $CURRENT_SOURCE = "AC" ]; then
          blueutil on
        else
          blueutil off
        fi
      fi
      sleep 5
    done
    When I compile in Apple Script Editor, I get "Expected expression but found unknown token" Syntax Error and the $ character is highlighted (as above).
    Comments posted on the web page where I found this suggest that some of the "escapes on the word characters" have been stripped? Can anyone suggest how this could be edited to work?
    Cheers, Sla

    The previous script doesn't quite work properly, this one is better:
    tell application "System Preferences"
      activate
              set the current pane to pane id "com.apple.preferences.bluetooth"
    end tell
    set _power to do shell script "pmset -g | grep AC"
    set _power to last character of _power
    if _power = "*" then
              tell application "System Events"
                             set _status to checkbox "On" of window "Bluetooth" of application process "System Preferences"
                             tell _status
                                            if not (its value as boolean) then click _status
                             end tell
              end tell
    else
              tell application "System Events"
                             set _status to checkbox "On" of window "Bluetooth" of application process "System Preferences"
                             tell _status
                                            if (its value as boolean) then click _status
                             end tell
              end tell
    end if
    tell application "System Preferences" to quit

  • Using VI server from DIAdem script :: Syntax (documenta​tion) for properties and methods of VI Server objects (for non-labvie​w programmer​s)

    Hello all,
    I am using DIAdem 10.0 Advanced, LabVIEW 8.0 PDS. I would like to start a LabVIEW IHM from a VBS script. I use VI Server to call my VI from DIAdem.
    Here is the script and the VI I use (VI attached):
    Dim lvapp, vi, viPath, paramName(1), paramVal(1)
    Set lvapp = CreateObject("LabVIEW.Application")
    viPath = "C:\TEST\test.vi"
    Set vi = lvapp.GetVIReference(viPath)
    vi.FPWinOpen = True
    paramName(0) = "Input"
    paramVal(0) = 10
    paramName(1) = "Output"
    paramVal(1) = 0
    Call vi.Call(paramName, paramVal)
    Call lvapp.Quit()
    I found a similar example on your web site.
    Question 1:
    I need to know the syntax for all the other properties and methods of a VI object (method like Get or Set Control Value for example).
    Is a documentation (other than the LabVIEW help which is dedicated for LV programmers) exist in order to be able to use all the features of VI Server from another environment (CVI, VB, ...)?
    Question 2:
    Is it possible to call a VI with VI Server with the parameter "Wait until done" to FALSE? (run a VI asynchronuously from DIAdem)
    Thanks for your answer.
    MatthieuG
    Eurilogic
    Attachments:
    Test.vi ‏9 KB

    Hello,
    I finally found a way to get the documentation of VI Server. I can view the "LabVIEW.TLB" type library file with a OLE/COM Object Viewer (a utility from the Windows SDK).

  • Customd validation script syntax

    Hi,
    I use simple acroform created by Acrobat 9 pro with text field. On the text field properties -> validate tab I had put some custom javascript but it has never executed. Can you tell me what must be exact syntax for this script is it suppose to return boolean value or something ?

    There is no return code, but you may need a custom keystroke and format scripts to support the validation script.
    The validation script for inputting the first and last name with each name must start with a capital letter followed by one or more lower case letters and separated by a blank character:
    this.getField(event.target.name).fillColor = color.transparent; //clear field background
    // create RegExp string for required format
    // First and last names begin with one capital letter followed by lower case letters
    var re = /^[A-Z[a-z]+ [A-Z][a-z]+$/;
    // use RegExp test to see if format rule followed
    if (re.test(event.value) == false) {
    app.alert("That does not appear to be a valid name. I need first and last name.", 1, 0); // error message
    // other error processing options
    this.getField(event.target.name).fillColor = color.red; // use red to highlight problem field
    // event.value = ''; // optional to force complete reentry if an error
    app.beep(1); // beep sound
    } // end validation test

  • Having a progblem with action script syntax error

    I am using adobe flash CS3 Professional.
    I am new to flash and have built a time sharing simple advertisement with an invisible button.
    Here is the code:
    inv_btn.addEventListener(MouseEvent.CLICK, clickhandler);
    function clickhandler(event:MouseEvent):void {
    navigateToURL(new URLRequest("http://www.someurl.com.au"));
    When I run it (Ctrl-Enter) the images how correctly but I get the following syntax error referring to the function line :
    '{' expected
    I can't see anything wront with this, and if I paste the same actionscript into a different flash file - it does not generate the error.

    Thanks Ned.
    Spot on - I had it set to flash player 6 and thus only activescript 1.0 and 2.0 available.
    Changed to Flash player 9 and activescript 3 - and all good.
    Thanks Mate.

  • Booting with Ubuntu Grub. Proper syntax to add to Ubuntu's menu.lst?

    This is what I found in my menu.lst:
    # (0) Arch Linux
    title  Arch Linux
    root   (hd2,0)
    kernel /vmlinuz26 root=/dev/sdc3 ro
    initrd /kernel26.img
    # (1) Arch Linux
    title  Arch Linux Fallback
    root   (hd2,0)
    kernel /vmlinuz26 root=/dev/sdc3 ro
    initrd /kernel26-fallback.img
    Is it OK to add it as it is to Ubuntu's menu.lst?
    Thanks a lot.

    True. I'm the kind of guy that likes to use suspenders and a belt. I have time to do it on Thursday, so I figured I'd get advice in the meantime. It never hurts. There is always someone that knows more than one and is willing to help. I think.

Maybe you are looking for

  • Forcing Audition to copy media rather than reference

    Hi all, How do you force Ausition to copy media locally rather than reference it by default. So that when I drag a sound effect from my networked library on to a multitrack session it copies it, rather than referencing the original. By doing this I a

  • 'ORA-12571: TNS:packet writer failure' error while calling procedure from VC++

    hi all, i am writing stored procedures and calling these from vc++. I have one stored procedure in that all in and out perameters are numeric. When i am calling these procedure i am able to get the values properly. But in another procedure one in per

  • Modify the selection screen

    Hi all , This is how I have defines my selection screen : *           S E L E C T   O P T I O N S & P A R A M E T E R S         * SELECTION-SCREEN BEGIN OF BLOCK b1                           WITH FRAME TITLE text-001. SELECTION-SCREEN SKIP 1 . SELECT

  • Delay and cancel delay

    Hello, I'm having some trouble delaying single keyframes keyframe in flash. I'm making a 5 slide slideshow over 5 frames. Each frame needs to last about 4000ms, although this is flexible. BUT the 4000ms delay must be able to be reset when a button is

  • Safari 7.0.1 doesn't run in 32 bit mode  under Mavericks

    iMac (27-inch, Late 2012), OS X Mavericks (10.9.1) Safari 7.0.1 -> get info, Open in 32-bit mode checked Launch Safari In the activity monitor -> Disk ->Kind : still  read 64 bit Testing 32 bit mode with another app: Logic Pro- 9.1.8 -> get info, Ope