Smtp.NET 3 Documentation

SmtpServer.GetWebPageHtml Method 

Downloads the specified URL and puts HTML into a string buffer.

[Visual Basic]
Public Shared Function GetWebPageHtml( _
   ByVal Url As String _
) As String
[C#]
public static string GetWebPageHtml(
   string Url
);

Parameters

Url
The URL to download

Return Value

String that contains HTML

Remarks

This method is provided as a helpful utility for downloading a web page into a local string.

Example

[C#]
            public void Send()
            {
                 string sHTML = SmtpServer.GetWebPageHtml("http://www.yahoo.com");
            }
            
[VB]
            Public Function Send() As Integer
                 Dim sHTML As String
            
                 sHTML = SmtpServer.GetWebPageHtml("http://www.yahoo.com")
            End Function
            

See Also

SmtpServer Class | SmtpServer Members | SmtpDotNet Namespace