app out of app

Discussion in 'iOS Programming' started by exmerci, Feb 10, 2012.

  1. exmerci
    Expand Collapse
    macrumors newbie

    Joined:
    Feb 10, 2012
    #1
    Hello,

    i'm ab beginner in xcode.
    I have make an app with a button to start an website.
    My question. Is it possible to make a button in an app to start another app?
     
  2. jonnymo5
    Expand Collapse
    macrumors 6502

    Joined:
    Jan 21, 2008
    Location:
    Texas
    #2
    If you just want a website you don't need another app. You could certainly tell the iPhone to open the url using mobile safari app but you could also just include a webview in your application.

    Can you give some more detail on what you want to do and what kind of webpage you want to open?
     
  3. xStep
    Expand Collapse
    macrumors 68000

    Joined:
    Jan 28, 2003
    Location:
    Less lost in L.A.
    #3
    As jonnymo5 said, more detail of your needs would be helplful.

    The following code will open up the URL into Safari. I connect a button to it, in Interface Builder in my case. This will push your app in the background of course.

    Code:
    - (IBAction) appWebSite:(id)sender
    {
        NSString * urlString = [NSString stringWithString: @"http://www.morphedthought.com"];
        [[UIApplication sharedApplication] openURL:[NSURL URLWithString: urlString]];
    }
    
     
  4. dejo
    Expand Collapse
    Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #4
    Yes, if you know the Custom URL scheme of the other app.
     
  5. exmerci
    Expand Collapse
    thread starter macrumors newbie

    Joined:
    Feb 10, 2012
    #5
    Okay, and how ist the code?

    I want to start apples remote out from my app.
     
  6. dejo
    Expand Collapse
    Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #6
    I feel I've given you enough info that you should be able to find this out on your own. I normally don't just give coded solutions out.

    Do you know the Custom URL Scheme for Apple's Remote app?
     

Share This Page