What I am trying to do is click a button (that was created in code) and have it call up a different view controller then have it run a function in the new view controller.>
Just Follow these steps
1.import your app delegate in your class where you want app delegate object.
#import "YourAppDelegate.h"
2.inside your class create an instance of your app delegate object(Its basically a singleton).
YourAppDelegate *appDelegate=( YourAppDelegate* )[UIApplication sharedApplication].delegate;
3.Now invoke method using selector
if([appDelegate respondsToSelector:@selector(yourMethod)]){
[appDelegate yourMethod];
}
or directly by
[appDelegate yourMethod];
for swift
let appdel : AppDelegate = UIApplication.shared.delegate as! AppDelegate
i will recommend the first one. Run and Go.