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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T17:22:23+00:00 2026-06-06T17:22:23+00:00

I’m new on this, and I would like to get some advice because I

  • 0

I’m new on this, and I would like to get some advice because I don’t know what I’m doing wrong.
I want to make an app in xcode, with a UIView with some items, and when you do something, another UIView (smaller than the first) pops up above the first UIView. The popup UIView would be a customized class.

I have started with the UIViewController template and the initial UIView, and I have linked all the items in the .storyboard, and it works. But when I create my own UIView class (from objective-C class), put the second UIView over the first in the storyboard and link it to my class, something goes wrong.

The UIView appears, but when I try to set it to hidden, it doesn’t answer. It’s like it’s not receiving the messages, so I think I don’t link it well programmatically and just appears because of the storyboard.

I don’t know if I have to create another UIViewController instead of the UIView, or if this is the correct path.

Can anybody explain me a little, or just write a little code snippet with the instantiation of the second view and adding it?

Lots of thanks!!

(I paste some code, of the declaration in .h and instantiation in .m)

     #import <UIKit/UIKit.h>
     #import "EditView.h"

    @interface ReleaseViewController : UIViewController <UIWebViewDelegate, UISearchBarDelegate> {

        IBOutlet UIWebView *web;
        IBOutlet UISearchBar *search;
        IBOutlet EditView *evHack;

    }

    @property (nonatomic, retain) IBOutlet UIWebView *web;
    @property (nonatomic, retain) IBOutlet UISearchBar *search;
    @property (nonatomic, retain) IBOutlet EditView *evHack;

    @end

- (void)viewDidLoad
{
    [super viewDidLoad];

    search.delegate = self;
    web.delegate = self;

    evHack = [evHack initWithFrame:CGRectMake(0, 44, 320, 377)]; 
    [evHack setHidden:YES]; 

}

EditView Class (I still have nothing):

#import <UIKit/UIKit.h>

@interface EditView : UIView

@end



#import "EditView.h"

@implementation EditView

- (id)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        NSLog(@"View created");
    }
    return self;
}

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect
{
    // Drawing code
}
*/

@end
  • 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-06-06T17:22:25+00:00Added an answer on June 6, 2026 at 5:22 pm

    initWithFrame only works when you alloc/init an app. If its already initialized, in this case by the storyboard, just set its frame:

    evHack.frame = CGRectMake(0,44, 320, 377);

    I don’t know what it looks like in IB, But setting its frame in code may be redundant if you set it in IB too. To check whether evHack is hooked up right, NSLog evHack in viewDidLoad. If you get nil back, it’s not hooked up right.

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

Sidebar

Related Questions

For some reason, after submitting a string like this Jack’s Spindle from a text
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I would like to count the length of a string with PHP. The string
I want use html5's new tag to play a wav file (currently only supported
I would like to run a str_replace or preg_replace which looks for certain words
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I know there's a lot of other questions out there that deal with this
Does anyone know how can I replace this 2 symbol below from the string
I would like my Web page http://www.gmarks.org/math_in_e-mail.txt on my Apache 2.2.14 server to display
I'm new to using the Perl treebuilder module for HTML parsing and can't figure

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.