2012-04-02 23 views

答えて

0

カスタムフィールドを編集して無効にすることができます。カスタムフィールドにテキストを設定したいとします。あなたは

field.setText("Test"); 

のsetTextがこのように

public void setText(String text) 
{ 
this.text=text; 
invalidate(); 
} 

でなければなりません、あなただけのたCustomFieldを無効にすることができませんし、それだけでは

+0

ありがとう先生、変更のためにその作業偉大を再描画されますマネージャーで一度に1つのフィールドの内容が、複数のフィールドに同時に適用したい場合は、それが正しく機能していません。なぜ、その背後にある理由がありますか? – 1001

+0

どのように複数のフィールドに適用しようとしましたか?コードを投稿してください – rfsk2010

+0

hello sir plz reply to fast私のコード – 1001

0
 public void flashScreen(){ 
    new Thread(){public void run(){ 
      try{ 
       int alertLevelColor[]=new int[bedList.size()]; 

       for(int i=0;i<3;i++){ 
        for(int j=0;j<bedList.size();j++){ 
         BedInfo bedInfo= (BedInfo)bedList.elementAt(j); 
         if(bedInfo.isFlash){ 
          BedField bdField=(BedField)vfm.getField(j); 
          alertLevelColor[j]=bedInfo.alertLevelColor; 
          bdField.rePaintField(MvisumAlertMain.appMain.loginUser.backgroundColor); 
         } 
        } 
        Thread.currentThread().sleep(300); 
        for(int k=0;k<bedList.size();k++){ 
         BedInfo bedInfo=(BedInfo)bedList.elementAt(k); 
          if(bedInfo.isFlash){ 
          BedField bdField=(BedField)vfm.getField(k); 
          bdField.rePaintField(alertLevelColor[k]); 
         } 
        } 
        Thread.currentThread().sleep(300); 
       } 
      //} 
      }catch(Exception e){ 
       MvisumAlertUtil.saveException("BedListScreen","Flash Screen",e.toString()); 
      } 
     }}.start(); 
} 
+0

上記はコードです。私は3-4フィールドを同時に再描画したいので、plzはコードをチェックアウトしています。 – 1001

関連する問題