JAVA 웹 과 비교를 하기위한 기타 기능 추가

This commit is contained in:
chi
2019-11-25 21:06:59 +09:00
parent 8174108238
commit 5cc843777c
14 changed files with 318 additions and 171 deletions

View File

@@ -54,5 +54,46 @@
' Me.bs.DataSource = DSETR
End Sub
Private Sub ToolStripButton1_Click(sender As System.Object, e As System.EventArgs) Handles ToolStripButton1.Click
Dim sd As New SaveFileDialog()
sd.Filter = "csv|*.csv"
sd.FilterIndex = 0
If (sd.ShowDialog() <> Windows.Forms.DialogResult.OK) Then Return
Dim Fs As New System.IO.FileStream(sd.FileName, IO.FileMode.Create)
Dim SW As New System.IO.StreamWriter(Fs, System.Text.Encoding.Default)
Dim Strbuf As String = ""
Dim colList As New List(Of Integer)
SW.WriteLine(",Code,Total,M1,M2,M3,M4,M5,M6,M7,M8,M9,M10,M11,M12")
Strbuf = ""
For Each DR As Windows.Forms.DataGridViewRow In DataGridView1.Rows
Strbuf = Strbuf & "," & DR.Cells(0).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 0).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 1).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 2).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 3).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 4).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 5).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 6).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 7).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 8).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 9).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 10).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 11).Value.ToString
Strbuf = Strbuf & "," & DR.Cells(7 + 12).Value.ToString
SW.WriteLine(Strbuf)
Strbuf = ""
Next
SW.Dispose()
Fs.Dispose()
MsgBox("저장완료" & vbCrLf & sd.FileName, MsgBoxStyle.Information, "확인")
Shell("notepad " & sd.FileName, AppWinStyle.NormalFocus)
End Sub
End Class