config.wepKeys[0] = "";  
config.wepTxKeyIndex = 0;  
额,这两句去掉就可以了。 

解决方案 »

  1.   

    问下楼主:为什么有些值总是重复设定,下面的GroupCiphers,搜索了好多都是这样
    if(Type == Data.WIFICIPHER_WEP) 
               { 
                   config.hiddenSSID = true;
                   config.wepKeys[0]= "\""+Password+"\""; 
                   config.allowedAuthAlgorithms.set(WifiConfiguration.AuthAlgorithm.SHARED); 
                   config.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.CCMP); 
                   config.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.TKIP); 
                   config.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.WEP40); 
                   config.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.WEP104); 
                   config.allowedKeyManagement.set(WifiConfiguration.KeyMgmt.NONE); 
                   config.wepTxKeyIndex = 0; 
               }