本文整理匯總了VB.NET中System.Web.UI.HtmlTextWriter.Write方法的典型用法代碼示例。如果您正苦於以下問題:VB.NET HtmlTextWriter.Write方法的具體用法?VB.NET HtmlTextWriter.Write怎麽用?VB.NET HtmlTextWriter.Write使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類System.Web.UI.HtmlTextWriter
的用法示例。
在下文中一共展示了HtmlTextWriter.Write方法的11個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的VB.NET代碼示例。
示例1:
' Create a manually rendered <img> element
' that contains an alt attribute.
writer.WriteBeginTag("img")
writer.WriteAttribute("alt", "A custom image.")
writer.Write(HtmlTextWriter.TagRightChar)
writer.WriteEndTag("img")
示例2: testChars
Private testChars() As Char = _
{"h"c, "e"c, "l"c, "l"c, "o"c, _
HtmlTextWriter.SpaceChar, "w"c, "o"c, "r"c, "l"c, "d"c}
示例3:
' Render a character array as the
' contents of a <label> element.
writer.RenderBeginTag(HtmlTextWriterTag.Label)
writer.Write(testChars)
writer.RenderEndTag()
示例4: WriteLine
' Use the WriteLine(Double) method to render
' the MaxValue field of the Double structure.
writer.RenderBeginTag(HtmlTextWriterTag.Label)
writer.WriteLine(Double.MaxValue)
writer.RenderEndTag()
示例5:
' Use the Write method to render an arbitrary
' object, in this case a CultureInfo object.
writer.Write("This is a rendered CultureInfo Object.")
writer.RenderBeginTag(HtmlTextWriterTag.B)
writer.Write(CultureInfo.CurrentCulture)
writer.RenderEndTag()
示例6: Write
' Use the Write(Single) method to render the
' Epsilon field of the Single structure.
writer.RenderBeginTag(HtmlTextWriterTag.B)
writer.Write(Single.Epsilon)
writer.RenderEndTag()
示例7:
' Create a non-standard tag.
writer.RenderBeginTag("MyTag")
writer.Write("Contents of MyTag")
writer.RenderEndTag()
writer.WriteLine()
示例8: Write
' Use the Write(string, object) method to
' render a formatted string and an object in it.
writer.RenderBeginTag(HtmlTextWriterTag.Label)
writer.Write("The current cultural settings are {0}.", _
CultureInfo.CurrentCulture)
writer.RenderEndTag()
示例9:
' Render a formatted string and the
' text representation of an object array,
' myObjectArray, as the contents of
' a <label> element.
writer.RenderBeginTag(HtmlTextWriterTag.Label)
writer.Write("The trade value at {1} is ${0}.", curPriceTime)
writer.RenderEndTag()
示例10:
' Render a subarray of a character array
' as the contents of a <label> element.
writer.RenderBeginTag(HtmlTextWriterTag.Label)
writer.Write(testChars, 0, 5)
writer.RenderEndTag()
示例11: Write
' Use the Write(string,object,object) method to
' render a formatted string and two objects
' in the string.
writer.RenderBeginTag(HtmlTextWriterTag.Label)
writer.Write("The current cultural settings are {0}. Today's date is {1}.", _
CultureInfo.CurrentCulture, DateTime.Today)
writer.RenderEndTag()