Automator for changing system settings?

Here's my issue: I have an external monitor connected to my 2010 Macbook Pro with OSX Snow Leopard. I do all my work when I'm at home on the larger monitor and use the other screen for iTunes. I use spaces alot, and so when using my external monitor, I put iTunes to open on all spaces so that it's always handy. When I go out with my laptop, I have to change the spaces settings back to iTunes only being open in one space.
It's not a big issue, but does anyone know how to use automator (or by any other means) to automatically change the system settings so that my computer can, on detecting I have an external monitor plugged in, change the spaces settings for iTunes? (and preferably back again when it doesn't have the external monitor plugged in).

Hi there :)
You can connect directly to the DB without a DSN like this:
url = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ=<YOUR DB LOCATION HERE>;
try
Class.forName ("sun.jdbc.odbc.JdbcOdbcDriver");
icuCon = DriverManager.getConnection (url);
catch (Exception e)
You will obviously replace <YOUR DB LOCATION HERE> with the location of your database for example you can set the url of the database like this:
url = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ=" +
System.getProperty ("user.dir") + System.getProperty ("file.separator") +
"DBFolder" + System.getProperty ("file.separator") + "DB.mdb";
Matt

Similar Messages

  • FM for changing system status in Service Notification

    Hi all,
    I have a tough situation here.
    To change the system status in service notification, the system use "IQS4_CHANGE_STAT_NOTIFICATION".
    CALL FUNCTION 'IQS4_CHANGE_STAT_NOTIFICATION'
      EXPORTING
        i_qmnum                  =
        i_vrgng                  =
        I_CHECK_ONLY             = ' '
        I_SPRAS                  = SY-LANGU
        I_BEZDT                  = SY-DATUM
        I_BEZUR                  = SY-UZEIT
        I_POST                   = 'X'
        I_COMMIT                 = ' '
        I_WAIT                   = ' '
        I_REFRESH_COMPLETE       = 'X'
      IMPORTING
        E_VIQMEL                 =
        E_STTXT                  =
        E_ASTXT                  =
      TABLES
        RETURN                   =
    2 main fields are required; i_qmnum and i_vrgng.
    I am able to provide i_qmnum (as this is the service notification number that i need to change).
    However, i_vrgng is a field in table (TC33-VRGNG). The values in the table does not make sense to me.
    Example. To change the status to NOPR (Put in progress), the FM uses PPM2 or PPM6 for i_vrgng. If we take a look at the table TC33, it doesn't indicate in anyway how NOPR is related to PMM2 or PMM6.
    Is there a guideline (ie, to change status to OSTS, i use a certain value in TC33-VRGNG to run the FM)?
    Please see BAPI_SERVNOT_POSTPONE & BAPI_SERVNOT_PUTINPROGRESS for a clearer picture of what I'm saying.
    Thanks,
    Earl

    Please try using FM STATUS_CHANGE_INTERN for changing System Status as i was not able to find any link between status and the field provided in FM in ur post.
    This FM directly changes system status of any object.But this FM requires System Status Value not Text.
    NOPR, NOCO etc are system texts.The main table for system status  is TJ02T which will give u the status value for the status text.
    For eg NOPR status text will have status value as 'I0070'.
    Reward Points if useful
    Edited by: Pratyasha Shishodia on Mar 14, 2008 11:07 AM

  • How do I change system settings so that users are not required to enter the mac's admin pw in order to join a wifi network?

    how do I change system settings so that users are not required to enter the mac's admin pw in order to join a wifi network?
    Right now my macbook pro requires an admin password before connecting to a new wifi network. In other words when a user that is not an admin tries to connect to a new wifi network the pop up displays indicating that it is locked and an admin password is required.
    Is there a way to remove this restriction so that a non admin can connect to wifi without the mac's admin password.

    You can enable / disable this option in System Preferences:
    System Preferences > Network > Wi-Fi > Advanced > Wi-Fi tab > Require administrator authorization to: Change networks

  • Using automator to change system preferences

    can i use automator to change my network settings. my stupid wireless at home does not automatically connect so everytime i get home i have to open up sys preferences and change the airport settings to manual and enter in the ip address of the router manually. can i create an automator script to do this in one step?
    any help appreciated. thanks.

    I have a similar problem with the ultra sensitive trackpad with the "Clicking, Dragging, Drag lock" checked in Preferences/Keyboard & Mouse. I'm always turning them on and off depending on which application I am using.
    My problem is that when I record a series of actions in Automator, the resulting action list has no text behind the action for the mouse click for the Clicking checkbox. Its as though it doesn't even know that its there. All of the other actions show up.
    Got any ideas on how to fill that void or another workflow that would do the same thing ? I think that running the workflow again would turn it back on as the actions are identical.

  • OS changes System settings and other stuff

    Hej,
    I have this very strange thing going on atm w/ my MacBook (ICD1), as all my remembered usernames and passwords in Safari are gone, iTunes is strange (keeps on telling me that my library is damaged, Artwork missing, other things show up twice w/ different sets of files [two Podcasts Folders for example, in one are 20 and in the other one are 35 - the original 20 plus 15 others I downloaded later]), OS changes desktop and and other System settings, Skype passwords are missing, iTerm went back to original configuration, etc. Its all very annoying, and I have no idea what could be the cause for this. I spend the better part of today reading support and the forums but found no similar case, maybe someone can help me, please?

    First, I'd make sure the disk verified okay with the install utility.
    Then I'd check the disk permissions, with the install utility.

  • Any printer UI for change printer settings?

    Since Solaris 10's printing system is powered by PPD files. (at least for some printers). I suppose I can access all features PPD file provide: Change page size, input-tray, output-tray, color-mode, etc.
    Is there a GUI that comes with Solaris that can help me change printer settings? (The printer manager is useless)
    How do I tell what command line option a PPD file provides? (Yes, I can write my own script to parse the PPD file for OpenUI, CloseUI), but what's Sun's solution for it?

    /usr/sadm/admin/bin/printmgr &
    Don't ask me why it's in a weird location.
    It's the Best GUI In The World -
    gives you the option of a console
    window, so you can see what it's
    doing on the command-line in
    response to your button-clicks.
    Dunno about the PPDs.
    cheers.

  • GPO for changing privacy settings for Internet Zone

    Hi I want to change the privacy setting for the Internet Zone from Medium to Low. Can't seem to find the right location in the GP. Can someone please point me in the right direction.

    Hi,
    If we want to change the privacy setting for the Internet Zone from Medium to Low via Group Policy, please navigate to
    User Configuration - Windows Settings - Internet Explorer Maintenance – Security
    in GPMC. On the right-pane, please double-click Security Zones and Content Ratings. On the dialog box, we should choose "Import the current security zones and privacy settings" under
    Security Zones ad Privacy and click Modify Settings
    to modify the level.
    The article Ravikumar provided is very useful to us for configuring the settings via Group Policy, please also refer to it.
    Regards,
    Andy
    Using IE maintenance is the old way which I don´t recommend when implementing IE9 or newer. I wonder, why there is no way to configure this with traditional GPO? 

  • SG 200-08 does not permit changing System Settings screen

    I am unable to change the settings on this screen:
    Administration => System Settings
    The GUI objects to any of the combination of characters I've entered into 'Hostname', including the provided default.
    --sk

    Verified this under both 1.0.5.1 and 1.0.6.2

  • ICloud keeps changing system settings

    Hi all,
    Sing moving to Mavericks, I have noticed that there are miscellaneous settings being reset by iCloud. For example, if "Documents and Data" is checked, I get all my text shortcuts i use on my iPhone on my Mac. hOwever, it cheeks changing the Finder's view settings, so that it orders things by date instead of name, and it keeps bringing back iTunes Helper and dropbox, no matter how many times I delete them from my login items.
    At least, I am assuming that it is iCloud doing this. It is similar to starting to write a note or an iCal entry, and then the update to iCloud erases the note that I had open.
    I really don't want to go through and work out all my shortcuts. Not because I'm lazy, but because this should just work. However, the frustration of navigating the Finder when all the columns reorder themselves as I am browsing is a headache.
    So my question is this: What OSX settings are stored by iCloud? I want to know the list of unmentioned settings that are synced, so I can note the settings as they are, remove iCloud sync for Documents and Data, and then reset all my settings.
    I should mention I don't have any documents that upload to iCloud under Documents and Data.
    Thanks for your time and help!
    Regards, Kieran

    Hi Diane, thanks for your reply!
    I am interested in turning it off, but I would like to know what settings are synced first. There are quite a few bizarre problems in Mavericks, and as my professional bread and butter software takes almost a year to update to Apple's notorious fast paced update cycle, I will be stuck with Mavericks for a while, so I am keep to find out (and understand) rather than disable the parts of the software that don't make sense.
    Concerning the view settings, it might simply be that the way they operate in Mavericks is different from Mountain Lion, because of the tags. The problem is that I set (for example) the Application folder to arrange by name and sort by kind, while every other folder is set to arrange by kind and sort by tags (I use column view by the way). I have found that the application folder won't stay arranged by kind, it changed to tags too. But further, even when in tags, things are subsorted by name. While browsing in column view it automatically changes to date modified, and if I open another window and then go back, it remembers what it is supposed to do. It seems to be that rather than remember the settings per folder, either it reorders the folder when opened, or it gets permission to view from somewhere that updates the preference, which is why I assume iCloud has its hand in it. It has the same feel as when iCloud updates a note I am working on, or a contact and wipes the changes I have made.
    When I first set up my account and linked it to my Apple ID, Documents and Data was turned on. The Keyboards>Text system preferences miraculously recalled all my shortcuts/text replacements. I turned off Documents and Data in iCloud and these disappeared. When I logged out and logged back in, Documents and Data had switched itself back on. I left it, and now I want to know all the preferences it has its sticky fingers in. I don't wish to guess or discover why something isn't working the way I expect, based on my experience with Mountain Lion. It is hard to find an explicit list of the details, and it seems to be strange that operating systems need to be dealt with by trial and error, rather than reading the relevant document.

  • Using Automator to change System Preference when opening an app

    Hello everyone,
    I have been using a Mac for a good 8 years now and I'm a happy user. I recently found out about Automator ('hey what is this little robot for?') and what it can do, yet I lack the knowledge of finding out what I must do to make a script to perform the following thing:
    When I launch an app (FL Studio), I want the box checked next to 'Use F1 and F2 as standard function keys' in the Keyboard preferences pane in the System Preferences app.
    When I close the same app (FL Studio), I want the box unchecked next to 'Use F1 and F2 as standard function keys' in the Keyboard preference pane in the System Preferences app.
    I have found several other topics about this subject, however, those were about scripts when logging in to your computer, and not upon opening/closing an app. Please note that I am seeking for the setting to be changed when the app is opened and closed.
    I hope you can help,
    Sander

    This kind of question comes up a lot - how to run a script when an application launches/quits.
    The short answer is that it's not easy to do directly, unless the application itself supports launching scripts on startup/quit (hint: few do).
    Fortunately, a little difference in thinking can give you the same effect.
    Rather than trying to have your script trigger AFTER the app launches, rethink your process to a script that FIRST changes the preference, THEN launches the app. You get the same result but about 14 billion times easier to implement.
    In this case, write a script to set the function key preference, then launch FL Studio. The script can then hang around to wait for the app to quit and reset the pref.
    Furthermore, don't try to do this the human way (open System preferences, select Keyboard, check the box). You can set the preference directly via the defaults command line utility:
    on run
      do shell script "defaults write .GlobalPreferences com.apple.keyboard.fnState 1"
      tell application "FL Studio" to activate
    end run
    Resetting the preference is a little trickier since you need to detect when FL Studio has quit. You can do this with an idle() handler in your script that hangs around, periodically checking if the app is still running and then taking action:
    on idle
      tell application "System Events"
      if (name of every application process) contains "FL Studio" then
      -- app is still running, so come back and check later:
      return 10
      else
      do shell script "defaults write .GlobalPreferences com.apple.keyboard.fnState 0"
      tell me to quit
      end if
      end tell
    end idle
    Putting these together in a Stay Open script should do much of what you want.

  • Use Automator to Change System Preferences?

    Hi. I want to create a workflow or applescript that will open my system's sound preferences and change the output source. The Applescript editor doesn't record any of my actions.

    Modify the setting from System Preferences, and then look for plist files in ~/Library/Preferences/ and /Library/Preferences/ modified around that time. When you've located a possible plist, open the Terminal application in the /Applications/Utilities/ folder and enter 'defaults read ' without the quote marks. Drag the plist into the Terminal and press Enter; you will then see a list of keys. If a key looks like it contains what you're looking for, remember its value, change the setting again from System Preferences, and check the key again. Once you've found the key, you can use a 'defaults write' action in Automator's shell script option to change the value. If you can't write the key successfully, post back here with the name of the key and where you found it for further assistance.
    (12421)

  • I am logged in as Admin user, but cannot unlock and change system settings-why?

    I am the admin user on my iMac with OS-X 10.7.5. When I open up system preference and try to change anything, the lock on the bottom won't unlock. What gives?

    Bizzare... it fixed itself. Same password.
    I noticed that the time was off by about 20 mins and wanted to adjust, but couldn't unlock the system preferences. The time & date preferences suggested turning on the wi-fi (I normally use a cable to connect to the internet) and when I did the date & time synched itself.
    After that, I was messing around under the desk and accidentally switched off the power strip. When I rebooted, I went into the preferences, and low & behold, the lock was unlocked. I can lock & unlock it (with prompt for admin password) normally.
    Strange.
    Everything is working the way its supposed to, but I am going to get replacement disks from AppleCare anyway just in case.
    Thanks for the advice.

  • Automating installations -- changing network settings from AppleScript

    How can I change a computer's DHCP client ID's and name from AppleScript (or a shell script)? This is to automate Mac OS X deployments.

    This has been successfully resolved by electing to 'forget' both devices (the new AirPort Express unit and existing Time Capsule), doing a factory reset of both, and then re-scanning to add devices through AirPort Utility.

  • Admin and user rights for change active airport

    Hello alltogether,
    my son has a new MacBook (System 10.5) for his school and he learn with the computer in all school-subjects. So I create two users, admin and one for him. After he has install all applications that he need for school, I gave the admin a password. Now my son can't install applications or change system settings. But i must give him admin rights, because when he stay at school, he must change the airport environment for school and if he stay at home he must change it back to home. Is it not possible to set the rights for a not admin user so, that he can change the airport environment?
    Thanks for reading.
    Regards,
    Tommy

    If he needs admin status to use the wireless connection, then you need to make him an admin user. As far as I know, there is no partial admin configuration.

  • Where to "Edit Your System Settings"?

    The update tab of the portal page says:
    Updates
    From this page you can view all of the different types of updates available for your systems by ID, name, type, how many systems would be affected and by the date the update was released. If you want to view the current baseline, go to "Edit Your System Settings."
    But I don't see an "Edit Your System Settings." option. What am I missing?
    Cheers,
    Rich Whiffen

    Hi Rich,
    Thank you for pointing out this issue and posting the location (and path allowing) for Editting System Settings. A Change Request was filed and completed to resolve the issue of wording on the Updates Page.
    Thank You,
    William Brower

Maybe you are looking for