how should i use open/save dialog boxes with loading in html files in vb 7.0 beta 2? i just am wanting to dump them into a text box
Printable View
how should i use open/save dialog boxes with loading in html files in vb 7.0 beta 2? i just am wanting to dump them into a text box
Just call their properties, you can't expect to use a default property of a property though.
Here's a quick example using the System.IO namespaceBest regardsVB Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim fs As System.IO.FileStream Dim sr As System.IO.StreamReader With OpenFileDialog1 If .ShowDialog() = DialogResult.OK Then fs = .OpenFile sr = New System.IO.StreamReader(fs) TextBox1.Text = sr.ReadToEnd() End If End With End Sub