0% found this document useful (0 votes)
26 views1 page

Coding Dasar

The document contains VBA code that activates a worksheet based on a combobox selection, inputs textbox values into cells below the last used cell, clears and repopulates the combobox with all worksheet names, and sets the combobox to the active sheet name.

Uploaded by

Balian TV
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views1 page

Coding Dasar

The document contains VBA code that activates a worksheet based on a combobox selection, inputs textbox values into cells below the last used cell, clears and repopulates the combobox with all worksheet names, and sets the combobox to the active sheet name.

Uploaded by

Balian TV
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1

PilihSheet = Me.ComboBox1.

Value
If PilihSheet = "" Then
Exit Sub
End If
Worksheets(PilihSheet).Activate
Set Datainput = ActiveSheet.Range("A1000").End(xlUp)
Datainput.Offset(1, 0).Value = Me.TextBox1.Value
Datainput.Offset(1, 1).Value = Me.TextBox2.Value

Dim ERWIN As Long


Me.ComboBox1.Clear
For ERWIN = 1 To Sheets.Count
Me.ComboBox1.AddItem Sheets(ERWIN).Name
Next
Me.ComboBox1.Value = ActiveSheet.Name

You might also like