用于在代码中指定Web浏览器控件的URL的适当语法。 [英] Appropriate Syntax for specifying a URL for a web browser control in code.

查看:74
本文介绍了用于在代码中指定Web浏览器控件的URL的适当语法。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在使用Visual Studio 2015的VB项目中使用Web浏览器控件。我希望在表单上的组合框中添加多个URL选项。但是,我收到以下代码的语法错误:

I am using a Web browser control in a VB project using Visual Studio 2015. I wish to add multiple URL options to a combo box on the form. However, I am getting a syntax error for the following code:

wbFCC_Rules.Url = http://www.ecfr.gov/cgi-bin/text-idx?SID=e22c7f83fd948450ab39992b2e40c13b&mc=true&node=sp47.5.90.t&rgn=div6





我可以对相应的语法使用一些见解。



I could use some insight as to the appropriate syntax.

推荐答案

你必须传入URL作为Uri对象。

You have to pass in the URL as a Uri object.
wbFCC_Rules.Url = New Uri("yourUrlGoeshere")


这篇关于用于在代码中指定Web浏览器控件的URL的适当语法。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