hi i am new to vba i want to Update cells via a user form. user enter data in form and update in some cells like c5, c6, d5, d6, e6. e7.
one more thing i want to show some data from the sheet on a user form. please help me...
below given is code for 1st user form.
one more thing i want to show some data from the sheet on a user form. please help me...
below given is code for 1st user form.
Code:
Option ExplicitPrivate Sub int_cal1_Click()
Worksheets("Non-Deduction").Activate
Range("A5").Select
'Date
ActiveCell.Offset(0, 3).Range("A5").Select
Selection.Value = DD1.Text
ActiveCell.Offset(1, 3).Range("A5").Select
Selection.Value = DD2.Text
'Month
ActiveCell.Offset(0, 4).Range("D5").Select
Selection.Value = MM1.Text
ActiveCell.Offset(1, 4).Range("D6").Select
Selection.Value = MM2.Text
'Year
ActiveCell.Offset(0, 5).Range("E5").Select
Selection.Value = YYYY1.Text
ActiveCell.Offset(1, 5).Range("E6").Select
Selection.Value = YYYY2.Text
'TDS Amount
ActiveCell.Offset(3, 3).Range("C7").Select
Selection.Value = TDSAMT.Text
'TDS Rate
ActiveCell.Offset(5, 3).Range("C9").Select
Selection.Value = TDSRATE.Text
Me.DD1.SetFocus
Me.DD2.SetFocus
Me.MM1.SetFocus
Me.MM2.SetFocus
Me.YYYY1.SetFocus
Me.YYYY2.SetFocus
Me.TDSAMT.SetFocus
Me.TDSRATE.SetFocus
Non_deduct.Hide
End Sub