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

The Archive Base Latest Questions

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

hello every one i have table view with one cell,and i make on this

  • 0

hello every one
i have table view with one cell,and i make on this cell a UITextView that the user can write what he want,this is the code inside the cellForRow:

static NSString *CellIdentifier = @"Cell";
UITextView *text;

UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
    cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
    text = [[UITextView alloc]initWithFrame:CGRectMake(1, 5, 200, 140)];
    text.tag = 1;

    UIView *statusView = [[UIView alloc] initWithFrame:CGRectMake(0.0, 0.0, 300, 150)];
    statusView.tag = 0;
    [statusView addSubview:text];
    [cell.contentView addSubview:statusView];
}
else {
    text = (UITextView *)[[cell.contentView viewWithTag:0] viewWithTag:1];
}

i want to make a save button and i want to know how i can take the text from this UITextView from another method in the class.
thx

  • 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-23T00:21:52+00:00Added an answer on May 23, 2026 at 12:21 am

    Use UIButton to create the button and set a action (method) for that will be called when you click on button.

    -(void) buttonPressed:(id) sender
    {
       //First get the cell (We know we have the only one cell).
    
       // Create an NSIndexPath to access the cell from UITableView.
        NSIndexPath *myIndexPath = [NSIndexPath indexPathForRow:0 inSection:0];
    
       //Now We can access the cell using UITableView instance.
       UITableViewCell *myCell = [myTabelView cellForRowAtIndexPath:myIndexPath];
    
       //Now access the instance of UITextView using viewWithTag property of UIView.
       UITextView* myTextView = (UITextView*) [myCell viewWithTag:1];
    
    
       //Now you could get the text. :)
       NSString* myTextViewText = myTextView.text ;
    
    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

hi every body can some one help me with thi problem i have a
Hello every one i have strange bug with dropdownlist on one of the pages!
Hello every one I want to send ajax call and on success I want
Hello fellow developers, I am a little stumped on this one as I have
Hello can anybody solve this please I'm creating the object in the action class
Hello I am working with a simulator that uses rcS scripts to boot, this
I have a Linq object, and I want to make changes to it and
I have read some tutorials for bezier curve such as this one http://www.codeproject.com/KB/recipes/BezirCurves.aspx .
Hello I have a question that could seem complicated. But I will try to
Hello everyone and thank you for your answers and comments. I have a table

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.