当我用的端口号的IP地址作为URL值在我的配置文件,我收到以下错误如何在Visual Studio的配置文件中使用ip地址作为url?
System.NotSupportedException: The given path's format is not supported
但是当我使用像一个网站,这是工作的罚款“http://www.google.com” 我有什么用使支持这一IP地址格式...
PFB是配置文件我试过
<?xml version="1.0" encoding="utf-8"?
<configuration>
<appSettings>
<add key="baseURL" value="http://255.255.255.1:6060"/>
</appSettings>
</configuration>
显示实际读取'baseURL'并使用它 – haim770
没有HTTP代码://也给予同样的错误.. –
公共静态字符串BASEURL {得到 {返回System.Configuration.ConfigurationManager.AppSettings [“基本URL “]; } } –