Register FAQ / Rules Forum Spy Search Today's Posts Mark Forums Read
Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Apr 18, 2013, 10:16 PM   #1
SteveniMac
macrumors newbie
 
Join Date: Apr 2013
Is it possible to do this in Xcode

I want to know whether it is possible for Xcode to create any type of application that when opened, it would open a specified file on the desktop. It would also help if you could post the code to do this as well.
SteveniMac is offline   0 Reply With Quote
Old Apr 18, 2013, 10:48 PM   #2
Comeagain?
macrumors 68020
 
Comeagain?'s Avatar
 
Join Date: Feb 2011
Location: Spokane, WA
Sounds more like AppleScript is what you're looking for.
__________________
Questions? MRoogle it!
Current iOS 8 "All the little things!"
MR Scavenger Score: 1
Comeagain? is offline   0 Reply With Quote
Old Apr 19, 2013, 12:11 AM   #3
Red Menace
macrumors 6502
 
Join Date: May 2011
Location: Littleton, Colorado, USA
I would just put the file into an AppleScript application bundle and use the Finder to open it with the default application, for example:

Code:
set theFile to path to resource "Fake Profile.spx" -- a fake system profile
tell application "Finder" to open theFile -- open the file using the default application
__________________
MacBook Pro / OS X Mavericks (10.9.4) / Xcode 5.1.1 / RubyMotion FTW
Red Menace is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
thread Thread Starter Forum Replies Last Post
The App Store app thinks Xcode is installed, but I deleted Xcode. moonman239 Mac Applications and Mac App Store 3 May 6, 2014 05:53 PM
Moving from xcode 3.2 to xcode 4.5.2 compilation error for 'abs' macro in stdlib.h hrishidev Mac Programming 7 Jun 2, 2013 10:36 AM
Xcode 4.5 iNeedAnsurs iPhone 0 Jan 25, 2013 02:49 PM
Xcode 3 vs Xcode 4 when dealing with Objective-C timebourne Mac Programming 8 Sep 23, 2012 05:36 PM
XCode 4.4.1 to Xcode 4.5 in Mountain Lion VinegarTasters OS X 10.8 Mountain Lion 2 Sep 19, 2012 08:55 PM

Forum Jump

All times are GMT -5. The time now is 03:22 PM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013, MacRumors.com, LLC