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.
関数が完了したときにチェックボックスを自動的に選択する方法を教えてください。条件をチェックします。関数が完了したら、チェック ボックスがオンになっていることを自動的に表示する必要があります。
前もって感謝します。
チェックボックスはxmlから自動的にチェックできます
<CheckBox android:id="@+id/checkbox1" . . . android:checked="true" />
または次のようなJavaコードを設定します
CheckBox cbCheckbox = (CheckBox)findViewById(R.id.checkbox1); cbCheckbox .setChecked(true);