Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 902183
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T15:40:36+00:00 2026-05-15T15:40:36+00:00

I am writing a simple iPhone application and I am wondering if there is

  • 0

I am writing a simple iPhone application and I am wondering if there is something equivalent to C#’s try{}-catch{}-finally{} exception handling.

I have come across a few references via google, but I am having trouble figuring out what the actual syntax is on the iPhone platform.

Does anyone know of a very basic example on how to do this?

Many thanks,
Brett

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T15:40:37+00:00Added an answer on May 15, 2026 at 3:40 pm

    The actual syntax on the iPhone platform/framework is the same as it is in obj-c because it is still obj-c with a set of classes. This kinda stuff is easily found in the online obj-c documentation provided by apple and any intro obj-c book. The Google-fu answer:

    Cup *cup = [[Cup alloc] init]; 
    
    @try { 
        [cup fill]; 
    } 
    @catch (NSException *exception) { 
        NSLog(@"main: Caught %@: %@", [exception name], [exception reason]); 
    } 
    @finally { 
        [cup release]; 
    } 
    

    Now, if you are looking for how this code fits into an iPhone application then you can download a sample application and copy the syntactical structure.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am writing an iPhone application and need to essentially implement something equivalent to
Hey folks - I'm writing a pretty simple iPhone application. The data comes from
I am writing a very simple application, for the iPhone. Unfortunately I am really
Is there any reference about writing an application on iPad/iPhone to show HTML5 content
I am writing a iphone application using phonegap and ios. I have a weird
I have a children's iPhone application that I am writing and I need to
I am writing a simple application using the Facebook iPhone SDK. The Facebook code
i am writing a simple application for iphone wich displays a rotating cube. I
I'm writing a simple iPhone app which lets a user access a series of
I'm writing simple GUI using wxPyhon and faced some problems. My application does simple

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.