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

  • Home
  • SEARCH
  • 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 3623484
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T23:23:21+00:00 2026-05-18T23:23:21+00:00

Hey …. im working on a Iphone app ..i cant get this working: i

  • 0

Hey …. im working on a Iphone app ..i cant get this working:

i want this alert to show up if the text field is empty when clicking the button linked to “timedAlarm” and if the text filed has a text i want it to go ahead and do the local notification, every thing works fine, until i put in this code before all the code for the notification, i have tried a lot of ways, but it wont work, either the alert shows up, even if there is a text, or els the alert wont show.

- (IBAction) timedAlarm {

    if (eventText.text != nil){

        UIAlertView *message = [[UIAlertView alloc] initWithTitle:@"Excuse Me !" 
                                                          message:@"Plz enter an alarm text" 
                                                         delegate:nil 
                                                cancelButtonTitle:@"OK" 
                                                otherButtonTitles:nil]; 

        [message show]; 

        [message release]; 

    }else {

Hope u can help me 😀

Rene Skov

  • 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-18T23:23:21+00:00Added an answer on May 18, 2026 at 11:23 pm

    First of all you show alert if text is entered in textfield (i.e. text property is not nil), so you need to reverse condition you have. Additionally you may want to check if current text is an empty string (user might enter some text and delete it afterwards – in that case text will not be nil).

    if (event.text == nil || [event.text length] == 0){
       // Show alert
    }
    else{
      // Text is ok
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hey trying to get a validation check working on a boolean field called 'activated'.
Hey i have been looking around and i cant find a way to get
*Hey , I have finished developing my app In my iphone apps I have
hey guys having this really simple problem but cant seem to figure out have
Hey I can't figure out an error I got. I had my App working
Hey i am new to iOS development, in my app i want to fetch
Hey am just curious to know if this can be done! I want to
Hey guys, I always get confused by this so it's not exactly my strong
Hey, I'm trying to get the source code of an app similar to the
Hey guys this is my html code: <div class=nakupy> <li class=icn_kategorie><a href=#>Nákupy</a> <div class=sub_menu>

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.