を疑う、用アプリの起動場合は、初めてアプリケーションの起動を乗り切るアプリケーションを初めて起動は、私は自分のアプリケーションに問題が生じています
NSUserDefaults *padFactoids;
int launchCount;
padFactoids = [NSUserDefaults standardUserDefaults];
launchCount = [padFactoids integerForKey:@"launchCount" ] + 1;
[padFactoids setInteger:launchCount forKey:@"launchCount"];
[padFactoids synchronize];
NSLog(@"number of times: %i this app has been launched", launchCount);
if (launchCount == 1)
{
NSLog(@"this is the FIRST LAUNCH of the myBibleapp");
// do stuff here as you wish
UIScrollView_PagingViewController *detailViewController = [[UIScrollView_PagingViewController alloc] initWithNibName:@"UIScrollView_PagingViewController" bundle:nil];
//detailViewController.firstString = firstString;
// ...
// Pass the selected object to the new view controller.
[self.navigationController pushViewController:detailViewController animated:YES];
[detailViewController release];
}
if (launchCount == 2)
{
// do stuff here as you wish
NSLog(@"this is the SECOND launch of the myBibleapp");
// do stuff here as you wish
}
を確認するために私のmainviewcontrollerのviewDidLoadメソッドでこのコードを持っている.I初めてUIScrollView_PagingViewControllerページに移動するか、mainviewcontrollerにとどまります。私の問題は、アプリが最初に起動されたときにメインコントローラのティックイメージを再表示する必要があります。最初の条件では、私はこれを行うには、コードからunhide何も得ていない。 ありがとうございます。
正確に画像を再表示しようとしていますか?最初の起動時にのみイメージを表示しますか? – giorashc
あなたはこのティックイメージをビュー(コントローラ)階層に配置する場所と場所をコードに示す必要があります。このチックイメージがmainController上にあるとし、detailViewControllerをpushすれば、tickImageをdetailViewControllerに置かないと表示されません。 –
@rokjarc tickはmainviewcontrollerです。上記のコードもmainviewcontrollerにありますviewdidload method.iはコードからUIScrollView_PagingViewControllerを削除したが運行はチェックしなかった – stackiphone