You cannot request to applescript "If file exists" "else".

Hello everyone!

I've been Googling for hours for this. Could not find anything.

I thought it would have been quite simple: get applescript to do a check to see if a file exists, and do something. If it does not exist, do something else.

My script is as follows (more or less):

game file_yes (("~ /") & 'File.txt')

say application 'Finder '.

if there are file file_yes then

the shell script "SHELL SCRIPT" with administrator privileges

say application "Finder" for display alert "Shell Script complete!"

Try

the shell script "rm ~ / FILE.txt" with administrator privileges

end try

on the other

say application "Finder" display message "No file!"

end if

end say

You must use a Mac OS X-style path when it comes to the Finder:

If there is the file "File.txt" of the House then

(137423)

Tags: iOS Developer

Similar Questions

  • "You cannot request the signature...". »

    All of a sudden, when you use the signing tool to request a signature, I had 'unable signatures to demand up to that this request has been saved with all the powers of signature required'. I have been using the app for a long time signature tool.

    any idea on how to solve this problem?

    Thank you

    You must place all the files *.csi and sigtool.* (signing keys files) in the folder with SignatureTool.jar (JDE/bin).

    Without these files, it will not work and will display this message for each cod file that you are trying to sign.

    Seems that you have installed additional JDE and the JDE/bin does not contain these files.

    Copy these files to each JDE/bin folder on your computer.

    This will help you.

  • You cannot request signatures of COD

    I formatted my pc and reinstalled JDE. I have RBB, CPR, RRT RIM files. When I try to ask the signature, I get the following popup error message:

    Impossible signatures request until that this request has been saved with all the powers of signature required

    Someone guide me on how to do. Unfortunately, I forgot my PIN, but I can remember the password.

    Contact RIM. [email protected]

  • FAL [client]: you cannot request the gap sequence

    OTN community,

    Database: Oracle 10 g 2 group patch 3
    Operating system: HP - UX v.11.31

    I have a problem with the gap on the physical database archivelog ensures. You can very well below outputs;
    SQL> select * from v$dataguard_status;
    
    FACILITY                 SEVERITY         DEST_ID MESSAGE_NUM ERROR_CODE CAL TIMESTAMP           MESSAGE
    ------------------------ ------------- ---------- ----------- ---------- --- ------------------- ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    Log Transport Services   Informational          0           1          0 NO  18/07/2010 02:56:28 ARC0: Archival started
    Log Transport Services   Informational          0           2          0 NO  18/07/2010 02:56:28 ARC1: Archival started
    Log Transport Services   Informational          0           3          0 NO  18/07/2010 02:56:28 ARC0: Becoming the 'no FAL' ARCH
    Log Transport Services   Informational          0           4          0 NO  18/07/2010 02:56:28 ARC0: Becoming the 'no SRL' ARCH
    Log Transport Services   Informational          0           5          0 NO  18/07/2010 02:56:28 ARC1: Becoming the heartbeat ARCH
    Log Apply Services       Control                0           6          0 YES 18/07/2010 02:57:15 Attempt to start background Managed Standby Recovery process
    Log Apply Services       Control                0           7          0 YES 18/07/2010 02:57:15 MRP0: Background Managed Standby Recovery process started
    Log Apply Services       Informational          0           8          0 NO  18/07/2010 02:57:20 Managed Standby Recovery not using Real Time Apply
    Log Apply Services       Informational          0           9          0 NO  18/07/2010 02:57:21 Clearing online redo logfile 1 /usr/ORACLE/u02/KNWA_redolog/redo01a.log
    Log Apply Services       Informational          0          10          0 NO  18/07/2010 02:57:21 Clearing online redo logfile 1 complete
    Log Apply Services       Warning                0          11          0 NO  18/07/2010 02:57:21 Media Recovery Waiting for thread 1 sequence 354977
    Log Apply Services       Informational          0          12          0 NO  18/07/2010 02:57:21 Fetching gap sequence in thread 1, gap sequence 354977-354985
    Log Transport Services   Warning                0          13          0 NO  18/07/2010 02:57:52 FAL[client]: Failed to request gap sequence
    Fetch Archive Log        Informational          0          14          0 NO  18/07/2010 02:57:52  GAP - thread 1 sequence 354977-354985
    Fetch Archive Log        Informational          0          15          0 NO  18/07/2010 02:57:52  DBID 1228244844 branch 688497708
    Log Transport Services   Informational          0          16          0 NO  18/07/2010 02:57:52 FAL[client]: All defined FAL servers have been attempted.
    
    16 rows selected.
    
    SQL> archive log list;
    Database log mode              Archive Mode
    Automatic archival             Enabled
    Archive destination            /usr/ORACLE/archive/KNWASTBY/
    Oldest online log sequence     354990
    Next log sequence to archive   0
    Current log sequence           354992
    More old newspaper online sequence is 354900, but he tries to retrieve the sequence 354977-354985. I don't want the database to extract the old archivelogs since the YVERT database and controlfile is up-to-date. I really don't understand why he keeps trying to get the old archivelogs in the primary. I already deleted the archivelogs and I applied the last backup on the standby site.

    How can I omit these old archivelogs and leave the unapplied archivelogs applied to the standby database.
    SQL> select sequence#,applied from v$archived_log;
    
     SEQUENCE# APP
    ---------- ---
        354987 NO
        354990 NO
        354989 NO
        354986 NO
        354991 NO
    Log shipping is correct and the standby can trace switches archivelog perfectly.

    Thank you in advance.

    Ogan

    Published by: Ogan Ozdogan on 18.Tem.2010 03:07

    Another question, how can I change the standby controlfile controlfile to understand the database didn't need than archivelogs more?

    Ogan

    Thanks ogan.

  • Cannot find the corrupt configuration file to be recovered.

    I had a similar problem to many people, with my computer telling me that the windows\system32\config\system file is corrupted missing. But after trying the steps on the support page, I got no further than the first step that the files that I need to copy could not be found. I tried to jump to their compensation, but, yet again, as they cannot be found, they cannot be repaired! Don't know what else to try as no command doesn't seem to work with anything whatever in the config folder. Then, try the system restore, but don't even know if it's likely to work?

    Any help would be greatly appreciated!

    The problem is usually a corrupted file system and not a damaged or missing file.  The message means that XP tries to start, but just can't find or get the file.  A chkdsk /r usually clears it right up, but when the mistake of Googling, KB307545 is the first results, so unfortunately, it's where people start sometimes.  KB307545 is a corrupted registry or a file system afflicted.  If the file system is corrupted, you will get frustrated quickly with KB307545.

    KB307545 doesn't really work if you follow the directions exactly and you do not have a problem of file system, but I've never, never, never used to solve the problem you describe because it is usually never really necessary.  Recording file corruption does not usually go to the origin of the error.

    If you want to use KB307545, which is something you would do to get your whole system running long enough to make a 'real' system restore, but only after running a chkdsk/r from the Recovery Console.  There is no such thing as a "restoration of the manual system.  There is a "get my system functional enough to do a regular system restore".  KB307545 and a regular system restore are not interchangeable.  It could also be that your system restore is just totally whacked on too much by train.

    What happens when you try to start your system in Mode safe?  What is the last thing you see on the screen?

    What does ' not loading everything '?

    If you use the Recovery Console to implement the KB307545 and have already tried, name changes will not work until you remove the files target of your previous efforts.

    If you want to rename fileA to fileB, you must first remove the current file (if it exists).  Change of name is not identical to the copy so if the target file already exists, you cannot rename just another file on top of it.  You will get an error message.  You will need to delete the old file first, and then rename.  That is why your worked the first time but not the second time - the file you are trying to rename already exists.  You cannot rename on top of an existing file.

    Do, or do not. There is no test.

    I need YOUR voice and the points for helpful answers and propose responses. I'm saving for a pony!

  • Cannot connect to the local file and print when the domain controller is not available because the network connection

    Hi all
    Having problems for local users, connection to a file and print server in one of my satellite offices.
    When my t1 connection is disrupted (problem of local carrier) my users when the connection is down to connect to the file room and print and always have access to their files and the local printer.
    The domain controller is off site in my main office.
    Environment:
    All local desktop clients are windows machines 7.
    Printing and local file is a windows 2003 server.
    DC is window 2008
    Note that we recently changed all 2003 to all domain controllers the PDC 2008, suspect that it may cause the problem, but just cannot know where it track.
    Any help or thoughts would be appreciated.
    Thank you

    Hello trj'hwma,

    Thank you for the question!

    It's discouraging to know that have problems you with the local file and print. As I understand well you cannot connect to the local file and print when the domain controller is not available because the network connection.

    The question you posted would be better suited in the TechNet Forums. I would recommend posting your query in the TechNet Forums. You can follow the link to your question:

    Windows 7 IT Pro category

    Answer to us if you have problems with the local files and print or any other issue of Windows, and I'd be happy to help you again and try to correct the problem as soon as possible.

    Good day!

    Hope this information helps.

  • 0X803C0107 error: you cannot access shared files and printers and the MSE does not start at startup

    Original title: mainly MSE does not start at startup. have you tried re-loading and other elements on the card, still no luck. Here is the error code I have and the information complete.

    Remember - this is a public forum so never post private information such as numbers of mail or telephone!

    Ideas:

    • Error 0X803C0107

      Details of the editor for Windows Firewall troubleshooting

      Verified issues

      You cannot access shared files and PrintersYou cannot access shared files and printers

      You can't access shared folders or printers on a computer on which Windows Firewall is enabled. This happens when the Windows Firewall blocks traffic entering via the UDP ports 137 and 138 and the ports TCP 139 and 445. Checked

      No workingRemote Assistance remote assistance does not

      When you use Windows Help and Support, remote support available to offer assistance to a computer, you receive the error message "the remote server computer does not exist or is unavailable", even if Remote Assistance and file sharing and printing are activated. Windows Firewall may be blocking Remote Assistance. Checked

      Windows Vista may not start Windows Vista FirewallWindows could not start the Windows Firewall

      On a computer that is running Windows Vista, you find that the Windows Firewall service is not running. When you try to manually start the service, you get "Windows didn't start the Windows Firewall on the Local computer." For more information, see the system event log. If it is a non-Microsoft service, contact the service vendor and refer to service particular 5 error code. "error message. This can occur if the 'MpsSvc' account does not have the necessary permissions for the registry keys concerned. Checked

      Windows Firewall service is not his firewall service is not started

      Windows Firewall service is not running or is not started. Checked

      Issues checked the details of the detection

      6 you cannot access shared files and printers checked

      You can't access shared folders or printers on a computer on which Windows Firewall is enabled. This happens when the Windows Firewall blocks traffic entering via the UDP ports 137 and 138 and the ports TCP 139 and 445.

      Unlock the file and printer sharing in Windows Firewall works not

      To allow access to shared folders and printers, except for the file sharing and printers in the Windows Firewall must be enabled.

      6 remote assistance works not verified

      When you use Windows Help and Support, remote support available to offer assistance to a computer, you receive the error message "the remote server computer does not exist or is unavailable", even if Remote Assistance and file sharing and printing are activated. Windows Firewall may be blocking Remote Assistance.

      Allow Remote Assistance in Windows not running Firewall

      Which allows Assistance remotely as an exception in Windows Firewall it unlocks and corrects this problem.

      6 Windows Vista could not start Windows Firewall check

      On a computer that is running Windows Vista, you find that the Windows Firewall service is not running. When you try to manually start the service, you get "Windows didn't start the Windows Firewall on the Local computer." For more information, see the system event log. If it is a non-Microsoft service, contact the service vendor and refer to service particular 5 error code. "error message. This can occur if the 'MpsSvc' account does not have the necessary permissions for the registry keys concerned.

      Set permissions for the registry keys concerned not run

      Setting permissions for the registry keys concerned will solve this problem. Applies only to computers by using Group Policy to manage the firewall.

    6 Windows Firewall service did not start Checked

    Windows Firewall service is not running or is not started.

    Start the Windows Firewall service is not running

    Start the Windows Firewall service solves this problem.

    Details of detection

    Collection information

    Computer name: NORMBRESINSKI

    Windows Version: 5.1

    Architecture: x 86

    Time: 09-20-2010 07:51:49

    Publisher details

    Troubleshooting Windows Firewall

    Automatically fix problems of Windows Firewall, such as Windows cannot start the firewall service (0x5) Windows or Windows remote assistance does not work

    Package Version: 1.0

    Publisher: Microsoft Corporation

    You have problems with programs

  • Error messages
  • Recent changes to your computer
  • What you have already tried to solve the problem
  • Hi Rickbsk,

    You can check out the link and check the suggestions provided by scotty1294.

    http://social.answers.Microsoft.com/forums/en-us/msestart/thread/05a63b12-1be9-4BD3-898e-64674c1e9afd

    If you have not tried all the suggestions above, try and see if it helps.

    Hope this information is useful.

    Jeremy K
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

    If this post can help solve your problem, please click the 'Mark as answer' or 'Useful' at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • Send to trash, auto deletes files: Message "this item will be immediately removed. You cannot undo this action. »

    I know that there is a button somewhere that allows me to send files to the trash when I click right

    But currently the button 'Send to trash' generates this message "this item will be immediately removed. You cannot undo this action. »

    Can someone guide me to the control button that will allow me to have the standard configuration of "send in the trash."

    Thank you!

    LMB

    Highlight

    CMD + delete

  • try to install Picture IT Publishing Platinum & get error 1305 D:\PIP\PIP2002\openscn6.its...verify file exists and you can access it... help

    It wont let me install Picture It! Publushing Platinum... error message 1305:
    Error reading file D:\PIP\PIP2002\openscn6.its... check the file exists and you can open it... help... what I do

    Hello
    1 did you change on your computer before this problem?
    2. in the place where you are trying to install?
    3. is this a problem install only Platinum edition or with all applications?

    You can follow the steps in the article and see if it helps.
    Problems installing and uninstalling programs on Windows computers
    http://support.Microsoft.com/kb/2438651
  • Error "Windows cannot access the specified device, file, or path. You can not have appropriate permission to access the item.

    Hello

    I have already read many answer to this problem here, but unfortunately none of this applies to me. I have a Windows XP and for some time I've always started some message when starting my laptop on rundll32.exe on my desk. I checked and I have this file in my system folder. Since this morning, I became suddenly unable to use any application like Skype, messenger other messengers etc. I can't even run my AVG scan for viruses and not can't open most of the programs in the control panel including Security tab / does anyone have an idea how can I get rid of this virus, or at least turn back my applications, I can use?

    Hi Platamon1980,
     
    -Remember to make changes to your computer after that this problem started to happen?
     
    First, try the steps listed in the following article to fix rundll error message:
     
    This problem occurs because of a missing or corrupted Rundll32.exe file.
     
     
    Check if this solves other problems also.
     
    Keep me updated on the status of the issue.
  • RootKit/Malware/Virus problem - windows cannot access the specified device file or the path, you don't have permissions

    Hello

    I have a problem with my computer it has been infected by a virus that is not visible in normal mode. It prevents running any application that would help in the detection and removal. I tried running mrt, mcaffe, trendmicro rootkit detector rootkit detector, spybotSD, analysis windows Defender online Windows live onecar. All these works for a minute and then shutsdown, when I click it again I get the error, as mentioned in the title, 'windows cannot access the specified device file or the path, you do not have permissions.

    This problem has a solution or re - install is the only way out?

    The pointers/help appreciated.

    Just to add, I am able to connect using my last known good configuration and only safe mode configurations.

    Thank you

    Id2View,

    1. follow all the instructions in this thread: How to get rid of malware

    2. If still no joy you can find Microsoft MVPs and other trained analysts on the following support sites:
    Aumha.org
    Atribune.org
    SpywareHammer
    BleepingComputer
    Safer-Networking

    3. If you need help with virus-related issues, contact the Support Services Microsoft product.

    To support the Canada and the United States, call toll-free (866) PCSAFETY (727-2338).

    For support outside the United States and the Canada, visit the page Web of Product Support Services.

    4. If you need more assistance for the position of the newsgroup Microsoft - security - virusvirus/worm.
    Through your News Reader:
    News://msnews.Microsoft.com/Microsoft.public.Security.virus
    Via the Web:
    http://www.Microsoft.com/communities/newsgroups/list/en-us/default.aspx?DG=Microsoft.public.Security.virus

    Hope this helps,

    Vincenzo Di Russo - Microsoft MVP Windows Internet Explorer, Windows Desktop Experience & security - since 2003. ~ ~ ~ My MVP profile: https://mvp.support.microsoft.com/profile/Vincenzo

  • I get "file exists" when you try to open a session to Quickbooks pays.

    Original title: Windows error message

    When you try to log in to Quickbooks don't pay I get an error message

    "the file exists." The error message is still displayed. I have to go into the Task Manager to stop the program.

    Hello

    You can follow the article below in order to solve the problem.

    http://support.QuickBooks.Intuit.com/support/pages/knowledgebasearticle/1011639

    Aziz Nadeem - Microsoft Support

    [If this post was helpful, please click the button "Vote as helpful" (green triangle). If it can help solve your problem, click on the button 'Propose as answer' or 'mark as answer '. [By proposing / marking a post as answer or useful you help others find the answer more quickly.]

  • Cannot open the program after you restore the backup of the files.

    original title: problems of recovery program

    I had to do a system recovery. When the files have been restored from the backup made on to the DVD-they do not repopulate the original sites, that is to say the restoration has created a section of program in the C drive, but it had only the value default ones that came with the computer since the store - as it was supposed to, given was a cover. However, all of the programs I've added over the years are stuck in the restore file called "Program Files" as most have been downloaded since the ' net, I have no disks. not only that most is time sensitive and have many improvements. How can the Backed files program, now residing in 'My Documents', developed by the backup process located in the C drive program area? When I try to open the program in the restore file, the content and details are listed, but the program does not work. Thanks for any information.

    Hey Dave to Campbell River.

    I'm a bit confused between your question and the answer. Have you already restored your system or if you are trying to implement and obtain information?
    In response to the original question, you can back up your entire hard drive, back up is called a System Image, it will be, as it is said, back up your system.
    A system backup / full copying data files, but not everything on the drive. You cannot use it to restore the entire system.
    I hope that sheds some light on it for you. And fear what (I'm trying to follow the number two of the answer now) you created a backup system, and are now trying to re access to your program files, I'm afraid, you're out of luck. I had to learn the hard way, too, so I hope you are getting information and are not in this situation.
    Hope this has been useful, if you have any other questions, feel free to keep coming them.
    Thanks for posting of answers!
  • the contents of this file cannot be decompressed the executable file that you are attemptiong to run

    The contents of this file cannot be decompressed the executable file you are trying to run has been corrupted you can get another copy of the file check its integrity and try again.

    You have not told us what you're doing or what program you are trying to use...

  • Problem with Windows Search 'Windows cannot access the specified device, file, or path. May not be the appropriate permissions for access you to computing.

    I have a very annoying problem:


    OT: Problem with Windows Search
    When I try to use Windows Search in the menu start I get the message "Windows cannot access the specified device, file, or path. May not permissions to access you the item. I get this message no matter what I type in. Therefore, I can't find something on my computer and continually to achieve this result.
    Could someone please help me solve this problem?
    I tried what answers I could find other peoples messages online, nothing helps. I'd appreciate any help.
    Thank you very much.

    Hello

    You did changes to the computer before the show?

    I suggest you try the steps from the following link:

    Error "Windows cannot access the specified device, path or file" when you try to install, update or launch a program or file
    http://support.Microsoft.com/kb/2669244

Maybe you are looking for