Hi, i am trying to implement this into my source code and i am finding it very difficult :
Code:
launch:
if (alertView.title == @"Launch Application WithIdentifier") {
[[[SBManagerAppDelegate sharedAppDelegate] userDefaults] setObject:[[alertView textField] text] forKey:@"launchApplicationWithIdentifier"];
[[UIApplication sharedApplication] launchApplicationWithIdentifier:[[alertView textField] text] suspended:NO];
}
uuid:
if (indexPath.row == 0) {
cell.textLabel.text = @"uniqueIdentifier";
cell.detailTextLabel.text = [[UIDevice currentDevice] uniqueIdentifier];
}
could anyone tell me how i could implement this into my source code here:
Code:
- (void)viewDidLoad {
[super viewDidLoad];
tableList = [[NSMutableArray alloc] init];
[tableList addObject:@"Open Application With Identifier"];
[tableList addObject:@"UUID"];
[self setTitle:@"YourInfo"];
// Uncomment the following line to display an Edit button in the navigation bar for this view controller.
// self.navigationItem.rightBarButtonItem = self.editButtonItem;
}
/*
- (void)viewWillAppear:(BOOL)animated {
[super viewWillAppear:animated];
}
*/
/*
- (void)viewDidAppear:(BOOL)animated {
[super viewDidAppear:animated];
}
*/
/*
- (void)viewWillDisappear:(BOOL)animated {
[super viewWillDisappear:animated];
}
*/
/*
- (void)viewDidDisappear:(BOOL)animated {
[super viewDidDisappear:animated];
}
*/
/*
// Override to allow orientations other than the default portrait orientation.
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations.
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
*/
- (void)didReceiveMemoryWarning {
// Releases the view if it doesn't have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren't in use.
}
- (void)viewDidUnload {
// Release anything that can be recreated in viewDidLoad or on demand.
// e.g. self.myOutlet = nil;
}
#pragma mark Table view methods
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
return 1;
}
// Customize the number of rows in the table view.
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
return [tableList count];
}
// Customize the appearance of table view cells.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
static NSString *CellIdentifier = @"Cell";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
}
[cell setText:[[tableList objectAtIndex:indexPath.row] retain]];
[cell setAccessoryType:UITableViewCellAccessoryNone];
return cell;
}
// Override to support row selection in the table view.
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
}
thanks in advance