What's new
Apple iPad Forum 🍎

Welcome to the Apple iPad Forum, your one stop source for all things iPad. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

IBAction Call

swilker

iPF Noob
Joined
Jul 4, 2011
Messages
12
Reaction score
0
Location
Maryland
Website
www.dean.usma.edu
:confused:
Help Please,

I'm new. I've been working on a plotting function that used a draw2D routing I found on line. I need to call the routine from IBAction with a date picker change and want to pass the date in the date picker. So basically I want to combine the IBAction and the plotting on the following two routines. Unsure how to combine them.

-(IBAction)showDate: (id) sender {
//date calculations.....
}

- (id)initWithFrame: (CGRect)frame {
if (self = [super initWithFrame:frame]) {
// Initialization code
}
return self;
}

- (void)drawRect: (CGRect)rect {
//drawing code
}
 
OP
S

swilker

iPF Noob
Joined
Jul 4, 2011
Messages
12
Reaction score
0
Location
Maryland
Website
www.dean.usma.edu
OK I tried some experiments that didn't work. For clarification I have a routine that draws some lines with these two declarations:

- (id)initWithFrame: (CGRect)frame {
if (self = [super initWithFrame:frame]) {
// Initialization code
}
return self;
}

- (void)drawRect: (CGRect)rect {
//drawing code
}

What I want is, for that to happen only when I push a button or some other action. I clearly don't understand the structure of the calls or I'd be able to do this. Can someone help me.

Drew
 
OP
S

swilker

iPF Noob
Joined
Jul 4, 2011
Messages
12
Reaction score
0
Location
Maryland
Website
www.dean.usma.edu
I am simply amazed. I asked this question yesterday at 12 and have had 71 people look at it without an answer. Come on. I'm not looking for the secret to life or an explanation of string theory. Just want to use an IBAction to draw a line. Is there anyone out there that that can actually program in this God awful language that will help me? Please....
 

twerppoet

iPad Fan
Joined
Jan 8, 2011
Messages
24,193
Reaction score
15,536
Location
Milton-Freewater, OR
Most of the people here are users, not developers. I see a moderator moved your post to the developer section, but it is more than possible that none of them have seen this, or that the few that have do not have an answer for you.

My own experience puts me some where between the user and developer (heavily biased towards user), and other than recognizing the code I haven't a clue.
 
OP
S

swilker

iPF Noob
Joined
Jul 4, 2011
Messages
12
Reaction score
0
Location
Maryland
Website
www.dean.usma.edu
Twerppoet,

Thanks much. I simply couldn't understand why no one posted a reply. I know this isn't a difficult question for a developer. I will go to work tomorrow and get someone to help me. I was hoping to get some help while on vacation to keep my project moving. I'm going to write free ware for educational projects for kids if I ever get proficient at Objective C and I Pad programming. Just getting started.

Drew
 

twerppoet

iPad Fan
Joined
Jan 8, 2011
Messages
24,193
Reaction score
15,536
Location
Milton-Freewater, OR
Good luck with that. It is a worthy cause.

Have you checked out KhanAcademy? They have an iPhone app, and are working on an iPad one. Seems like a group you'd be interested in, if you don't' already know about them.
 

Most reactions

Latest posts

Top