'Declaration Public Sub Load( _ ByVal stream As Stream, _ ByVal type As RichTextType _ )
public void Load( Stream stream, RichTextType type )
Parameters
- stream
- Stream with content
- type
- RichText type; one of rtf, html or text
'Declaration Public Sub Load( _ ByVal stream As Stream, _ ByVal type As RichTextType _ )
public void Load( Stream stream, RichTextType type )
The data loaded from the stream replaces the existing text in the RichTextBox.
private void Detail_Format(object sender, System.EventArgs eArgs) { System.IO.FileStream streamR = new System.IO.FileStream(System.Windows.Forms.Application.StartupPath + "\\sample.rtf", System.IO.FileMode.Open); rtfRTF.Load(streamR, RichTextType.Rtf); System.IO.FileStream streamH = new System.IO.FileStream(System.Windows.Forms.Application.StartupPath + "\\sample.html", System.IO.FileMode.Open); rtfHTML.Load(streamH, RichTextType.Html); }
Private Sub Detail_Format(ByVal sender As Object, ByVal e As System.EventArgs) Handles Detail.Format Dim streamR As New System.IO.FileStream(Application.StartupPath & "\sample.rtf", IO.FileMode.Open) rtfRTF.Load(streamR, RichTextType.Rtf) Dim streamH As New System.IO.FileStream(Application.StartupPath & "\sample.html", IO.FileMode.Open) rtfHTML.Load(streamH, RichTextType.Html) End Sub