Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
iOS開発初心者です。私の現在のタスクは、ボタンをクリックして画像を変更することです。画面は 4 ~ 5 個の画像で構成され、ボタンをクリックすると、4 ~ 5 個の画像のいずれかが変更されます。進め方を教えてください。
前もって感謝します。
よろしく、 バスカー M.
まず、ボタンを押したときに起動するメソッドを作成する必要があります。そして、このようなものを作ります
-(void) buttonPushed{ //MyImageView will be the one you need to change //you can choose it randomly. It's up to you [MyImageView setImage:[UIImage imageNamed:@"qwe.jpg"]]; }