IOS source code download: Scroll view of text + Images

Source: Internet
Author: User

IOS source code download: Scroll view of text + Images

Function category: Others

Supported platforms: iOS

Running Environment: iOS

Development language: Object-c

Development Tool: Xcode

Source code size: 1.22 MB

Source code:Http://down.51cto.com/data/1976925

Source code Introduction

This is a rolling view that combines problems and images. It can scroll left and right and display text descriptions.

Source code running

Source code snippets

 
 
  1. - (void)viewDidAppear:(BOOL)animated 
  2.     [super viewDidAppear:animated]; 
  3.     NSString *path = [[NSBundle mainBundle] pathForResource: 
  4.                       @"Places" ofType:@"plist"]; 
  5.       
  6.     NSMutableArray *placeArray = [[NSMutableArray alloc] initWithContentsOfFile:path]; 
  7.       
  8.     NSMutableArray *array = [[NSMutableArray alloc] init]; 
  9.     for (int i =0 ; i < [placeArray count] ; i++){ 
  10.           
  11.         NSDictionary *dict = [placeArray objectAtIndex:i]; 
  12.         PJRItems *item = [[PJRItems alloc] init]; 
  13.         item.itemTitle = [dict objectForKey:@"placeName"]; 
  14.         item.itemDesc = [dict objectForKey:@"placeDesc"]; 
  15.         item.itemImage = [dict objectForKey:@"placeImage"]; 
  16.         [array addObject:item]; 
  17.     } 
  18.       
  19.     PJRPageScrollingView *pagScrollView = [[PJRPageScrollingView alloc] initWithFrame:self.view.bounds withNumberOfItems:array]; 
  20.     [self.view addSubview:pagScrollView]; 
  21.   

Source code:Http://down.51cto.com/data/1976925

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.