Loads a specific type of file into the RichTextBox control.


object.LoadFile( path, type )


path - The name and location of the file to load into the control.

type - Optional. One of the RichTextBoxStreamType values. The default is RichText.

Return Value



When loading a file with the LoadFile method, the contents of the file being loaded replace the entire contents of the RichTextBox control. This will cause the values of the Text and Rtf properties to change. You can use this method to load a previously created text or Rich Text Format (RTF) document into the control for manipulation. If you want to save the file, you can use the SaveFile method.

You can use this version of the LoadFile method to specify the file type of the file being loaded. This feature enables you to load files other than RTF documents into the control.

See Also

Applies To: RichTextBox

The CHM file was converted to HTML by chm2web software.