qstring ss = "http://124.71.132.71:18080/jeeplus_lndwfs/deviceAlive"使用代码将其改成ss ="http://221.226.146.230:28082/jeeplus_lndwfs/getWaitData"
时间: 2023-12-02 18:04:15 浏览: 33
你可以这样修改:
```
QString ss = "http://221.226.146.230:28082/jeeplus_lndwfs/getWaitData";
```
这样就可以将 ss 的值修改为 "http://221.226.146.230:28082/jeeplus_lndwfs/getWaitData"。
相关问题
QString str = QString("C:/Qt/lei-muban.dot").arg(dir.absolutePath());
This line of code creates a QString object named "str" that contains a path to a file named "lei-muban.dot". The path is specified as "C:/Qt/lei-muban.dot", and the ".arg()" method is used to insert the absolute path of the directory specified by the "dir" object.
For example, if "dir.absolutePath()" returns "C:/users/johndoe/documents/", the resulting string stored in "str" would be "C:/Qt/lei-muban.dot/C:/users/johndoe/documents/".
Note that this may not be a valid file path, as it could result in a directory being treated as part of the filename. It would be more appropriate to use QString's "append()" method to add the directory path to the end of the file path, like so:
QString str = QString("C:/Qt/lei-muban.dot").append(dir.absolutePath());
This would result in "str" containing the string "C:/Qt/lei-muban.dot/C:/users/johndoe/documents/" (using the example directory path from earlier).
QString strDataDir = QApplication::applicationDirPath() + "/../../Data/GridCache";是几层目录
这代码中的`"../../"`表示返回上级目录两次,所以`QApplication::applicationDirPath()`返回的是当前应用程序的目录,再加上`"/../../Data/GridCache"`,就是在当前应用程序目录的上级目录两次后的`Data/GridCache`目录。所以总共是两层目录。