Control.ResolveClientUrl(String) Control.ResolveClientUrl(String) Control.ResolveClientUrl(String) Control.ResolveClientUrl(String) Method

定义

获取浏览器可以使用的 URL。Gets a URL that can be used by the browser.

public:
 virtual System::String ^ ResolveClientUrl(System::String ^ relativeUrl);
public string ResolveClientUrl (string relativeUrl);
abstract member ResolveClientUrl : string -> string
override this.ResolveClientUrl : string -> string
Public Function ResolveClientUrl (relativeUrl As String) As String

参数

relativeUrl
String String String String

相对于当前页的 URL。A URL relative to the current page.

返回

适合用于浏览器的指定资源的完全限定 URL。A fully qualified URL to the specified resource suitable for use on the browser.

实现

异常

注解

ResolveClientUrl使用方法可返回适合客户端访问 Web 服务器上的资源(例如图像文件、其他页面的链接等)的 URL 字符串。Use the ResolveClientUrl method to return a URL string suitable for use by the client to access resources on the Web server, such as image files, links to additional pages, and so on.

备注

此方法返回的 URL 是相对于包含实例化控件的源文件的文件夹的相对路径。The URL returned by this method is relative to the folder containing the source file in which the control is instantiated. 继承此属性的控件(如UserControlMasterPage)将返回相对于控件的完全限定的 URL。Controls that inherit this property, such as UserControl and MasterPage, will return a fully qualified URL relative to the control.

适用于