Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 01-31-2010, 04:13 PM   #16 (permalink)
evfalcon
Registered Member
 
Join Date: Jan 2010
Posts: 20
evfalcon is on a distinguished road
Default

i was able to get the error messages to go away by adding the end bracket before -(void) i've goofed around with it with no luck..by changing alertView to prompt I get a blank white screen after i enter. I have no clue as to how to make this work..i keep getting the same thing i had before a password box that dosent' work, here is the code i have..

- (void)viewDidLoad{





UIAlertView *prompt = [[UIAlertView alloc] initWithTitle:@"Password"
message:@"\n\n\n" // IMPORTANT
delegate:self
cancelButtonTitle:nil
otherButtonTitles:@"Enter", nil];


textField2 = [[UITextField alloc] initWithFrame:CGRectMake(12.0, 85.0, 260.0, 25.0)];
[textField2 setBackgroundColor:[UIColor whiteColor]];
[textField2 setPlaceholder:@"password"];
[textField2 setSecureTextEntry:YES];
[prompt addSubview:textField2];

// set place
[prompt setTransform:CGAffineTransformMakeTranslation(0.0, 110.0)];
[prompt show];
[prompt release];


// set cursor and show keyboard
[textField2 becomeFirstResponder];
}
- (void)promptUIAlertView *)prompt clickedButtonAtIndexNSInteger)buttonIndex {
if ([textField2.text isEqualToString: @"MyPassword"]) {
// Do something on good password
} else{

}




[super viewDidLoad];
webView.scalesPageToFit=YES;
webView.autoresizingMask = (UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight);
NSString *pdfPath = [[NSBundle mainBundle] pathForResource:@"2009EVFalcon" ofType:@"pdf"];

/*
If we have to take from its operational directory, then the next 4 lines will be used...

NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDire ctory, NSUserDomainMask, YES);
NSString *saveDirectory = [paths objectAtIndex:0];
NSString *saveFileName = @"myPDF.pdf";
NSString *pdfPath = [saveDirectory stringByAppendingPathComponent:saveFileName];
*/
self.pdfUrl = [NSURL fileURLWithPathdfPath];
[webView loadRequest:[NSURLRequest requestWithURLdfUrl]];
}


- (void)dealloc
{
[webView release];
[pdfUrl release];
[super dealloc];
}
@end
evfalcon is offline   Reply With Quote
 

» Advertisements
» Online Users: 563
13 members and 550 guests
daunmi, givensur, headkaze, iekei, jbro, Joseph262, kasumar, linkmx, samichaudry, sunlite, Thompson22, w0rldsell3r, yvonneolivia
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,443
Threads: 94,026
Posts: 402,591
Top Poster: BrianSlick (7,978)
Welcome to our newest member, Joseph262
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 09:11 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.