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 6209871
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T06:03:42+00:00 2026-05-24T06:03:42+00:00

For those of you who use three20 ‘s TTPostController, how do you go about

  • 0

For those of you who use three20‘s TTPostController, how do you go about handling user errors before and after sending a request? i.e., if a user tries to post a blank comment, I want to be able to alert them and keep the view active so they can fix it.

The problem I’m having though is getting the modal view to stay open after things go wrong. I can alert the user, but once they click OK, the modal gets dismissed. I thought I was going be able to use TTPostControllerDelegate:willPostText delegate to accomplish this, but that doesn’t seem to be working, or I’m not understanding exactly how it’s designed to work.

What i’m doing:

/**
 * The user has posted text and an animation is about to show the text return to its origin.
 *
 * @return whether to dismiss the controller or wait for the user to call dismiss.
 */
- (BOOL)postController:(TTPostController*)postController willPostText:(NSString*)text {
    if ([text length] == 0) {
        UIAlertView * alert = [[UIAlertView alloc] initWithTitle:nil 
                                                         message:@"Your message is blank" 
                                                        delegate:self 
                                               cancelButtonTitle:@"OK" 
                                               otherButtonTitles:nil ];
        [alert show];
        [alert release];    

        return false;
    }        
    return true;
}

If I try posting a blank comment, I get an alert letting me know, but once I press OK, the modal view get’s dismissed.

Is there something I’m missing or not understanding correctly?

Edit: I should also note that I tried using alertView’s didDismissWithButtonIndex: method to try and stop the view from unloading, but i wasn’t successful.

  • 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-24T06:03:42+00:00Added an answer on May 24, 2026 at 6:03 am

    I ran into this the other day. If you pass nil instead of self as the delegate into:

    UIAlertView initWithTitle:message:delegate:cancelButtonTitle:otherButtonTitles 
    

    the TTPostController is no longer dismissed when the user touches “OK”.

    - (BOOL)postController:(TTPostController*)postController willPostText:(NSString*)text {
        if ([text length] == 0) {
            UIAlertView * alert = [[UIAlertView alloc] initWithTitle:nil 
                                                             message:@"Your message is blank" 
                                                            delegate:nil 
                                                   cancelButtonTitle:@"OK" 
                                                   otherButtonTitles:nil ];
            [alert show];
            [alert release];    
    
            return false;
        }        
        return true;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

A little help from those who’ve used Timthumb before. http://themes.amplus.gambit.ph/wp-content/themes/amplus/functions/timthumb.php?src=http://themes.amplus.gambit.ph/wp-content/uploads/2011/02/12979795614923485443_a1967ff888_b.jpg&w=860&h=300&f=5,255,0,0,0 This image should be
Here is the wiki for those who want to know about Apache CXF. http://en.wikipedia.org/wiki/Apache_CXF
I'm trying to sort friends by 2 criterias those who use my app first
This question is, as indicated, for those who use Emacs. When you do, do
Those who use Facebook have probably noticed the recent change to the photo albums
For those of us who use standard shared hosting packages, such as GoDaddy or
I am trying to use a forum with my website. Those who haven't registered
For those who use or have used THIS code, please tell me how to
For those of you who use the Amazon Product Advertising API, what experience have
Edit for those who say to use tab control I would love to use

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.