I got a little program with a button that when the user presses it I want it to open another view, the button is "Add note" I want that new view slides from bottom to top so user can add the info and accept it, the same way like you can in address book add new contact. What I got here is a class called Notecontroller and function to open my other view that is linked to it:
Here is the code
Notecontroller.h
Notecontroller.m
Sorry I am this noob, but I couldn't google even as I don't know the exact words.
Here is the code
Notecontroller.h
Code:
#import <Foundation/Foundation.h>
@interface Notecontroller : UIViewController {
IBOutlet UITableView * TableView;
IBOutlet UIView * OpenView;
}
-(IBAction)OpenAddnoteform:(id)sender;
@end
Notecontroller.m
Code:
#import "Notecontroller.h"
@implementation Notecontroller
-(IBAction)OpenAddnoteform:(id)sender
{
//
// Notecontroller.m
// Muistio
//
// Created by Samuli Lehtonen on 28.5.2010.
// Copyright 2010 Test. All rights reserved.
//
#import "Notecontroller.h"
@implementation Notecontroller
-(IBAction)OpenAddnoteform:(id)sender
{
[OpenView setFrame:CGRectMake(0, 480, 320, 480)];
[OpenView setBounds:CGRectMake(0, 0, 320, 480)];
[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:1.0];
[UIView setAnimationDelegate:self];
[OpenView setFrame:CGRectMake(0, 0, 320, 480)];
[UIView commitAnimations];
}
@end
}
Sorry I am this noob, but I couldn't google even as I don't know the exact words.