I am working in a small call center and when our clients call, we take the basic details like user_name, User_id, phone_number, problem. Now what I want is, when a call comes we will note down all the above mentioned details in to an excel sheet and when I click on update this data should be saved in another excel sheet.
Thanks in advance!
P.S.: What is a variable in Excel VBA?
Download a sample Excel file:
Excel VBA Code for the command button:
Private Sub CommandButton1_Click()
Dim CustomerName As String, CustomerProblem As Integer
CustomerName = Range(“C4”)
CustomerProblem = Range(“C5”)
If Worksheets(“Sheet2”).Range(“B4”).Offset(1, 0) <> “” Then
ActiveCell.Value = CustomerName
ActiveCell.Value = CustomerProblem
Watch the Excel training video below to see how data can be tranferred quickly and easily from one excel worksheet into another using Excel VBA: