Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Caranya saVe To Ms.Excel [VB.Net]
#1
oke kawan..
bAru beLaJar VB.Net Juga neh..
hehehee..

sekarang yAng mAu beLaJar .Net
buAt Form..
isinya 3 Text Box..dan 1 command Button..

ne codingnya..

Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim oExcel As Excel.Application Dim oWorkbook As Excel.Workbook Dim oSheet As Excel.Worksheet 'Buat Objec Aplikasi Excel oExcel = CreateObject("Excel.Application") oExcel.Visible = True 'Tambahkan Workbook Dan Sheet oWorkbook = oExcel.Workbooks.Add oSheet = oWorkbook.ActiveSheet 'Utak Atik Data Cell Excel oSheet.Cells(1, 1).Value = "Nama" oSheet.Cells(1, 2).Value = "Alamat" oSheet.Cells(1, 3).Value = "Hobby" oSheet.Cells(3, 1).Value = TextBox1.Text oSheet.Cells(3, 2).Value = TextBox2.Text oSheet.Cells(3, 3).Value = TextBox3.Text 'Buat Aplikasi Excel Visible oExcel.Visible = True oExcel.UserControl = True

Sekian..semoga berguna..huFh..

"Lakukan apa yang kalian inginkan, dapatkan apa yang kalian lakukan"
Reply


Messages In This Thread
Caranya saVe To Ms.Excel [VB.Net] - by Jacket^Cyber - 05-03-2010, 10:44 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)