ラベルに Web サービスの 1 つのフィールドが表示されます。10 文字のラベルを表示したいのですが、コードが機能しません。
didEndElement コード内:
if ([elementName isEqualToString:@"StationName"] ) {
StationName.text = retornoSOAP;
returnSOAP = nil;
tReturn = NO;
}
このコードは機能しています。StationName フィールドを StationName ラベルに表示します。
ここで私の間違いはどこですか?
- (void)viewDidUnload {
*NSString *temp =@" ";
if ([temp length] > 10) {
NSRange range = [temp rangeOfComposedCharacterSequencesForRange:(NSRange){0, 10}];
temp = [temp substringWithRange:range];
}
StationName.text= temp;
}