Using sw As StreamWriter = File.CreateText(NomDeTonFichierCrée) sw.WriteLine("blablabla")
StreamWriter
WebBrowser?
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre questionPrivate Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim tpc As New System.Windows.Forms.TabControl.TabPageCollection(TabControl1) tpc.Add("coucou") End Sub
Public Class Navigateur Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Me.AcceptButton = Button3 End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click web.GoForward() End Sub Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click web.GoBack() End Sub Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click web.Navigate(TextBox1.Text) End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click web.Stop() End Sub Private Sub ToolStripDropDownButton1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub ToolStripStatusLabel1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub Label1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label1.Click End Sub Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click web.GoHome() End Sub Private Sub ProgressBar1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ProgressBar1.Click End Sub Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub web_DocumentCompleted(ByVal sender As System.Object, ByVal e As System.Windows.Forms.WebBrowserDocumentCompletedEventArgs) Handles web.DocumentCompleted End Sub Private Sub web_ProgressChanged(ByVal sender As System.Object, ByVal e As System.Windows.Forms.WebBrowserProgressChangedEventArgs) Handles web.ProgressChanged Dim Progress As Integer = e.CurrentProgress Dim ProgressMax As Integer = e.MaximumProgress Dim Pourcent As Short If ProgressMax <> 0 Then On Error Resume Next ProgressBar1.Maximum = ProgressMax If Not Progress < 0 Then ProgressBar1.Value = Progress End If Pourcent = Fix((Progress / ProgressMax) * 100) If Pourcent > 100 Then Pourcent = 100 End If Else ProgressBar1.Value = 0 End If End Sub Private Sub Label2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub PictureBox1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub LinkLabel1_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) End Sub Private Sub Button6_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click Me.web.Refresh() End Sub Private Sub Label2_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox1.TextChanged End Sub Private Sub Button3_KeyUp(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyEventArgs) End Sub Private Sub Button3_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Button3.KeyPress End Sub Private Sub CopierToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CopierToolStripMenuItem.Click TextBox1.Copy() End Sub Private Sub CollerToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CollerToolStripMenuItem.Click TextBox1.Paste() End Sub Private Sub ToutSelectionnerToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub QuitterToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles QuitterToolStripMenuItem.Click Me.Close() End Sub Private Sub ToolStripMenuItem2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripMenuItem2.Click Form2.Show() End Sub Private Sub PictureBox3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles PictureBox3.Click End Sub Private Sub MettreÀJourToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MettreÀJourToolStripMenuItem.Click Dialog3.Show() End Sub Private Sub AideToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles AideToolStripMenuItem.Click Form3.Show() End Sub Private Sub FichierToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles FichierToolStripMenuItem.Click End Sub Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click TextBox1.Text = web.Url.ToString() End Sub Private Sub TextBox2_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub Button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Using sw As StreamWriter = File.CreateText("fav.txt") sw.WriteLine(web.Url) End Using End Sub Private Sub Button8_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button8.Click Using sw As StreamWriter = File.CreateText("fav.txt") sw.WriteLine(web.Url) End Using End Sub End Class
Dim tpc As New System.Windows.Forms.TabControl.TabPageCollection(TabControl1) tpc.Add("coucou")
Using sw As New IO.StreamWriter("blabla.txt", True) sw.WriteLine("coucou") End Using
Using sw As New IO.StreamWriter("blabla.txt", True) sw.WriteLine("coucou") sw.close() End Using