-1

我想为黑莓应用程序做一个 httpconnection。我使用像这样的网址

http://ip:port/prueba.php;deviceside=true

如果我想通过wifi在设备中使用它,我添加interface=wifi。

但我不知道为什么它不通过 EDGE 连接。我还能做些什么吗?我听说你已经签署了你的申请,但我不明白。

4

1 回答 1

0

使用:";deviceside=true;ConnectionUID="+ srTCP.getUid()

 private ServiceRecord srTCP;
 private void init() 
    {

        ServiceBook sb = ServiceBook.getSB();
        ServiceRecord[] records = sb.getRecords();

        for (int i = 0; i < records.length; i++)
        {
            ServiceRecord myRecord = records[i];
            String cid, uid;

            if (myRecord.isValid() && !myRecord.isDisabled()) 
            {
                cid = myRecord.getCid().toLowerCase();
                uid = myRecord.getUid().toLowerCase();
                if (cid.indexOf(WPTCP_STR) != -1 && uid.indexOf(WIFI_STR) == -1 && uid.indexOf(MMS_STR) == -1) 
                {
                    String httpProxyAddress = getDataString(myRecord, BYTE_PROXY_ADDRESS);
                    if ((httpProxyAddress == null) || StringUtils.isBlank(httpProxyAddress.trim())) 
                    {
                        srTCP = myRecord;
                    } 
                }
            }
      }
  }
于 2012-04-24T05:59:09.873 回答