Showing posts with label different example. Show all posts
Showing posts with label different example. Show all posts

Tuesday, 6 November 2012

remove the background color from search bar in iPhone

for (UIView *subview in [searchBar subviews]) {
    if ([subview isKindOfClass:NSClassFromString(@"UISearchBarBackground")])
    {
        [subview removeFromSuperview];
    }
}

for (UIView *subview in [searchBar subviews]) {
        NSLog(@"%@", [subview class]);
}

Customizing the search bar textfield in iPhone

http://caydenliew.com/2012/01/customize-uisearchbar-background-image/
for (UIView *subview in [searchBar subviews]) {
        if ([subview isKindOfClass:NSClassFromString(@"UISearchBarBackground")])
        {
            [d

        if ([subview isKindOfClass:NSClassFromString(@"UISearchBarTextField")]) {
            [(UITextField *)subview setBackground:[UIImage imageNamed:@"searchboxbg.png"]];
        }
    }

Changing the search bar textfield left search icon in iPhone

 UITextField *textfield=(UITextField*)[[searchBar subviews] objectAtIndex:0];
            UIImage *image = [UIImage imageNamed: @"searchbtn.png"];
            UIImageView *iView = [[UIImageView alloc] initWithImage:image];
            textfield.leftView=iView;

Checking device compatibilty comparision parameter in iphone

iPhone 1G
iPhone 3G
iPhone 3GS
iPhone 4
Verizon iPhone 4
iPhone 4S
iPad
iPad 2 (GSM)
iPad 2 (CDMA)
iPad-3G (4G)

Image color operation in iphone

https://github.com/tomsoft1/StackBluriOS
CIImage

Collection view in iOS 6 with Xcode 4.5 in iPhone

https://github.com/RomanN2/CollectionView

Starting to ending for the registering and issuing the certificate for the IOS program.

http://www.raywenderlich.com/8003/how-to-submit-your-app-to-apple-from-no-account-to-app-store-part-1

Not reloaded issue with the CellforTowAtIndexPath + tableview + iphone

http://blog.d-17.com/2009/10/combining-multiple-uitextfields-and-a-uitableview-in-a-nice-way-for-an-iphone-app-part-2/

https://github.com/breeno/EditingUITableView

Write down this statement to the cellforrowatindexPath method of tableview and it will work now.
NSString *CellIdentifier = [NSString stringWithFormat: @"Cell%i", indexPath.row];


Example......
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
   
    NSString *CellIdentifier = [NSString stringWithFormat: @"Cell%i", indexPath.row];
   
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
    if (cell == nil) {
        cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] ;
        UITextField *textField = [[UITextField alloc]initWithFrame:CGRectMake(140.0, 12.0,170.0, 25.0)];
        textField.borderStyle = UITextBorderStyleNone;
        //yes strange, but otherwise the textfield won't show up :(
        cell.textLabel.backgroundColor = [UIColor blackColor];
        textField.tag=indexPath.row;
        //textField.text = [NSString stringWithFormat:@"value %i", indexPath.row];
        textField.placeholder= [NSString stringWithFormat:@"value %i", indexPath.row];
        [textField setDelegate:self];       
        //[textField addTarget:self                       action:@selector(textFieldDone:)
        //    forControlEvents:UIControlEventEditingDidEndOnExit];
        [cell.contentView addSubview:textField];
        [textField release];
        cell.textLabel.text = [NSString stringWithFormat:@"Item %i", indexPath.row];//[questionsArray objectAtIndex:indexPath.row];
        textField.returnKeyType=UIReturnKeyNext;
        if (indexPath.row==6) {
            textField.returnKeyType=UIReturnKeyDone;
        }
    }   
    cell.selectionStyle=UITableViewCellSelectionStyleNone;
    return cell;// autorelease];
}
 

Directly open up the map from the running app in iPhone

NSString* address = @"118 Your Address., City, State, ZIPCODE";
NSString* currentLocation = @"Current Location";
NSString* url = [NSString stringWithFormat: @"http://maps.google.com/maps?saddr=%@&daddr=%@",[currentLocation stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding],[address stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];
   UIApplication *app = [UIApplication sharedApplication];
[app openURL: [NSURL URLWithString: url]];

Thursday, 29 September 2011

Different example for iphone

http://pragprog.com/titles/cdirec/source_code
http://www.codingventures.com/2008/12/useful-open-source-libraries-for-iphone-development/

http://iphoneapp-dev.blogspot.com/2011/05/this-example-shows-how-to-upload-images.html

http://www.scoop.it/t/iphone-and-ipad-development/p/5853246/show-a-custom-popover-view-within-your-ipad-app-seaside

http://iphonecode.weebly.com/iphone-learning-codes.html

http://code.google.com/p/iphone-sdk-programming-book-code-samples/

http://www.iphoneexamples.com/

http://pragprog.com/titles/cdirec/source_code

http://www.theiphonedev.com/SourceCode/tabid/143/Default.aspx
http://iphone.zcentric.com/

http://www.bogotobogo.com/XcodeSDK-Chapter12.html