In order to save traffic, but also for a better user experience, many applications now use the local caching mechanism so I looked up the relevant data from the Internet, and found that there are generally two ways. One is to write their own cache
Sometimes we need to take the elements out of the array and then put them in a string and separate the elements with commas, and if we use [NSString stringwithformat:@ "%@%@", @ "", @ ","] stitching up, not to achieve the desired effect. A very
First of all, Uialertview and Uiactionsheet in iOS9 after the official Apple is not recommended, but use Uialertcontroller to replace.There are pictures to testify
So it is necessary to learn how to use Uialertcontroller.
1. Get the
Touch events are the most commonly used events in iOS, and here we introduce the next touch event.
Define Uiimageview in the following example. First we add touch events to the Toucheventviewcontroller and move the image using the touch move event,
Converts the current date to the day of the week
- (void) Getweek { nscalendar *calendar = [[nscalendar alloc]
initWithCalendarIdentifier:NSGregorianCalendar];
NSDate *now;
NSDateComponents *comps = [[NSDateComponents alloc] init];
The control of the UITableView control in the Iphone/ipad development process has many interesting places, such as implementing scrolling controls common to Android and returning to the top effect, which can be achieved with the following code, but
The Uiactionsheet in iOS offers only a handful of styles in the SDK that basically meet the development requirements, but also encounter more cumbersome requirements, which require a separate custom uiactionsheet to modify the button's properties.
To customize a cell by inheriting UITableViewCell
1, create an empty project, named:
2. Create a Uitableviewcontroller and create xib at the same time:
3. Set the root controller of windows in APPDELEGATE.M for the tableviewcontroller you
Effect:
The code is as follows
Copy Code
1. The Custom click button toggles the different Tableviewcell, the effect as shown in the picture
Hqsliderview.gif
The system's Uipickerview is very simple, the style is also very simple monotonous, the interface feeling is very monotonous not good-looking, sometimes needs us to customize, makes oneself wants the style. First give the generic style of the
Organize UIImagePickerController and save the image to the album,
// This method is used on the ios8.0 system. Previously, you can use the code to create an album, manually delete it, and then use this library to create the newly deleted album, in
IOS open-source project weekly report 0105, ios open-source project 0105
The fourth issue of the iOS open-source project weekly, which was produced by OpenDigg, is coming. Our iOS open-source weekly report combines the high-quality open-source iOS
Embedded & iOS: callback function (C) and block (OC) callback comparison, embedded training
After learning the OC block, it is awkward to write the C callback function. Compare the difference and record it.
C callback function:
CallBack. h
1)
AFNetworking error "_ UTTypeCopyPreferredTagWithClass", referenced from: _ AFContentTypeForPathExtens, chromeextens
Problem: During interaction with Unity, the following error occurs when a project file packaged from the Unity development tool is
RunLoop Summary: application scenarios of RunLoop (1): runloop scenariosReferences
Good books are worth reading. Good articles and good materials are worth reading. We can get different results from the same articles, materials, or books at
Common shortcuts for iOS development and ios shortcuts
2. Basic Xcode shortcut
Create a project Shift + CMD + N
Create a file CMD + N in the project
Run CMD + R
Compile CMD + B
Stop running CMD +.
Clear cache Shift + CMD + K
Left indent CMD +
Difference between _ block and _ weak, __block _ weak
Blocks comprehension:
Blocks can access local variables, but cannot be modified.
If you modify a local variable, add _ block.
_ Block int multiplier = 7; int (^ myBlock) (int) = ^ (int num)
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