Renaming Application in Applescript Studio

To those who know the answer, this probably seems simple, but for the life of me I cannot figure this out.
I wrote an application using XCode and Applescript Studio. When I started, I named the project "cm" because it was simple and short. Now the application is getting substantial and I regret the name. I always have to rename it manually after the compile. Where can I change the name generated by the compiler to the longer name I now wish I have invoked when I started? (Obviously without breaking anything.)

Hi Boberino
Some suggestions from to threads below
http://meandmarkpublishing.blogspot.com/2007/09/changing-application-name-for-xc ode.html
http://homepage.mac.com/kelleherk/iblog/C1216817469/E1454445171/index.html
Budgie

Similar Messages

  • Building a stand-alone AppleScript Studio application

    I’m taking a crack at building my first stand-alone application with AppleScript Studio. After many attempts to locate the needed “build” information in the various documentation resources I’m still pretty much poking around in the dark ...
    My application runs fine in the Xcode IDE. No problems. The application that Xcode saves in the project’s Debug folder runs too, (well, on the computer I developed it on) even if I move it out of its folder ...
    However, the app. doesn’t run on other macs. When double-clicked and it sorta fizzles without ever opening — wondering if the debug version relies on some resources within the project. I've installed it on a PowerBook and iBook, both running Mac OS 10.4
    I tried Build/Release. This also produced an application (in the Build/Release folder) which when failing to launch and causes the OS to burp, “You cannot open the application “My First App” because it may be damaged or incomplete.” This app will not run on my development computer or other laptops (PowerBook and iBook.)
    Build/Release also invoked three Xcode compiler error messages that seem to indicate that I need to change the NIB settings:
    /usr/bin/ld: warning /Developer/SDKs/MacOSX10.3.9.sdk/System/Library/Frameworks/Cocoa.framework/Coco a cputype (18, architecture ppc) does not match cputype (7) for specified -arch flag: i386 (file not loaded)
    /usr/bin/ld: warning /Developer/SDKs/MacOSX10.3.9.sdk/System/Library/Frameworks/AppleScriptKit.frame work/AppleScriptKit cputype (18, architecture ppc) does not match cputype (7) for specified -arch flag: i386 (file not loaded)
    /usr/bin/ld: warning fat file: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libSystem.dylib does not contain an architecture that matches the specified -arch flag: i386 (file ignored)
    Also got this warning(?):
    /usr/bin/ld: Undefined symbols:
    __keymgr_dwarf2_registersections
    _cthread_initroutine
    _atexit
    _errno
    _exit
    mach_initroutine
    _ASKInitialize
    _NSApplicationMain
    collect2: ld returned 1 exit status
    Also tried Clean All. Same result.
    I'm sure there's a simple step ... which I will remember well, 'cause I'm learning it the hard way.
    John

    However, the app. doesn’t run on other macs. When
    double-clicked and it sorta fizzles without ever
    opening — wondering if the debug version relies on
    some resources within the project. I've installed it
    on a PowerBook and iBook, both running Mac OS 10.4
    You're right. You can't move a debug version of the app to another computer unless you copy the entire project folder. The debug version of the app requires access to other by-products of the build process in order to run.
    Build/Release also invoked three Xcode compiler error
    messages that seem to indicate that I need to change
    the NIB settings:
    The following errors are not related to your NIB file. They indicate you're trying to link against the 10.3.9 frameworks on an intel CPU. The 10.3.9 frameworks are PPC only.
    /usr/bin/ld: warning
    /Developer/SDKs/MacOSX10.3.9.sdk/System/Library/Framew
    orks/Cocoa.framework/Cocoa cputype (18, architecture
    ppc) does not match cputype (7) for specified -arch
    flag: i386 (file not loaded)
    /usr/bin/ld: warning
    /Developer/SDKs/MacOSX10.3.9.sdk/System/Library/Framew
    orks/AppleScriptKit.framework/AppleScriptKit cputype
    (18, architecture ppc) does not match cputype (7) for
    specified -arch flag: i386 (file not loaded)
    /usr/bin/ld: warning fat file:
    /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libSyst
    em.dylib does not contain an architecture that
    matches the specified -arch flag: i386 (file
    ignored)
    [snip]
    Take a look at the suggestions I made in this thread to make sure your project is set up to build a universal binary and to ensure that you're linking against the 10.4 universal frameworks.
    Steve

  • Create a tab view item in obj-c for use in applescript studio

    I'm making an application with applescript studio. I want to be able to add tab view items to a tab view at the press of a button. The problem I have is applescript studio doesn't allow me to create a new tab view item. So I'm thinking I can create the tab view item using objective-c, pass that to my applescript, then add it to my tab view.
    In applescript I plan to use the following call methods to first create the tab view item object, and then add it to my tab view. The objective-c code which is called from the first line in the applescript code is below that. When I run my code I'm getting an error saying newTVI is not defined... so maybe you can see my error! Be kind to me because I'm new to objective-c and I'm sure that's where my problem lies. Anyway, I'd appreciate any help.
    ==Applescript calls to create and add a new tab view item
    set newTVI to call method "returnNewTabViewItem" of class "makeNewTabViewItem"
    call method "addTabViewItem:" of objMainTV with parameter newTVI
    ==Objective-c code to create the tab view item
    ==makeNewTabViewItem.h==
    #import <Cocoa/Cocoa.h>
    @interface makeNewTabViewItem : NSTabViewItem
    NSTabViewItem *newTVI;
    -(NSTabViewItem *)returnNewTabViewItem;
    @end
    == makeNewTabViewItem.m==
    #import "makeNewTabViewItem.h"
    @implementation makeNewTabViewItem
    -(NSTabViewItem *)returnNewTabViewItem
    newTVI = [[[NSTabViewItem alloc] initWithIdentifier:nil] autorelease];
    return newTVI;
    @end

    Please, any ideas?

  • Starting mysql daemon hangs applescript studio app

    hi,
    i am currently writing a small application with applescript studio that starts an apache server and a mysql database.
    Starting apache via a 'do shell' command is no problem at all but starting mysql with this command
    do shell script "/pathto/mysqldsafe --port=2323 --somemoreoptions &"
    hangs my application.
    Executing the command in a shell works well.
    I guess the problem is that firing the command (in the terminal) causes the terminal to return to the command prompt (username:~ username$ ) pretty immediatley. But after one or two seconds there are some more information echoed to the shell ('Starting mysqld daemon with databases from pathto_datadir').
    Maybe this confuses my app and it starts waiting for things that will never end.
    My current workaround is to open the terminal and to execute the command there:
    tell application "Terminal"
      do script "pathto/mysqldsafe --port=3023 --somemoreoptions &"
      delay 1
      if terminalwasopen is equal to false then
        quit
      else
        close window 1
      end if
    end tell
    Any ideas how to get rid off this wokaround and how to manage this with a simple 'do shell script'?
    Thanks in advance.
    i++
    PowerBook Pro 15"   Mac OS X (10.4.7)  

    This issue is discussed in the do shell script technote.
    Specifically, even though you tell the process to background (by appending the &), AppleScript still holds onto the process' stdout and stderr, waiting for the output of the command.
    The solution is to suppress or redirect stdout and stderr, e.g.:
    do shell script "/pathto/mysqldsafe --port=2323 --somemoreoptions > /dev/null 2>&1 &"
    The '> /dev/null' suppresses stdout (which could go to a file if you prefer), and '2>&1' sends stderr to the same place as stdout.
    Incidentally, I assume you have some check to ensure apache and/or mysql aren't already active, right? This would cause a problem if mysql is already running.

  • Scripting AppleScript Studio Applications

    Is there a way to create commands in an AppleScript Studio application that could be called by an AppleScript? Ideally, I want to be able to use the command in an AppleScript and have it execute a handler in my Studio Application.
    Thanks,
    Carl

    Won't be a problem with AppleScriptObjC

  • Localize the name of AppleScript Studio application

    Hi,
    How to localize the name of an AppleScript Studio application (Xcode 2.4.1) ?
    I have found the solution in the developer doc, but nothing...
    - I have added CFBundleName in every InfoPlist.strings file (with and without the CFBundleName property in the Info.plist file)
    - I have added CFBundleExecutable in every InfoPlist.strings file (with and without the CFBundleExecutable property in the Info.plist file)
    - I have tried to make localizable the Info.plist file, modifying the CFBundleName and CFBundleExecutable property of every localization
    Of course, I have run "Clean All" between each operation...
    Thanks by advance, CU

    Solution...
    In Info.plist file:
    - The CFBundleName property must have a unique name
    - Add the LSHasLocalizedDisplayName key with string "YES"
    In every InfoPlist.strings file:
    - Add a CFBundleDisplayName property with localized name
    - Add a CFBundleName property with localized name (for the application menu)

  • AppleScript Studio/Xcode problem - Problem with text entries! Please help!

    Hey, I've been up for hours each night looking for solutions to this but still have had no luck.
    I am creating an app in Xcode/Applescript studio that will ask you to enter how many times you would like system events to repeat a certain keystroke. First of all, the code would look something like this:
    on click theObject
    If the name of theObject is equal to "myApplication" then
    (Right here would be where the variables representing text in an input in the app's window would be, which I have absolutely no clue what to type.)
    tell application "text edit"
    activate
    tell application "system events"
    keystroke x (x representing a variable)
    end tell
    end tell
    end clicked
    and that's about as far as I can get. I want a variable representing the text in the main text entry box, but I have no clue how to access that text, or even know if it's submitted or detected when I hit a button. Hopefully you're following, as I am way to confused to fully explain it, but please try and help me out if you can.

    Hi Kamprath445,
    Though this mentions iTunes, I think it has good examples you can use...
    http://dougscripts.com/itunes/itinfo/keycodes.php
    More in depth...
    http://developer.apple.com/documentation/applescript/conceptual/applescriptlangg uide/conceptual/ASLR_variables.html

  • Option+Return does not work in applescript studio

    Fresh install of osx 10.4.6 Tiger, newest release of xcode.
    I start an applescript studio application project, when editing in Xcode Option+Return does not insert the continue line character.
    I can open the same .applescript in the Applescript Editor and Option+Return does work.
    Also, Option+Return works in my desktop installation of Xcode. No idea what's different here or how to fix it, but it's really messing with my work flow.

    Moved to .NET SDK forum.
    Search here, lots of post on IIS and setting Printer Access Permissions for your application.
    Also search MSDN on what is required to for IIS to access local Printers.
    Also search for ActiveX Controls and Browser permissions, you'll likely have problems there also since most Browsers will not or do not recommend allowing any ActiveX control.
    Don

  • Need applescript studio older version

    I have been asked to program for a company. what I would like to do is go back to an older version of Applescript studio what actually uses Applescript so I can create on interface with drop down windows and that cool floating gray-ish window. I dont know Obj-C.
    what version of AS would that be. thanks for the info.

    AppleScript is a set of system components, so you can't just drop in an older set.
    AppleScriptObjC does use AppleScript, the main difference is in the way it accesses the Cocoa frameworks - AppleScript Studio essentially uses a bunch of terminology and handler wrappers around Cocoa methods that the Studio development team have gotten around to including, while ASOC can call Cocoa methods directly (a bit cleaner than Studio's call method kludge). You don't really need to know Objective C, but it does help a little when looking at the documentation - I know just enough to get an idea what some code snippet is doing, but don't ask me much more than that.
    Older AppleScript Studio projects can still be edited and compiled in Snow Leopard's Xcode, so the components are still in there. Since Apple wants everyone to start using the new framework, the older project templates have been removed, but they can also still be used. If you really need to develop a new Studio application, for example to use on older systems, you just need to do a couple of things.
    1) The AppleScript Studio palette can be enabled in Interface Builder by using defaults write com.apple.InterfaceBuilder3 IBEnableAppleScriptStudioSupport -bool YES
    2) You need to get a copy of an AppleScript Studio project template. If you have access to a Leopard system installation, the easiest way would be to make a copy of the desired template from the */Developer/Library/Xcode/Project Templates/Application* folder there, for example the *AppleScript Application* template (you can also download the old templates from my iDisk here). You probably shouldn't modify anything in the /Developer folder, but you can use custom project templates from your user's *~/Library/Application Support/Developer/Shared/Xcode/Project Templates/Application* folder, so copy your project template there (make intermediate folders as needed).
    Once the template is copied, you can select it when making a new project and use the old terminology as usual.

  • Applescript Studio - Dynamically named button title

    Can anyone tell me if it is possible to retrieve the title of a button in an Applescript Studio application?
    I have no problem if the title of the button is set in the Attributes Inspector.
    EXAMPLE:
    If I set the title of a button to "test" in the attributes inspector and attach a script to a button like:
    *display dialog (get title of button "btnName" of window 1)*
    the result will be a dialog containing the text "test"
    However, if I set the title of a button through a script like
    *set title of button "btnName" of window 1 to "test"*
    and then try to retrieve it the same way
    *display dialog (get title of button "btnName" of window 1)*
    the dialog is empty
    Does anyone know if it is possible to retrieve these dynamically set button titles?

    The name of the button has an applescript name, which is how I reference it from the script. But, the actual project uses a series of buttons which all have their titles set dynamically from a script. Also the mode of the buttons are set to "On Off" (not that I think that should make a difference) I am running leopard 10.5 with xcode 3.0.
    I'm rather new to Applescript Studio and xcode. I don't know what would be wrong with the set-up. And why I would have no problem setting the button titles from a script but not be able to retrieve them.
    I have come up with a work around, keeping track of the button titles in a separate array. I seems stupid to have to do that rather than access the existing button property, but it does work.
    I will have to set up a simple test to explore what may be going wrong.

  • AppleScript Studio: status bar and panel window

    My problem is that the panel won't open, and so I don't see the progress bar.
    All I am looking for is the panel to come down, show the progress bar turning, then for the panel to go away when iCal is done adding the event. This is the entire script, but I'm not sure I have everything right in Interface builder. The Documentation for display mentioned clicking panel ended, but then further down it looked like you didn't need it.
    I'm confused.
    -- +Event.applescript
    -- +Event
    -- Created by Michael Ewald on 6/26/06.
    -- Copyright 2006 Michael Ewald. All rights reserved.
    load panel "statusPanel" from nib "statusPanel"
    on clicked theObject
    -- Get & Format form items
    set eventTitle to contents of text field "eventTitle" of window "main" as string
    set eventLocation to contents of text field "eventLocation" of window "main" as string
    set EventNotes to contents of text view "eventNotesText" of scroll view "eventNotesScroll" of window "main"
    set allDay to state of button "allDay" of window "main"
    set startDate to current date
    set startDate to content of control "startDate" of window "main"
    set endDate to content of control "endDate" of window "main"
    -- Make Event
    start progress indicator "statusBar" of window "statusPanel"
    try
    start progress indicator "statusBar" of window "statusPanel"
    display "statusPanel" attached to window "main"
    tell application "iCal"
    set theCalName to "AppleScript Test"
    set theCal to calendar theCalName
    if allDay is equal to 1 then
    make new event at end of calendar theCalName with properties {summary:eventTitle, location:eventLocation, allday event:true, description:EventNotes}
    else if allDay is equal to 0 then
    make new event at end of calendar theCalName with properties {summary:eventTitle, location:eventLocation, start date:startDate, end date:endDate, description:EventNotes}
    end if
    end tell
    -- reset form
    set the contents of text field "eventTitle" of window "main" to ""
    set the contents of text field "eventLocation" of window "main" to ""
    set contents of text view "eventNotesText" of scroll view "eventNotesScroll" of window "main" to ""
    set state of button "allDay" of window "main" to 0
    set currentDate to current date
    set currentDatePlus to (current date) + 1 * hours
    -- Update Times
    set content of control "startDate" of window "main" to currentDate
    set content of control "endDate" of window "main" to currentDatePlus
    on error
    display alert "There was a problem!"
    end try
    close panel "statusPanel"
    end clicked
    ----

    Thanks for the response,
    right now the window is in a seperate nib file. I was
    trying to follow the applescript studio example
    "Display Panel"
    Then you need to load it, look at the example, you see panelWIndow is declared as property:
    property panelWIndow : missing value
    then inside on click handler:
    if panelWIndow is equal to missing value then
    load nib "statusPanel" -- if your nib is statusPanel.nib
    set panelWIndow to window "statusPanel" --> that's AppleScript window name
    end if
    then you can use:
    display panel panelWIndow attached to window "main"
    What is the advantage / disadvantage of having more
    than one nib file?
    Not a whole lot in simple app, because you have to load it to use it.
    But in more complex apps, the advantage is that you don't commit run time memory, if the users don't use it.

  • Applescript Studio Ad Builder Demo

    Apple distributed a CD for Applescript with a demo for InDesign 2.0 called Ad Builder. Is there an updated demo for CS2 sytax?? It built Real Estate pages..

    Hi--
    AppleScript Studio uses Xcode for creating, editing, and compiling applications, and Interface Builder is for building the GUI part. I'd suggest taking a look at the Apple Developer Connection web site.
    In particular, there's an introduction to AppleScript Studio that may or not explain it all to you. There are even some tutorials there on building apps and gheir GUIs.
    charlie

  • AppleScript Studio Problems...

    I have documented some AppleScript Studio problems that I have encountered, along with some screenshots.
    Hopefully somebody might have a clue what is causing the problems.
    http://www.mac-specialist.com/r/as_studio.html
    I would be grateful for any insights,
    Bill Hernandez
    Plano, Texas

    Steve,
    This is the message I sent earlier with new findings:
    After I deleted "Smart Crash Reports.bundle" in /Library/InputManagers/, I rebooted, went to AS Studio to see if there were any problems, and guess what ?
    The Debugger started working. It's been broken as long as I can remember. Every time I've wanted to learn how to work with AS Studio since it came out, the Debugger has never worked, and I always ended up moving on to something else.
    This is awesome...
    Bill Hernandez
    Plano, Texas
    <hr>
    On Dec 24, 2006, at 5:27 PM, Steve Hayman wrote:
    Hi Bill.
    Make sure you're building a debug version of the project in order for breakpoints to work. In Xcode you set this with Project > Set Active Build Configuration > Debug .
    This was the very first thing I checked the other day when I started trying to learn AS Studio in earnest.
    Also I don't think those messages you are seeing about Smart Crash REports.bundle actually indicate that the app has crashed; it's just reporting that it can't load this bundle for some reason, and then proceeding anyway - I don't see anything that indicates your app has crashed.
    I read a long article at : http://daringfireball.net/2006/01/smartcrashreports
    and came away without a real solution. It was close to 3 am so I was barely awake, but came away confused as to what the solution was. I had used Unsanity's products particularly the menu product, but they caused too many problems with Quickeys and 4th Dimension. After talking to the people that write Quickeys, I disabled all their stuff and everything started working fine with Quickeys and 4D. They are far more important for me, that the Unsanity stuff.
    I agree with the Daring Fireball article, and am annoyed that Unsanity patches the OS without asking for permission. I won't buy their products any more.
    That bundle is something that certain third-party applications install which attempts to email crash reports for their apps back to their authors, rather than to Apple. I don't know what app you might have installed that included this but it would probably be safe to remove the bundle. (Double clicking on it wouldn't do anything; it's not intended to be double clicked; it just sits there and waits to be loaded.)
    After I wrote the original message I realized that it wasn't double clickable, but by then it was too late. I think it was probably Unsanity's APE, or FruitMenu.If you look at /Library/InputManagers/ there's an "info" file, and a "Smart Crash Reports.bundle". I just deleted both of them, if it causes a problem I'll copy them from another machine that doesn't have it. I'm not sure but I believe they patch the original one from Apple. I'm not sure if that is correct?
    <hr>
    On 22-Dec-06, at 8:54 PM, Bill Hernandez wrote:
    Wizards,
    I have documented some AppleScript Studio problems that I have encountered, along with some screenshots.
    Hopefully somebody might have a clue what is causing the problems.
    http://www.mac-specialist.com/r/as_studio.html
    I would be grateful for any insights,
    Bill Hernandez
    Plano, Texas

  • Applescript Studio Problems, Web Browser

    Hey,
    I'm attempting an application using Applescript in Xcode because I just can't get my head around objective-c.
    So far I have a GUI with a button and a webview both linked to this code:
    on clicked (theObject)
    if the name of theObject is "loadgoogle" then
    tell mainwindow
    open location "http://google.com"
    end tell
    end if
    end clicked
    It compiles fine but when I click the button nothing happens.
    Could someone please enlighten me?
    Kind Regards
    Message was edited by: maximart4u

    Are you really using *AppleScript Studio*, or are you just dropping the old handlers into a new AppleScriptObjC project?
    If you are creating a new project, note that AppleScript Studio is deprecated in Snow Leopard. You can still edit existing AppleScript Studio projects (which explains why it compiles), but your on clicked handler does not meet the new naming protocol used in AppleScriptObjC and Interface Builder.
    See the AppleScriptObjC Release Notes - it has information about enabling the AppleScript Studio palette in Interface Builder (the AppleScript Studio project templates have been removed, though). There is also a AppleScriptObjC in Xcode tutorial at MacScripter that should get you started.

  • AppleScript Studio + Sparkle Framework for auto updates

    I have sucessfully added the Sparkle framework to one of my Applescript Studio applications, but I'm having trouble finding out how to call a Cocoa method from within an Applescript. I need to live-update the interval at which Sparkle checks for updates. As of now I have to restart the app for the changes to take place.
    Here is the explanation from their documentation on how to do it...
    http://sparkle.andymatuschak.org/wiki/Documentation/PeriodicChecks
    +You might make a menu in your preferences to let the user specify this interval; just update SUScheduledCheckInterval in the user defaults with the user’s choice—a setting there will override one in Info.plist. You’ll need to let Sparkle know when the interval changes, though: *just call scheduleCheckWithInterval: on your SUUpdater (it’ll cancel the old one).*+
    I just don't know how to do this in Applescript. I'm assuming it's possible through the "call method" command, but I haven't been able to figure it out by myself.
    My best guess was the following...
    +call method "scheduleCheckWithInterval:" of object "SUUpdater"+
    Has anyone got this working before?
    Thanks for any help.

    Won't be a problem with AppleScriptObjC

