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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T23:02:16+00:00 2026-05-25T23:02:16+00:00

This is a weird behavior that I just can’t understand: I access my own

  • 0

This is a weird behavior that I just can’t understand:

I access my own subclassed UIViews like this:

    UIView *aZettel = [self.view viewWithTag:100]; 
    NSLog(@"aZettel %@", aZettel);

The view I’m calling is my own class, it’s an UIView containing one UIImageView and one UILabel. NSLog shows:

    2011-10-04 09:45:35.969 accessapp[11264:207] aZettel <Zettel: 0x534b1c0; frame = (88 103; 160 106); tag = 100; layer = <CALayer: 0x534abc0>>

but when I write NSLog(@”aZettel %@”, aZettel.frame); the app crashes with EXC_BAD_ACCESS on the line with NSLog. Zombies says nothing.

I wouldn’t ask if I hadn’t already wasted almost one day with this. The longer I try stuff with trial and error the more confused I get. Anybody a hint what could be causing this?

  • 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-25T23:02:16+00:00Added an answer on May 25, 2026 at 11:02 pm

    Your program crashes because in

    NSLog(@"aZettel %@", aZettel.frame);
    

    NSLog expects its parameter to be valid object, while you pass c-struct to it (CGRect). Convert CGRect to NSString to log it:

    NSLog(@"aZettel %@", NSStringFromCGRect(aZettel.frame));
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

OK, I admit it this code will just look weird to you, and that's
I've seen this weird behavior on several sites recently: I scroll down a page
This is the day of weird behavior. We have a Win32 project made with
I'm experiencing this weird problem which my scrollbar jumps by itself to somewhere that
This is some weird behavior... Whenever I script certain tables (using CREATE TO...) or
I've got some weird behavior and I can only assume is because of the
We are getting a very weird behavior in our development environment that is consistent
I have stumbled on a weird thing. It looks like UIView 's contentScaleFactor is
I just noticed some weird behaviour with my Android 2.3.3 application. I can write
Should sound weird, but this is just for my hobby. I would want a

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.