Folder Selection loops end

Hi All,
I have this script to relink images to new name and path.
When I run this script select folder dialogue display again and again (match with doc links length). I mean if document has 15 links select folder dialogue display 15 times.
Can anybody please help me to resolve it. See below my Code:
var updatedLinks = myInddLinks[i].name.replace ("oldtext", "newtext");
var myFolder = Folder.selectDialog("Select the links folder", "");
var getLinks = Folder(myFolder).getFiles (updatedLinks);
if (getLinks.length == 1)
myInddLinks[i].relink(getLinks[0]);
Thanks,
Mon

Sorry guys to bother you.
I have resolved this problem myself.
Thanks anyway.
Mon

Similar Messages

  • Problem in moving to next record in  For Loop end loop construct

    Hi friends i have the followind code in my stored proc. I am reading each row in the temprec and then based on the variable "i_copy_notes" processing the record. If the value of the I_copy_notes" varialble is 1 then i need to move to next record. when I am using "Next" then the compiler is telling me that the "NEXT" must be declared. Please advise.
    FOR TEMPREC IN
    SELECT
    DP_SER,
    GRD_POS,
    TS_POS,
    ASG_ID,
    DESCS,
    GRD_ID
    FROM DCGRD_POS
    WHERE CLLI = i_FROM_CLLI AND SUBSYS = i_SUBSYS AND BAY_ID = v_OLD_BAY_ID ORDER BY GRD_ID
    LOOP
    IF v_OLD_GRDID = TEMPREC.GRD_ID THEN
    v_NEW_GRDID := v_NEW_GRDID;
    IF i_COPY_NOTES = 1 THEN
    Next;
    END IF;
    ELSE
    v_OLD_GRDID := TEMPREC.GRD_ID;
    SELECT DCGRD_POS_GRD_ID.NextVal INTO v_NEW_GRDID FROM DUAL;
    END IF;
    INSERT INTO DCGRD_POS VALUES
    i_TO_CLLI,
    DCGRD_POS_ROW_SER.NextVal,
    TEMPREC.DP_SER,
    v_NEW_GRDID,
    v_NEW_BAY_ID,
    TEMPREC.GRD_POS,
    DECODE(i_COPY_NOTES,1, TEMPREC.TS_POS,''),
    TEMPREC.ASG_ID,
    DECODE(i_COPY_NOTES,1,TEMPREC.DESCS,'UASGN'),
    i_CURRENT_ISSUE,
    -1,
    i_SUBSYS,
    SYSDATE,
    i_USERID
    END LOOP;
    Line # = 315 Column # = 10 Error Text = PLS-00201: identifier 'NEXT' must be declared
    Line # = 315 Column # = 10 Error Text = PL/SQL: Statement ignored
    ----------------------------------------------

    Personally, I'm not a big fan of this technique but you can use a goto ...
    begin
    for i in 1.. 10 loop
       if i < 5 then
         goto end_of_loop;
       end if;
       dbms_output.put_line(i);
       <<end_of_loop>>
       null;
    end loop;
    end;

  • For r in (select) loop: execution plan question

    Hi there,
    I have a procedure which does the following (on Oracle 11.1.0.7):
    begin
      for r in (select col1,max(col2) as col2 from tab@remote_db group by col1 ) loop
        update tab2
           set col_a = r.co1
           where col_b = r.col2;
        commit;
      end loop;
    end;The subselect from the remote table delivers about 4000 rows.
    When executing fast, the procedure runs about 20 seconds, the trace shows that the select is executed 1 time, fetches 49 times. The update executes 4000 times.
    When executing slow, the procedure runs about 20 minutes (!), the trace shows that the select is executed 1 times, fetches 4000 times. The update executes 4000 times.
    This happens without changing the code, from the same client (sqlplus on the server, same version as database).
    Can anyone probably give me a clue how I could track down the plsql execution steps like the optimizer trace that let you see why a certain sqlplan was not taken or what might cause that change in behavior?
    I cannot produce that behavior at will - most times the procedure runs fast.
    thanks,
    Heimo

    Hi again,
    regarding the "faulty test" and what is fastest: user tested both versions and came up with the for-loop to satisfy him best. I would, of course, utilize event 10046 and tkprof and a repeatable dataset to have solid data. Sorry for not setting enough emphasis on my real question, which is described in the following.
    But, and that is what is really causing awkward feelings for me: when doing plain sql, I can use events 10046, 10053 and learn from the tracefiles why a decision was taken (now that is making me feel good, actually). But when it comes to plsql, I have not yet such a handy toolset that helps me understand what influences the plsql-engine to go this or that way.
    Thus, I valued the posts pointing to dbms_trace and plsql_optimization_level as helpful answers.
    Because of that I learned about the views %_PLSQL_OBJECT_SETTINGS and remembered to check for other plsql-initora settings.
    I also verified that neither the 10046 nor the 10053 trace files contain any reference to plsql-parameters/settings, and that the 10053 trace only shows the subselect and update, but no info if it would "bulkify" or not.
    Meanwhile I did start to utilize dbms_trace (which causes the statement to go the unbulkifyed by the way) and maybe I can learn from that output or from following posts?
    best regards
    Heimo

  • CL_GUI_FRONTEND_SERVICES in select loop

    Hi all,
    I have a problem using CL_GUI_FRONTEND_SERVICES=>FILE_EXIST within a select loop. I want to loop through a databasetable with filenames and if the file exists, do some stuff with it. The method works good, but when the loop is executed and the next SELECT is executed I get a short dump:
    DBIF_RSQL_INVALID_CURSOR
    CX_SY_OPEN_SQL_DB
    Invalid interruption of a database selection.
    This is my code:
    SELECT file FROM files  INTO l_file.
                   WHERE EXTID = p_extid AND UNAME = sy-uname.
    CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_EXIST
                    EXPORTING
                      FILE                 = l_strfloc
                      RECEIVING
                      RESULT               = l_result.
    ENDSELECT.

    Better select data into table.
    then use
    LOOP AT ITAB.
       CALL GUI_FRONT END SERVICES.
    ENDLOOP.
    OTHER WISE......you cannot interfere the Prsentation (Desktop) Servier Logic with the DATA BASE LOGIC ....SELECT ENDSELECT.
    Vijay

  • Apple loops for garageband pack doesn't show the folder content (loops, files...)  in ableton live suite 8 library browser, but I can see all the loops in the folder from finder. how can i fix this? help please.

    apple loops for garageband pack doesn't show the folder content (loops, files...)  in ableton live suite 8 library browser, but I can see all the loops in the folder from finder. how can i fix this? help please.

    Thanks Barney, I tried that but all that comes up in Spotlight are the log files that show the file paths! I don't know how Steam works. Are all the files held by Steam on their server perhaps?

  • Splitting a document,in output options you select the target folder to be "the same folder selected at start"? Where is that folder?

    When splitting a document, in output options you can select the target folder to be "the same folder selected at start", but where is that folder?  I assumed it would be the original location of the source file but in my test the split files are not there just the source file.

    Have you checked My Documents? You might close Acrobat and reopen, then see what folder comes up when you select File>Open.

  • Slow Performance During Folder Selection in Miggui

    I am trying to migrate some 30,000 folders from an NSS volume on NW 6.5 SP5 server to an NSS volume on a server running OES2 SP3 on SLES 10 SP4.
    Using the miggui from the OES server, I can authenticate to both servers, and select File System as the service to be migrated. Both servers show up in the list and I can expand the folders and select what I want to migrate. Now here's where I'm getting stuck: I select a subset (say 1,000 folders) and drag them to the destination. Once I let go the mouse, it sits there for hours. If I look at the target destination, a folder appears once every few minutes. What did I forget to turn on/configure in order to get this to speed up???
    I saw a message that said to increase the cache values for the TSA on the source. I tried that and it didn't help. However, I'm assuming that the TSA only gets used when you actually migrate the data and not during the pre-copy checks.
    Any help is appreciated!
    Mario
    Laurentian University

    $(UI tried with 10k folders drag-drop on the target and it took approximately 20 minutes to show it on the Target Server folder tree. I haven't tried it with 30k folders yet.
    All you have to do is select the folder range on the source server and drop exactly on the target volume/folder. You can tailf /var/opt/novell/migration/<my_project>/log/debug.log and notice the messages like:
    '<time_stamp> DEBUG - Path of folder selected /NSS Volumes/VOL1', running for every folder created on target.
    If you see message in debug.log as 'Drag and drop in progress: java.awt.dnd.InvalidDnDOperationException: Drag and drop in progress', means either the drop on the target is not accurate or off the tree.
    -Ramesh
    >>> Gingrasm<[email protected]> 11/16/2011 10:36 PM >>>
    I am trying to migrate some 30,000 folders from an NSS volume on NW 6.5
    SP5 server to an NSS volume on a server running OES2 SP3 on SLES 10
    SP4.
    Using the miggui from the OES server, I can authenticate to both
    servers, and select File System as the service to be migrated. Both
    servers show up in the list and I can expand the folders and select what
    I want to migrate. Now here's where I'm getting stuck: I select a
    subset (say 1,000 folders) and drag them to the destination. Once I let
    go the mouse, it sits there for hours. If I look at the target
    destination, a folder appears once every few minutes. What did I forget
    to turn on/configure in order to get this to speed up???
    I saw a message that said to increase the cache values for the TSA on
    the source. I tried that and it didn't help. However, I'm assuming
    that the TSA only gets used when you actually migrate the data and not
    during the pre-copy checks.
    Any help is appreciated!
    Mario
    Laurentian University
    Gingrasm
    Gingrasm's Profile: http://forums.novell.com/member.php?userid=14183
    View this thread: http://forums.novell.com/showthread.php?t=448307

  • When to use SELECT and END SELECT in the query.

    hi all,
    When to use SELECT and END SELECT in the query.
    regads,
    Venkata Suresh Penke.

    Hi Suresh..
    When do we need to use SELECT .. ENDSELECT
    Usually we will never use SELECT .. ENDSELECT as it gives very poor performance.
    But whenever we read a single Record we will use it as an alternative for SELECT SINGLE in some scenarios.
    Eg: When the Full primary key is not specified in the WHERE clause.
    SELECT * FROM MARC INTO WA_MARC UP TO 1 ROWS WHERE MATNR = P_MATNR.
    ENDSELECT.
    And other scenario is when we perform AGGREGATE OPERATIONS.when the Result is only one row.
    SELECT SUM( LABST ) FROM MARD INTO V_LABST UP TO 1 ROWS
    WHERE MATNR = P_MATNR.
    ENDSELECT.
    Note: In The Above scenario we cannot use SELECT SINGLE..
    <b>REWARD IF HELPFUL.</b>

  • About start-of-selection and end-of-selection

    Hi all,
      what is the functionality of start-of-selection and end-of-selection events in reports.

    Here we go :
    Start-of-selection is the event where you will code ur sql statements, this is the event which will be triggered automatically even for normal programs, not only for reports even if you dont specify this event in the program.
    At Selection screen is the event to validate the input values given in the selection screen using initialization event.
    First in the sequence AT SELECTION SCREEN event will be triggered and then START-OF-SELECTION.
    END-OF-SELECTION, will fire only when you actually write it after the selection of the data is over. Usually between the START and END OF SELECTION you fetch the data and after the END OF SELECTION, you process the data and write that as output as display the same as ALV.
    If helpful pl reward.
    Cheers.

  • Bridge cs6 - different sets of keywords based on folder selected?

    In Bridge CS6 I would like the selection of available keywords in the keywords panel, to change based upon the folder selected in the folders panel.
    For example, in my hobby of woodworking I plan to have a multitude of keywords in a folder structure that would describe everything from the wood used to the joinery used; in the computer consulting business I will have a folder structure to describe various projects.
    I realize that I can twirl folder branches open, but I would like to not have the woodworking options available for the consulting disk folders and the consulting keyword options be available within the woodworking disk folders.
    Is this possible?
    If not, is it possible to have which keywords twilled open based upon the folder or favorite I have selected?
    Thanks in Advance
    I am a beginner with Photoshop and am trying to teach myself how to use the software.  Please be patient with me.
    Comments, observations, and suggestions are my express opinions and do not reflect any company that I own, are associated with, consult or work for.

    Keywords ar global. Anything else would defeat the purpose of searchable catalogs. At best you could define different custom categories and data fields in your XMP settings and use that, but even then they wont contextually appear or hide.
    Mylenium

  • Why is my iPhoto library greyed out in the Screensaver folder selection dialog on one iMac but not my other?

    Why is my iPhoto library greyed out in the Screensaver folder selection dialog on one iMac but not my other?

    I have an update to my issue above, with a Semi-solution found. I brought my Macbook Air back to the Genus bar today and they were able to identify (using “Activity Monitor”) that when the particular iPhoto library was being launched through iPhoto both Photostream and iPhoto's CPU% usage was excessively high (between 100% - 200% each). She discovered that if we turn off Photostream in iCloud settings iPhoto then behaved fast and snappy and CPU% came back down to a healthier level. When we turned Photostream back on the problem continued. After an hour of trying to trouble shoot why Photostream was causing the issue they recommended I keep Photostream turned off until a future software update/fix comes out. The particular Genus I worked with was not familiar with this issue. I’m very happy to at least be able to use iPhoto again, but if anyone has ideas or theories on how the Photostream conflict can be fixed please share. Thanks.

  • Why doesn't my while loop end?

    * Main method
    public static void main(String args[])
    Scanner sc = new Scanner(System.in);
    //get input
    String hexa = "nothing";
    while (hexa != "q")
    System.out.println("");
    System.out.println("Please enter a hexadecimal to convert to binary, enter q to quit");
    hexa = sc.next();
    int hexlength = hexa.length();
    for (int i = 0; i < hexlength; i ++)
    char hexadec = hexa.charAt(i);
    //send to subprogram
    findBinary(hexadec, hexlength);
    why doesn't my while loop end when i enter q?

    The equals method returns a boolean (true/false). So you simply negate the returned value.
    if( ! methodCall()) {
    }

  • What happens to my files on creative cloud folder after the end of my subscription?

    What happens to my files on creative cloud folder after the end of my subscription?

    Creative Cloud Help | Creative Cloud / Common Questions
    "What happens to my files in the cloud if I cancel or downgrade my membership?
    Your Creative Cloud files are stored on your desktop as well as on the Creative Cloud servers. If you cancel or downgrade your paid membership, you will still have access to all of the files in the Creative Cloud folder on your computer and via the Creative Cloud website.
    Your account will be downgraded to a free membership, which includes 2GB of storage. If you’re using more than 2GB of storage, you will not be able to upload any new files to the cloud until the amount of online space used in your account drops below your allotted amount.
    If you are over your storage limit, you have 90 days to reduce your online usage or you may lose access to some or all of your files saved on the Creative Cloud servers."

  • F4 for selecting folder from front end

    Hi,
    The function module KD_GET_FILENAME_ON_F4 can be used for selecting a file from the front end.
    Similar way, I need to select a folder name (not specific file in it) through F4 help on to a parameter entry on the selection screen.
    Anyone can help me with the relevant fn module or method.
    Advance Thanks
    Aadarsh

    HI.
    Using ABAP Objects suits better to ur requirement.
    The class CL_GUI_FRONTEND_SERVICES should be used. In that a default method is there which shall give u list of directories.
    Thanks and regards,
    Maheshwari.V

  • How do I select the end of a row or column in Numbers?

    I am trying to select to the end of a column in Numbers. In Excel, I simply hold down the shift+command+arrow keys and I can select the entire row or column int he arrow direction. How do I do this in Numbers?

    Here two other scripts :
    Select-to-top and select-to-left.
    Both of them take care of possible headers.
    --{code}
    --[SCRIPT select-to-top]
    Enregistrer le script en tant que Script : select-to-top.scpt
    déplacer le fichier ainsi créé dans le dossier
    <VolumeDeDémarrage>:Utilisateurs:<votreCompte>:Bibliothèque:Scripts:Applications :Numbers:
    Il vous faudra peut-être créer le dossier Numbers et peut-être même le dossier Applications.
    Sélectionner une ou plusieurs cellules d'une ligne dans une table de Numbers
    Aller au menu Scripts , choisir Numbers puis choisir “select-to-top”
    Il étendra la sélection jusqu'à la première ligne standard de la colonne (ne sélectionne pas les rangs d’en tête).
    Bien entendu, ce script sera plus intéressant si vous le dotez d'un raccourci clavier à l’aide, par exemple, de FastScripts.
    --=====
    L’aide du Finder explique:
    L’Utilitaire AppleScript permet d’activer le Menu des scripts :
    Ouvrez l’Utilitaire AppleScript situé dans le dossier Applications/AppleScript.
    Cochez la case “Afficher le menu des scripts dans la barre de menus”.
    Sous 10.6.x,
    aller dans le panneau “Général” du dialogue Préférences de l’Éditeur Applescript
    puis cocher la case “Afficher le menu des scripts dans la barre des menus”.
    --=====
    Save the script as a Script: select-to-top.scpt
    Move the newly created file into the folder:
    <startup Volume>:Users:<yourAccount>:Library:Scripts:Applications:Numbers:
    Maybe you would have to create the folder Numbers and even the folder Applications by yourself.
    Select one or several cells in a row of a Numbers table.
    Go to the Scripts Menu, choose Numbers, then choose “select-to-top”
    It will expand the selection to the first standard row of the table (minus header rows).
    Of course, it would be more useful if you attach a shortcut thanks to a tool like FastScripts.
    --=====
    The Finder’s Help explains:
    To make the Script menu appear:
    Open the AppleScript utility located in Applications/AppleScript.
    Select the “Show Script Menu in menu bar” checkbox.
    Under 10.6.x,
    go to the General panel of AppleScript Editor’s Preferences dialog box
    and check the “Show Script menu in menu bar” option.
    --=====
    Yvan KOENIG (VALLAURIS, France)
    2012/02/09
    --=====
    on run
              my activateGUIscripting()
              set {dName, sName, tName, rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
              tell application "Numbers" to tell document dName to tell sheet sName to tell table tName
                        set count_HeaderRows to my countXers("Numbers", "R")
                        set selection range to range ((name of cell (1 + count_HeaderRows) of column colNum1) & " : " & (name of cell rowNum1 of column colNum2))
              end tell
    end run
    --=====
    set { dName, sName, tName,  rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
    tell application "Numbers" to tell document dName to tell sheet sName to tell table tName
    on get_SelParams()
              local d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2
              tell application "Numbers" to tell document 1
                        set d_Name to its name
                        set s_Name to ""
                        repeat with i from 1 to the count of sheets
                                  tell sheet i to set maybe to the count of (tables whose selection range is not missing value)
                                  if maybe is not 0 then
                                            set s_Name to name of sheet i
                                            exit repeat
                                  end if -- maybe is not 0
                        end repeat
                        if s_Name is "" then
                                  if my parleAnglais() then
                                            error "No sheet has a selected table embedding at least one selected cell !"
                                  else
                                            error "Aucune feuille ne contient une table ayant au moins une cellule sélectionnée !"
                                  end if
                        end if
                        tell sheet s_Name to tell (first table where selection range is not missing value)
                                  tell selection range
                                            set {top_left, bottom_right} to {name of first cell, name of last cell}
                                  end tell
                                  set t_Name to its name
                                  tell cell top_left to set {row_Num1, col_Num1} to {address of its row, address of its column}
                                  if top_left is bottom_right then
                                            set {row_Num2, col_Num2} to {row_Num1, col_Num1}
                                  else
                                            tell cell bottom_right to set {row_Num2, col_Num2} to {address of its row, address of its column}
                                  end if
                        end tell -- sheet…
                        return {d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2}
              end tell -- Numbers
    end get_SelParams
    --=====
    on parleAnglais()
              local z
              try
                        tell application "Numbers" to set z to localized string "Cancel"
              on error
                        set z to "Cancel"
              end try
              return (z is not "Annuler")
    end parleAnglais
    --=====
    on activateGUIscripting()
      (* to be sure than GUI scripting will be active *)
              tell application "System Events"
                        if not (UI elements enabled) then set (UI elements enabled) to true
              end tell
    end activateGUIscripting
    --=====
    set count_Row_Headers to my countXers("Numbers","R")
    set count_Column_Headers to my countXers("Numbers","C")
    set count_Footers to my countXers("Numbers","F")
    set count_Row_Headers to my countXers("Pages","R")
    set count_Column_Headers to my countXers("Pages","C")
    set count_Footers to my countXers("Pages","F")
    on countXers(theApp, what)
              local mt, mi, mm, ms
              if theApp is "Numbers" then
                        set mt to 6 (* Table *)
                        if "Row" starts with what then
                                  set mi to 10
                        else if "Column" starts with what then
                                  set mi to 11
                        else if "Footer" starts with what then
                                  set mi to 14
                        else
                                  if my parleAnglais() then
                                            error "“" & what & "” isn’t a valid parameter !"
                                  else
                                            error "« " & what & " » n’est pas un paramètre géré !"
                                  end if -- parleAnglais
                        end if -- "Row"…
              else if theApp is "Pages" then
                        set {mt, mi} to {6, 4} (* Format, Table *)
                        if "Row" starts with what then
                                  set mm to 13
                        else if "Column" starts with what then
                                  set mm to 14
                        else if "Footer" starts with what then
                                  set mm to 15
                        else
                                  if my parleAnglais() then
                                            error "“" & what & "” isn’t a valid parameter !"
                                  else
                                            error "« " & what & " » n’est pas un paramètre géré !"
                                  end if -- parleAnglais
                        end if -- "Row"…
              else
                        if my parleAnglais() then
                                  error "The application “" & theApp & "” isn’t driven by this script !"
                        else
                                  error "L’application « " & theApp & " » n’est pas gérée par ce script !"
                        end if -- parleAnglais
              end if -- theApp…
      activate application theApp
              tell application "System Events" to tell process theApp to tell menu bar 1 to tell menu bar item mt to tell menu 1 to tell menu item mi to tell menu 1
                        if theApp is "Numbers" then
    Here we are in Numbers *)
                                  repeat with ms from 1 to 6
                                            try
                                                      (get value of attribute "AXMenuItemMarkChar" of menu item ms) = "✓"
                                                      exit repeat
                                            end try
                                  end repeat
                        else
    Here we are in Pages *)
                                  tell menu item mm to tell menu 1
                                            repeat with ms from 1 to 6
                                                      try
                                                                (get value of attribute "AXMenuItemMarkChar" of menu item ms) = "✓"
                                                                exit repeat
                                                      end try
                                            end repeat
                                  end tell -- menu item mm
                        end if -- theApp is …
              end tell -- System Events…
              return ms - 1
    end countXers
    --=====
    --[/SCRIPT]
    --{code}
    --{code}
    --[SCRIPT select-to-left]
    Enregistrer le script en tant que Script : select-to-left.scpt
    déplacer le fichier ainsi créé dans le dossier
    <VolumeDeDémarrage>:Utilisateurs:<votreCompte>:Bibliothèque:Scripts:Applications :Numbers:
    Il vous faudra peut-être créer le dossier Numbers et peut-être même le dossier Applications.
    Sélectionner une ou plusieurs cellules d'une colonne dans une table de Numbers
    Aller au menu Scripts , choisir Numbers puis choisir “select-to-left”
    Il étendra la sélection jusqu'à la première colonne standard de la table (ne sélectionne pas les colonnes d’en tête).
    Bien entendu, ce script sera plus intéressant si vous le dotez d'un raccourci clavier à l’aide, par exemple, de FastScripts.
    --=====
    L’aide du Finder explique:
    L’Utilitaire AppleScript permet d’activer le Menu des scripts :
    Ouvrez l’Utilitaire AppleScript situé dans le dossier Applications/AppleScript.
    Cochez la case “Afficher le menu des scripts dans la barre de menus”.
    Sous 10.6.x,
    aller dans le panneau “Général” du dialogue Préférences de l’Éditeur Applescript
    puis cocher la case “Afficher le menu des scripts dans la barre des menus”.
    --=====
    Save the script as a Script: select-to-left.scpt
    Move the newly created file into the folder:
    <startup Volume>:Users:<yourAccount>:Library:Scripts:Applications:Numbers:
    Maybe you would have to create the folder Numbers and even the folder Applications by yourself.
    Select one or several cells in a column of a Numbers table.
    Go to the Scripts Menu, choose Numbers, then choose “select-to-left”
    It will expand the selection to the first standard colomn of the table (minus fheader columns).
    Of course, it would be more useful if you attach a shortcut thanks to a tool like FastScripts.
    --=====
    The Finder’s Help explains:
    To make the Script menu appear:
    Open the AppleScript utility located in Applications/AppleScript.
    Select the “Show Script Menu in menu bar” checkbox.
    Under 10.6.x,
    go to the General panel of AppleScript Editor’s Preferences dialog box
    and check the “Show Script menu in menu bar” option.
    --=====
    Yvan KOENIG (VALLAURIS, France)
    2012/02/09
    --=====
    on run
              my activateGUIscripting()
              set {dName, sName, tName, rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
              tell application "Numbers" to tell document dName to tell sheet sName to tell table tName
                        set count_ColHeaders to my countXers("Numbers", "C")
                        set selection range to range ((name of cell (1 + count_ColHeaders) of row rowNum1) & " : " & (name of cell colNum1 of row rowNum2))
              end tell
    end run
    --=====
    set { dName, sName, tName,  rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
    tell application "Numbers" to tell document dName to tell sheet sName to tell table tName
    on get_SelParams()
              local d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2
              tell application "Numbers" to tell document 1
                        set d_Name to its name
                        set s_Name to ""
                        repeat with i from 1 to the count of sheets
                                  tell sheet i to set maybe to the count of (tables whose selection range is not missing value)
                                  if maybe is not 0 then
                                            set s_Name to name of sheet i
                                            exit repeat
                                  end if -- maybe is not 0
                        end repeat
                        if s_Name is "" then
                                  if my parleAnglais() then
                                            error "No sheet has a selected table embedding at least one selected cell !"
                                  else
                                            error "Aucune feuille ne contient une table ayant au moins une cellule sélectionnée !"
                                  end if
                        end if
                        tell sheet s_Name to tell (first table where selection range is not missing value)
                                  tell selection range
                                            set {top_left, left_right} to {name of first cell, name of last cell}
                                  end tell
                                  set t_Name to its name
                                  tell cell top_left to set {row_Num1, col_Num1} to {address of its row, address of its column}
                                  if top_left is left_right then
                                            set {row_Num2, col_Num2} to {row_Num1, col_Num1}
                                  else
                                            tell cell left_right to set {row_Num2, col_Num2} to {address of its row, address of its column}
                                  end if
                        end tell -- sheet…
                        return {d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2}
              end tell -- Numbers
    end get_SelParams
    --=====
    on parleAnglais()
              local z
              try
                        tell application "Numbers" to set z to localized string "Cancel"
              on error
                        set z to "Cancel"
              end try
              return (z is not "Annuler")
    end parleAnglais
    --=====
    on activateGUIscripting()
      (* to be sure than GUI scripting will be active *)
              tell application "System Events"
                        if not (UI elements enabled

Maybe you are looking for

  • Display aspect ratio is off

    I have just loaded PS Elements 7 on a new computer - HP lAPTOP, Core 2 Duo, Vista Ultimate (64 Bit), 22" external monitor. Every image file I open does not display correctly - the aspect ratio is off. If the image size is 8-1/2" x 11", it displays as

  • Who Wants To Be A Hero?

    Hi everyone, Have had my MBP for about a week now and absolutely love it. No problems with installing software or even with using Windows XP through boot camp. In all I am very happy. I do have one issue though (minor one) that if anyone can help me

  • I tried to send and email file that was too large and now my email is not working. the draft continue to repopulate over and over

    I need help with email. I composed a new mail with an attachment that was too large. I never sent it, but it locked my mail up and continues to repopulate the draft.

  • Hide line items on an invoice

    Is there any way to pick and choose or define which line items will appear on an invoice?

  • Db writer? how many?

    Hi, in my dataware house environment i have some i/o questions. AWR reports: In the Load profile Redo size is the first. Other wait events is db file sequential read, db file scattered read and log file parallel write. dbwr_io_slaves=0 and db_writer_