Maybe you are looking for

  • Xslt mapping in Imported archieves

    Hi all, The requirement is that I need to use XSLT mapping for this I created message mapping copied as a .xslt file and imported in the imported archeives and then I removed the message mapping . The problem is that when I try to use this XSLT mappi

  • Elements 11 wont let me open a file?

    I bought Elements 11 and a new Macbook Air about a month ago. Everything has been working great until yesterday. When I open Elements it won't let me work on any of the PSD files I've saved. All of the menu options turn light gray and won't let me op

  • Re: Help needed for easy Math & Java problems

    The logic in pseudo code : IF length <= 1 Price = Base price;//Base price = 8 in your case; ELSE IF length <= 10 Price = Base price + (Extra Meter Price * (length - 1)); ELSE IF length <= 20 Price = (Base price + (Extra Meter Price * (length - 1))) *

  • Getting Error:500 when trying to "Reset Client" Under setting tab in Mobile

    Hi All, We are getting following error when we are trying to Reset Client Under settings tab in the Mobile Device. Anyhelp would be highly appreciated. Client Details: MI70 SP15 0 Application: MAM LAPTOP3.0 with SR04. DB2e: 9.1.2. Error: 500 Location

  • Export message in READY status before oaiimport

    Hi all, We do not use migrate for production environment but OAIIMPORT as : - oaiimport is more reliable - we don't want to let production people doing those manipulations with ISTUDIO But we have a problem as we begin to have a lot of flows on produ