Please look at this simple script for an issue?

I have a corrupted icloud Contacts issue that another user gave a solution for in the form of an Apple Script he ran on the original Contacts on his computer. He said it worked for him. It didn't work on mine (see below). The script was supposed to remove the untitled groups that were created (for who knows what reason) when I synced the contacts with icloud and other devices. None of the devices ever had contacts in them besides the computer, and the contacts from the computer had never beed synced before. There are over 2,000 of these untitled groups, all of them empty. I sure want this to work, and i realize I will have to run it 40 times or so,  It has already ruined my last 48 hours. Lots of tears, lots of angst, very bad Mother's Day.
missing what value?

1. Change the number in the second line as desired.
2. If the script is working properly as is aside from the fact that it needs to be run many times, don't worry about that.
(82580)

Similar Messages

  • Could someone please sketch out this simple script for me?

    Could someone please sketch out a simple java script for me. I will have a document with one background
    layer and a layer set (group) called "Analyze" that consists of 63 adjustment layers. The layer names in that "Analyze" group(folder) will be
    "01" ...through "63" with 01 on the bottom and 63 at the top. Initially, all of the adjustment layers will be invisible and  the
    group will be closed (not expanded). I need a simple  script that will check for the first invisible layer in that group
    and make it visible without selecting that layer nor expanding the group. The script has to check
    for the first invisible layer every time it runs because other actions may have turned off a layer in the set.
    The point of this is so I can hotkey flipping on the layers one at a time without expanding the set or
    changing focus off the  background. It seems it should be a simple loop, but I just can't wrap  my head
    around all the objects (e.g. Layer as opposed to Layers  and  Artlayer as opposed to Artlayers)
    and the constants constants.
    for (i = 63; i>0; i--){                 /* I have found layer indexes 0 are the topmost layer */
      if( layerset[i] == INVISIBLE){
               layerset[i] = VISIBLE;
                  break;
    Could someone please write me a simple script that would do this?
    Edit I found this and its very close to what I need:
    var doc = app.activeDocument;
    for(var i = 0 ; i < doc.layers.length;i++){
      doc.layers[i].visible = (i % 2 == 0);
    From here : Function to show/hide layer with Photoshop script (JSX) - Stack Overflow
    In my case I would rewrite it to this
    for(var i = 62; i >=0; i--){
         if(  !doc.layers[i].visible){
              doc.layers[i].visible =TRUE;
              break;
    My problem is I just need  to traverse the layers in my layerset "Analyze"
    How do  I reference just those? Is there a doc.layersets["Analyze"].layers[i].visible = TRUE?
    Message was edited by: Shawn Laughlin To add more information

    Well this works:
    var doc = app.activeDocument;
    var analyze = doc.layerSets.getByName("Analyze").layers
    for(var i = 62 ; i >= 0; i --){
        if (!analyze[i].visible){
            analyze[i].visible =1;
            break;
    Hard to believe TRUE is not a constant in java.

  • My $20 to the person who can write this simple script for Fission

    Here is what I need to automate. I don't care if it's an Apple Script, or an Automator work flow - whatever - just so it will work with my present setup. Once I test it and it works, I'll send $20 to the first person who can help me.
    Script needs to apply to each (and every) MP3 file in a selected folder:
    Open the first file with Fission v1.6.6 (from: www.rogueamoeba.com)
    Select all
    Normalize
    Save audio (in same folder)
    A warning dialog pops up: "File already exists..." -- answer with "Replace"
    Close file
    Repeat for next file in the folder, until every file has been Normalized
    End script when the last file in folder has been Normalized
    I don't mind finding the folder (which will be in my iTunes Library), and then starting the set of actions on the folder but I definitely don't want to be required to take any additional action on each and every file.
    I'm presently running Fission v1.6.6 under MacOS 10.4.11 on a PPC desktop, so it needs to work in that environment.
    Note that the latest version of Fission requires MacOS 10.5 - I can't use any script that requires that version. Rogue Amoeba's Legacy software page (http://www.rogueamoeba.com/legacy/) shows Fission v1.6.8 as working with 10.4, but that contradicts the Version History for Fission which shows 1.6.6 as the last one for 10.4 - still investigating.

    Pierre L.
    Thanks for the effort!
    First, I can clarify this: Rogue Amoeba confirms that I can use the version 1.6.8 of Fission located on their Legacy page with my OS version 10.4.11, so I've upgraded from 1.6.6 to 1.6.8. Seems to be working OK.
    Next, let me apologize for being mostly ignorant about all things AppleScript. I'm really in over my head, here, because I've not used the ScriptEditor for more than a few minutes before today.
    What I've done so far:
    I checked the box in the Universal Access preferences pane to enable access for assistive devices.
    I copied your script from this forum and pasted it into Script Editor.
    I've Compiled your script, then "Saved As" an "Application" on my Desktop.
    When I double click the icon for the saved script (which ends in xyz.app), a navigation window appears, which I used to select a test folder on my desktop.
    When I Choose the test folder, Fission launched, and selected the whole file, as expected. Then I get an error:
    "NSReceiverEvaluationScriptError: 4" - with buttons to "Edit" or "OK"
    Thinking it might be a timing error, I edited the delays:
    set theFolder to choose folder
    tell application "Fission" to activate
    tell application "Finder"
    set theApp to POSIX path of (get file of process "Fission")
    set theFiles to document files of theFolder
    repeat with thisFile in theFiles
    open thisFile using POSIX file theApp
    tell application "System Events" to tell process "Fission"
    delay 18 -- adjust if necessary
    keystroke "a" using command down -- Select All
    delay 2 -- adjust if necessary
    click menu item "Normalize Selection" of menu 1 of menu bar item 7 of menu bar 1
    delay 4 -- adjust if necessary
    keystroke "s" using {shift down, command down} -- Save Audio…
    delay 3 -- adjust if necessary
    keystroke return -- Save
    delay 2 -- adjust if necessary
    click button "Replace" of sheet 1 of window "Save Audio"
    end tell
    end repeat
    end tell
    tell application "Fission" to quit -- optional
    ... Compiled, and Saved again.
    Now, the script runs up to the point where it should answer the Save pop-up window: "File already exists..." with the keystroke to "Replace" - but the script stops there, with the same error: "NSReceiverEvaluationScriptError: 4"
    Bottom line: so far, I've been able to get the first mp3 file in my test folder Normalized, but not Saved. Any suggestions?

  • Can you please help me with this simple (not for me:) issue

    Why this doesnt work?
    public void spl ()
         String a=("moon.sun");
    String [] f=a.split(".");
    System.out.println(f[0]);
    }

    The second expression to split() is a regular expression. A period in a regular expression matches all characters, and you're wanting it to just match a period.
    To match just the period for your split, you'll need to escape it:String[] f = a.split("\\.");

  • I am using Firefox 4.0 Beta 10. It doesn't start immediately after I click on the Firefox button located in my shortcut bar. And sometimes it even doesn't open. I don't know why it occurs, so please look into this matter. Thanks!

    Whenever I click on the button of Firefox 4.0 Beta 10 located in my shortcut bar. It opens after a very long time i.e. after 5-10 minutes after I get irritated and start using Safari. And sometimes it doesn't even open. Please look into this matter. :D
    Thanks

    Try disabling hardware acceleration in your Firefox settings and see if it helps:
    From the Firefox menu, go to '''Options''' and click the '''Advanced''' panel, then select the General tab. Clear the box in front of "Use hardware acceleration when available" so that it is unchecked, then restart Firefox. ([http://support.mozilla.com/media/uploads/gallery/images/2011-01-27-04-52-31-8c9d82.png screenshot]).
    Ref: <br>
    https://blog.mozilla.com/tglek/2010/12/21/rude-surprise-startup-overhead-of-windows-font-apis/

  • Need help making a simple script for my webcam

    Hey everyone, fairly new to applescript programming. I just bought a usb camera for my macbook because I use it for video conferencing/playing around, and it is better quality than the built in isight. However, in order to use this camera I need to use drivers from a program called camTwist. This being said camTwist needs to be opened first and the usb camera must be selected from camTwist Step 1 list in order for any other application to use the camera. I just want to make a simple program that would open camTwist first, then select "webcam" from the list (double click it like I always have to in order to select it) in order to activate the driver, and then open photo booth which would then be using the camTwist driver in order to take pictures.
    I made a crude program but it does not automatically select "webcam" from the Step 1 list in camTwist:
    tell application "CamTwist" to activate
    delay 10
    tell application "Photo Booth" to activate
    that’s basically it. I set the delay to 10 seconds so that when camTwists boots up first I can manually select my webcam. HOWEVER, I would like to make a script that would boot up CamTwist first, select my webcam from the list automatically, and then open Photo Booth with the CamTwist webcam driver already selected.
    Don't know much about applescript so any help to make a working script to solve my problem would be greatly appreciated! Thanks!

    Solved my problem but now I need help with something else! First I used CamTwist user options to create user defined hot keys with the specific purpose to load the webcam. I chose Command+B. I tested it out in CamTwist and it worked. The program follows a logical order from there. First it loads CamTwist, then after a short delay it presses the hot keys in order to load the webcam from the video source list, then another short delay and Photo Booth is opened with the driver loaded from camTwist. Everything works Perfect! Here's the code:
    tell application "System Events"
    tell application "CamTwist" to activate
    delay 0.5
    --Press command+b which is a user defined hot key to load webcam
    key code 11 using command down
    end tell
    delay 0.5
    tell application "Photo Booth" to activate
    My Next question is, would it be possible with this same script to have both applications quit together. For example I always quit Photo Booth first, so when I quit photo booth is there a way to make CamTwist also quit and keep everything within the same script? Please let me know. This forum has been very helpful and lead me to a solution to my problem! Hoping I can solve this next problem as well! Thanks everyone.

  • Can anybody fix this apple script for me so all the responses work

    iv been working on a jarvis wake up script and iv continued to add on commands to if theResponce parts of the script but now most of them wont work and i get a syntax if i dont have like 8 end if's at the end of the script could somebody please overview it, fix the script and resubmit it to me in the comments. will be so grateful if somebody fixes this pleasee.!!!!
    set theHours to hours of the (current date)
    if theHours > 18 then
              say "good evening sir"
    else if theHours > 12 then
              say "good afternoon sir"
    else if theHours > 6 then
              say "good Morning sir"
    else if theHours > 0 then
              say "get out of bed sir!"
    end if
    say "It is " & getTimeInHoursAndMinutes() using "Tom"
    on getTimeInHoursAndMinutes()
              set timeStr to time string of (current date)
              set Pos to offset of ":" in timeStr
              set theHour to characters 1 thru (Pos - 1) of timeStr as string
              set timeStr to characters (Pos + 1) through end of timeStr as string
      -- Get the "minute"
              set Pos to offset of ":" in timeStr
              set theMin to characters 1 thru (Pos - 1) of timeStr as string
              set timeStr to characters (Pos + 1) through end of timeStr as string
      --Get "AM or PM"
              set Pos to offset of " " in timeStr
              set theSfx to characters (Pos + 1) through end of timeStr as string
              return (theHour & ":" & theMin & " " & theSfx) as string
    end getTimeInHoursAndMinutes
    set CityCode to 1098081
    set t_format to "C"
    set v_format to "S"
    set a_format to "Y"
    set IURL to "http://weather.yahooapis.com/forecastrss?w=" & CityCode
    set file_content to (do shell script "curl " & IURL)
    --looking for the line with actual condition
    set theText to text ((offset of "yweather:condition" in file_content) + 1) thru -1 of file_content
    set sub_1 to text ((offset of "\"" in theText) + 1) thru -1 of theText
    set actual_condition to text 1 thru ((offset of "\"" in sub_1) - 1) of sub_1
    set sub_1a to text ((offset of "temp=" in sub_1)) thru -1 of sub_1
    set sub_1b to text ((offset of "\"" in sub_1a) + 1) thru -1 of sub_1a
    set actual_temp to text 1 thru ((offset of "\"" in sub_1b) - 1) of sub_1b
    if t_format is equal to "C" then
              set actual_temp to (5 / 9) * (actual_temp - 32) as integer
    end if
    set theText to text ((offset of "yweather:forecast" in file_content) + 1) thru -1 of file_content
    set sub_2 to text ((offset of "\"" in theText) + 1) thru -1 of theText
    set today_min_temp to word 9 of sub_2
    set today_max_temp to word 12 of sub_2
    if t_format is equal to "C" then
              set today_min_temp to (5 / 9) * (today_min_temp - 32) as integer
              set today_max_temp to (5 / 9) * (today_max_temp - 32) as integer
    end if
    set sub_3 to text ((offset of "text" in sub_2) + 1) thru -1 of sub_2
    set sub_4 to text ((offset of "\"" in sub_3) + 1) thru -1 of sub_3
    set today_forecast to text 1 thru ((offset of "\"" in sub_4) - 1) of sub_4
    set sub_5 to text ((offset of "yweather:forecast" in sub_4) + 1) thru -1 of sub_4
    set sub_6 to text ((offset of "\"" in sub_5) + 1) thru -1 of sub_5
    set tomorrow_min_temp to word 9 of sub_6
    set tomorrow_max_temp to word 12 of sub_6
    if t_format is equal to "C" then
              set tomorrow_min_temp to (5 / 9) * (tomorrow_min_temp - 32) as integer
              set tomorrow_max_temp to (5 / 9) * (tomorrow_max_temp - 32) as integer
    end if
    set sub_7 to text ((offset of "text" in sub_6) + 1) thru -1 of sub_6
    set sub_8 to text ((offset of "\"" in sub_7) + 1) thru -1 of sub_7
    set tomorrow_forecast to text 1 thru ((offset of "\"" in sub_8) - 1) of sub_8
    if a_format is equal to "Y" then
              say "The current conditions in Perth are " & actual_condition & " ,and the current temperture is " & actual_temp & " degrees"
    end if
    if v_format is equal to "L" then
              say "Today it will be : " & today_forecast & ". Temperature: between " & today_min_temp & " and " & today_max_temp & " degrees .
              Tomorrow we are expecting it to be: " & tomorrow_forecast & ". Temperature: between " & today_min_temp & " and " & today_max_temp & " degrees " using "Tom"
    else
              say "Today it will be : " & today_forecast & ", between " & today_min_temp & " , and " & today_max_temp & " degrees .
               Tomorrow we are expecting it to be: " & tomorrow_forecast & ", between " & tomorrow_min_temp & " ,and " & tomorrow_max_temp & " degrees " using "Tom"
              say "will that be all sir?"
              tell application "SpeechRecognitionServer" to set theResponse to listen for {"get my mail ", "yes", "notes", "repeat", "Music", "Sleep in"}
              if theResponse is "Sleep in" then
      delay 6
                        say "Time to get up sir,or you will be late"
                        tell application "SpeechRecognitionServer" to set theResponse2 to listen for {"Ok pat im getting up"}
                        if theResponse2 is "Ok pat im getting up" then
      set volume 35
                                  tell application "iTunes"
                                            set the sound volume to 0
      play user playlist "Wake up"
                                            repeat 10 times
                                                      if sound volume is less than 40 then
                                                                set sound volume to (sound volume + 10)
                                                                delay 2
                                                      end if
                                            end repeat
                                  end tell
                                  if theResponse is "Music" then
      set volume 20
                                            tell application "iTunes"
                                                      set the sound volume to 0
      play user playlist "Wake up"
                                                      repeat 10 times
                                                                if sound volume is less than 60 then
                                                                          set sound volume to (sound volume + 10)
                                                                          delay 2
                                                                end if
                                                      end repeat
                                            end tell
                                            if theResponse is "yes" then
                                                      delay 1
                                                      set theOptions to {"very good, sir, have a nice day"}
                                                      set theChoice to some item of theOptions
      say theChoice displaying theChoice with waiting until completion
                                            end if
                                            if theResponse is "get my mail " then
                                                      tell application "Mail" to launch
                                            end if
                                            if theResponse is "notes" then
                                                      tell application "Stickies" to launch
                                            end if
                                            if theResponse is "repeat" then
                                                      set CityCode to 1098081
                                                      set t_format to "C"
                                                      set v_format to "S"
                                                      set a_format to "Y"
                                                      set IURL to "http://weather.yahooapis.com/forecastrss?w=" & CityCode
                                                      set file_content to (do shell script "curl " & IURL)
      --looking for the line with actual condition
                                                      set theText to text ((offset of "yweather:condition" in file_content) + 1) thru -1 of file_content
                                                      set sub_1 to text ((offset of "\"" in theText) + 1) thru -1 of theText
                                                      set actual_condition to text 1 thru ((offset of "\"" in sub_1) - 1) of sub_1
                                                      set sub_1a to text ((offset of "temp=" in sub_1)) thru -1 of sub_1
                                                      set sub_1b to text ((offset of "\"" in sub_1a) + 1) thru -1 of sub_1a
                                                      set actual_temp to text 1 thru ((offset of "\"" in sub_1b) - 1) of sub_1b
                                                      if t_format is equal to "C" then
                                                                set actual_temp to (5 / 9) * (actual_temp - 32) as integer
                                                      end if
                                                      set theText to text ((offset of "yweather:forecast" in file_content) + 1) thru -1 of file_content
                                                      set sub_2 to text ((offset of "\"" in theText) + 1) thru -1 of theText
                                                      set today_min_temp to word 9 of sub_2
                                                      set today_max_temp to word 12 of sub_2
                                                      if t_format is equal to "C" then
                                                                set today_min_temp to (5 / 9) * (today_min_temp - 32) as integer
                                                                set today_max_temp to (5 / 9) * (today_max_temp - 32) as integer
                                                      end if
                                                      set sub_3 to text ((offset of "text" in sub_2) + 1) thru -1 of sub_2
                                                      set sub_4 to text ((offset of "\"" in sub_3) + 1) thru -1 of sub_3
                                                      set today_forecast to text 1 thru ((offset of "\"" in sub_4) - 1) of sub_4
                                                      set sub_5 to text ((offset of "yweather:forecast" in sub_4) + 1) thru -1 of sub_4
                                                      set sub_6 to text ((offset of "\"" in sub_5) + 1) thru -1 of sub_5
                                                      set tomorrow_min_temp to word 9 of sub_6
                                                      set tomorrow_max_temp to word 12 of sub_6
                                                      if t_format is equal to "C" then
                                                                set tomorrow_min_temp to (5 / 9) * (tomorrow_min_temp - 32) as integer
                                                                set tomorrow_max_temp to (5 / 9) * (tomorrow_max_temp - 32) as integer
                                                      end if
                                                      set sub_7 to text ((offset of "text" in sub_6) + 1) thru -1 of sub_6
                                                      set sub_8 to text ((offset of "\"" in sub_7) + 1) thru -1 of sub_7
                                                      set tomorrow_forecast to text 1 thru ((offset of "\"" in sub_8) - 1) of sub_8
                                                      if a_format is equal to "Y" then
                                                                say "The current conditions in Perth are " & actual_condition & " ,and the current temperture is " & actual_temp & " degrees"
                                                      end if
                                                      if v_format is equal to "L" then
                                                                say "Today it will be : " & today_forecast & ". Temperature: between " & today_min_temp & " and " & today_max_temp & " degrees .
              Tomorrow we are expecting it to be: " & tomorrow_forecast & ". Temperature: between " & today_min_temp & " and " & today_max_temp & " degrees " using "Tom"
                                                      else
                                                                say "will that be all sir?"
                                                                tell application "SpeechRecognitionServer" to set theResponse3 to listen for {"get my mail ", "yes", "notes", "Music"}
                                                                if theResponse3 is "Music" then
                                                                          set volume 20
                                                                          tell application "iTunes"
                                                                                    set the sound volume to 0
                                                                                    play user playlist "Wake up"
                                                                                    repeat 10 times
                                                                                              if sound volume is less than 60 then
                                                                                                        set sound volume to (sound volume + 10)
                                                                                                        delay 2
                                                                                              end if
                                                                                    end repeat
                                                                          end tell
                                                                else
                                                                          if theResponse3 is "get my mail " then
                                                                                    tell application "Mail" to launch
                                                                          end if
                                                                          if theResponse3 is "yes" then
                                                                                    delay 1
                                                                                    set theOptions to {"very good, sir, have a nice day"}
                                                                                    set theChoice to some item of theOptions

    What you do in this situation, is split the file into parts. 
    Start with:
    set theHours to hours of the (current date)
    if theHours > 18 then
              say "good evening sir"
    else if theHours > 12 then
              say "good afternoon sir"
    else if theHours > 6 then
              say "good Morning sir"
    else if theHours > 0 then
              say "get out of bed sir!"
    end if
    Add in a few lines of code to this file and see what happens. 
    add the on run, this would be clearer.  It is the default on unit to run.
    on run
        set theHours to hours of the (current date)
        if theHours > 18 then
            say "good evening sir"
        else if theHours > 12 then
            say "good afternoon sir"
        else if theHours > 6 then
            say "good Morning sir"
        else if theHours > 0 then
            say "get out of bed sir!"
        end if
    end run
    Now, it is time for debugging.
    It is easier to diagnose problems with debug information. I suggest adding log statements to your script to see what is going on.  Here is an example.
        Author: rccharles
        For testing, run in the Script Editor.
          1) Click on the Event Log tab to see the output from the log statement
          2) Click on Run
    on run
        -- Write a message into the event log.
        log "  --- Starting on " & ((current date) as string) & " --- "
        --  debug lines
        set desktopPath to (path to desktop) as string
        log "desktopPath = " & desktopPath
    end run

  • A simple script for you, a giant script for me-

    I like scripts very much but scripting does not seems to like me! Can anyone help me and write a script for me? What I need is this:
    1. Ungroup everything in a spread
    2. A loop that goes through every text frame in the spread and, at the end of the text contained in each of those frames inserts a blank paragraph. (The frames contains text and inline graphics)
    This may seems strange but is what I need.
    Best regards and thank you in advance
    Maria

    I like scripts very much but scripting does not seems to like me! Can anyone help me and write a script for me? What I need is this:
    It's much easier for you to show us what you have and then we'll fix it for you or tell you what is wrong. Then you'll learn something to!
    1. Ungroup everything in a spread 
    This one's easy -- unless you're worried about groups inside groups?
    app.activeWindow.activeSpread.groups.everyItem().ungroup()
    If it's groups all-the-way-down, on the other hand, well, it might be more than one line...

  • Anybody who wants to create a  small and simple Script for me?

    Hi,
    I am kind of new to Mac and totally AppleScript illiterate, but maybe there is a kind soul amongst all of you that can create an "easy" script for me?
    Well, here it goes:
    Every time I boot up my iMac, two things happen, the first is that I programed the "System Preferences" window to open automatically and display the "Energy Saver" section on the "Sleep" sub-section, so far so good and the second thing is that no matter what I have tried to avoid it, the "Customize" window for a program named "Butler" opens also.
    Now for the request:
    I would like the "System Preference window which displays the Energy Saver section" to change from "Sleep" to "Options" and while being there(in options), to tick(select) AND UN-tick(Un-select) immediately after the "Automatically reduce the brightness of the display before display sleep" Option.
    After doing all of this, the window should be closed.
    Now, is it possible to create a Script that performs all of the above and besides closes the "Butler" window afterwards?
    I know I am asking too much, but I know too that maybe there is someone with a heart of gold and the sufficient knowledge to help me.
    Thanks a lot
    Enrique Diazruanova

    ... Every time I boot up my iMac, two things happen, the first is that I programed the "System Preferences" window to open automatically and display the "Energy Saver" section on the "Sleep" sub-section, so far so good and the second thing is that no matter what I have tried to avoid it, the "Customize" window for a program named "Butler" opens also ...
    From your initial post, it appears that you have the Butler application running and have used it to access one of the Energy Saver opptions already. I don't have that particular application or a laptop to test, but if you've gotten it to access one option it should be able to access another one.

  • Can you please have a look on this small script?[SOLVED]

    Hello guys,
    I am writing a small script which has to do the following:
    1. It should run without any interruption. (Therefore while [ 1 ])
    2. While working continuously, it should check whether a folder named "check" is available in the folder "/home/arch".
    3. If it is the case, it should execute the script /home/arch/shutdownServer1
    The bash script I am trying to execute is the following:
    #!/bin/bash
    while [ 1 ]
    do
    if [$(ls /home/arch | grep check)="check"]; then
            /home/arch/shutdownServer1
    fi
    done
    I tried to execute the code while the folder named "check" was available in the folder "/home/arch" But I got the following error.
    /home/arch/myscript: line 5: [check=check]: command not found => This implies that the expression "$(ls /home/arch | grep check)" was evaluated correctly because of check=check. But why does it say "command not found"? Since check=check it should be evaluated as true and execute the script shutdownServer1?
    P.S.: myscript is the name of the bash script file.
    Guys, please help me.
    Thanks in advance
    Last edited by Archie_Enthusiasm (2010-11-29 12:20:58)

    Try one of these
    if [ $(ls ~/ | grep check) ]; then
    ~/shutdownServer1
    fi
    or
    [ $(ls ~/ | grep check) ] && ~/shutdownServer1
    Edit: @Allan: thanks for '-d', I completely forgot that
    Last edited by igndenok (2010-11-29 11:59:16)

  • Can anyone please name this simple font for me?

    I want to use it for wmii window title.

    Thank you very much everyone.
    I think you are right Xyne, it's Dejavu Sans Mono.
    I couldn't make it work well with wmii though. I don't know how to enable anti-aliasing and to show Hebrew characters in the window title. I think I'll give up
    Thanks for bauerbill by the way. Using it!

  • Mods...please look at this thread for violation

    http://discussions.apple.com/thread.jspa?threadID=390789&tstart=0
    The poster is offering a link to computers they have for sale.
    littleshoulders [:-)

    Hi littleshoulders,
    It has been taken care of.
    Thanks for letting us know.
    Kady

  • Can some one have a look at this php script?

    Ok! hear's the script! It work's fine! but with one problem.
    when I get the email it look's like this>
    Base Color: NaturalTread Color: Black
    What I want the email to look like is>
    Base Color: Natural
    Tread Color: Black
    ie i don't want all the "var's" on on line!
    Hear's my php code>
    Can someone have a look to give me some poniters?

    I too am learnig. And just found this>
    <?php
    $sendTo = "******@hotmail.com";
    $subject = "Combo Test Two";
    $headers = "From: " . $_POST["name"];
    $headers .= "<" . $_POST["email"] . ">\r\n";
    $headers .= "Reply-To: " . $_POST["email"] . "\r\n";
    $headers .= "Return-Path: " . $_POST["email"];
    $message .= $_POST["baseColor"] . "\r\n";
    $message .= $_POST["treadColor"] . "\r\n";
    mail($sendTo, $subject, $message, $headers);
    ?>
    u need to put Line-Feed & Carridge Return:
    \r\n
    And good luck to you! Thanks for the help my friend!

  • Why doesn't this simple script script work

    I'm pretty new to actionscript, I learned it from books, actually I still am.
    The script I'll try to work out for my site, worked fine in the lessons of the books.
    I don't think my buttons are any different, but why don't they work then.
    Can anybody figure this out.
    my script :
    stop();
    whoweare.addEventListener(MouseEvent.MOUSE_UP, onNavigate);
    function onNavigate (evt:MouseEvent):Void {
        gotoAndPlay("contact");
    whatwedo.addEventListener(MouseEvent.MOUSE_UP, onNavigate);
    function onNavigate (evt:MouseEvent):Void {
        gotoAndPlay("slideshow");
    The error : The class or interface 'MouseEvent' could not be loaded.
    Help?
    Dirkhou,

    right answer, but it was already fixed,
    It seems the problem can hide anywhere, even in the little things.
    anyway.
    Thank you for the help.

  • Please look into this.. where i have to write at end of

    HI all ,
    i am getting this output in my report.
    the first column is the division (D.C) and the next couln is the no of consumer(no of business partner in a perticular dc (this is the count of dc))
    314200     0
    314201     1     
    334300     0
    i got the value of the first two digit of dc in a variable.
    now when it change from 31 to 33 i want to get the value of no of count .
    but the atatement AT END OF IS NOT WORKING ...
    Can anyone just look at the code and let me where i have to change..
    REPORT  ZDISTRICT_CUST_AUCSALES.
           LINE-COUNT 40(4).
    ******************************************************TABLE DECLARATION
    TABLES: /BIC/AUCSALES00,
            /BIC/TCOKEY.
    *******************************************************DATA DECLARATION
    DATA:  BEGIN OF ITAB OCCURS 0,
           /BIC/COKEY LIKE /BIC/TCOKEY-/BIC/COKEY,
           TXTSH      LIKE /BIC/TCOKEY-TXTSH,
           END OF ITAB.
    DATA:  BEGIN OF ITAB2 OCCURS 0,
           BILL_DATE   LIKE /BIC/AUCSALES00-BILL_DATE,
           /BIC/COKEY  LIKE /BIC/AUCSALES00-/BIC/COKEY,
           BPARTNER    LIKE /BIC/AUCSALES00-BPARTNER,
           END OF ITAB2.
    DATA:  COUNT TYPE I,
           COKEY TYPE I,
           COKEYNO(2) TYPE C,
           BILDT TYPE I.
    DATA: C TYPE I VALUE 2.
    *DATA: /BIC/COKEY TYPE /BIC/AUCSALES00-/BIC/COKEY.
    SELECT OPTION FOR DATE SELECTION IN THE SELECTION SCREEN.
    SELECTION-SCREEN BEGIN OF BLOCK DATE WITH FRAME TITLE TEXT-001.
         SELECT-OPTIONS: S_BILDT FOR /BIC/AUCSALES00-BILL_DATE OBLIGATORY default sy-datum.
    SELECTION-SCREEN END OF BLOCK DATE.
    *********************************************************INITIALIZATION
    *INITIALIZATION.
    FORMAT INTENSIFIED ON COLOR = C.
    write:/  'PROCESSING DATE:',    20 SY-DATUM,
         125 'TIME           :',   130 SY-UZEIT.
    WRITE:/  'USER NAME      :',    20 SY-UNAME, 138 ' '.
    WRITE SY-ULINE.
    WRITE: / 'D.C'                   , 12 SY-VLINE,
             'NAME OF D.C'        , 36 SY-VLINE,
             'BILL DATE'             , 53 SY-VLINE,
             'NUMBER OF CONSUMER' , 74 SY-VLINE,
             'REMARKS'            ,105 SY-VLINE.
    write sy-uline.
    *ULINE AT (100).
    FORMAT INTENSIFIED OFF.
    *END-OF-PAGE.
    WRITE:/40 'PAGE NO:', SY-PAGNO.
    *****************************************************AT SELECTION-SCREEN
    SELECT BILL_DATE
           UP TO 1 ROWS
           INTO (/BIC/AUCSALES00-BILL_DATE)
           FROM /BIC/AUCSALES00
           WHERE BILL_DATE IN S_BILDT.
    ENDSELECT.
    IF SY-SUBRC <> 0.
          WRITE:/ ' NO DATA FOUND ON THIS DATE'.
          EXIT.
    ENDIF.
    START OF SELECTION
    SELECT /BIC/COKEY TXTSH from /BIC/TCOKEY into table itab.
    IF NOT ITAB[] IS INITIAL.
    SELECT  BILL_DATE
             /BIC/COKEY
             BPARTNER
             FROM /BIC/AUCSALES00
             INTO CORRESPONDING FIELDS OF TABLE ITAB2
             FOR ALL ENTRIES IN ITAB
             WHERE /BIC/COKEY = ITAB-/BIC/COKEY
             AND BILL_DATE IN S_BILDT.
    SORT ITAB BY /BIC/COKEY.
    ENDIF.
    ***********************CHECK WHETHER THE DATA RETRIVE SUCESSFULLY OR NOT
    IF SY-SUBRC NE 0.
      WRITE:/ 'THIS DATE DOESNOT CONTAIN ANY DATA'.
    ENDIF.
    ************************************************************DATA DISPLAY
    LOOP AT ITAB.
    MOVE: ITAB-/BIC/COKEY+4(2) to COKEYNO.
    READ TABLE ITAB2 WITH KEY /BIC/COKEY = itab-/BIC/COKEY.
    IF SY-SUBRC = 0.
           SORT ITAB2 BY /BIC/COKEY.
           DELETE ADJACENT DUPLICATES FROM ITAB2 COMPARING /BIC/COKEY.
    ENDIF.
    IF ITAB2-/BIC/COKEY = ITAB-/BIC/COKEY.
           SELECT COUNT( DISTINCT BPARTNER )
                  INTO COUNT
                  FROM /BIC/AUCSALES00
                  WHERE /BIC/COKEY = ITAB2-/BIC/COKEY and
                  BILL_DATE IN S_BILDT.
          COKEY = ITAB2-/BIC/COKEY.
          WRITE:/ ITAB2-/BIC/COKEY,             SY-VLINE,
               15 ITAB-TXTSH,                   SY-VLINE,
               42 ITAB2-BILL_DATE,              SY-VLINE,
               55 COUNT,                    74  SY-VLINE,
                  ' ',                     105  SY-VLINE.
          WRITE:/ SY-ULINE.
      ELSE.
         COKEY = ITAB-/BIC/COKEY.
         WRITE:/ ITAB-/BIC/COKEY,                SY-VLINE,
              15 ITAB-TXTSH,                     SY-VLINE,
              51 '0' ,                           SY-VLINE,
              55 'Not Processed',              74 SY-VLINE,
                 'Data Not extracted to BW', 105 SY-VLINE.
          WRITE:/ SY-ULINE.
    ENDIF.
    CLEAR: ITAB, ITAB2.
    ENDLOOP.
    thanks in advance..

    Hi
    In this case instead of using AT END OF just create temp. which will hold in it last value of dc,every loop run, check it with new value, if it not equal - get the desired value
    only condition - itab must be sorted
    temp = 'x'. -->you need to put the first value
    loop at itab.
    if temp <> COKEYNO.
    --->your actions to get your value
    endif.
    temp = COKEYNO.
    endloop.
    OR
    you can add one more field to itab (better first) with COKEYNO
    fill itab in this field and then
    loop at itab.
    at end of cokeyno.
    endloop.
    Regards
    Yossi

Maybe you are looking for

  • Problem with videos after upgrading to iTunes 9.0?

    Something went wrong with my videos after I upgraded to iTunes 9.0! The videos are twice as long as they were originally. Let's say this video was actually 1 minute long. It is now 2 minutes long. For the first minute it plays normally, then for the

  • How to set background color in a scene?

    I'm new to JavaFX and just started my first FX program.  I created an FX project in NetBeans 7.3 and the project runs properly.   All of the samples in the JavaFX samples download run as well.  But when I try to do something as simple as setting the

  • Why is internet radio not showing up on itunes 11.1?

    okay, so at the top where it shows Song,Albums,Artists,Genres and playlists, there is not internet...i'm pretty sure there is supposed to be. I just updated to itunes 11.1.

  • New Tab on header level for me21n/me22n/me23n

    Hi Friends i have created a new tab on the me21n/me22n/me23n  header level using the exit MM06E005 , The tab is displayed but i am not unable to udate the records into the EKKO  Table whereas i have added my field in the include of  EKKO  CL_EKKODB K

  • 2.2 Upgrade and Battery

    Stayed with 2.1 for a while. Tired of problems and 2.1 was pretty stable. Last weekend restored and installed 2.2. Stable, works well. Some mild screen brightness issues. Battery life always pretty poor. Imagine my joy when I charged her up to max ov