so whats the problem you can use checkbox checked changed event
Private Sub CheckBox1_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged
If CheckBox1.Checked = True Then
Directory.CreateDirectory("Path")
System.IO.File.Create("Path\filename.txt")
Dim sw As StreamWriter = New StreamWriter("FileName")
sw.Write("Your Information")
End If
End Sub