Excel VBA: Read and Write Cell Values Using Cells()

Опубликовано: 24 Июнь 2026
на канале: Alex Luy
4,776
55

In this lesson of Excel VBA for Professionals, we transition from hard-coded inputs to reading directly from Excel cells. You’ll learn how to use the Cells() function to retrieve values from your spreadsheet, perform calculations, and write the result back to a cell.

✅ Learn how to:

Read input from cells using Cells(row, column)

Perform basic arithmetic operations on cell values

Output results to another cell dynamically

This is a critical skill for anyone serious about automating Excel. No more static values—your macros will now interact with live spreadsheet data!

📌 Practice tip at the end included!

00:00 – Welcome back to Excel VBA for Professionals
00:10 – Recap: Input, Process, Output (IPO model)
00:27 – Transitioning from static variables to Excel cell input
00:42 – Declaring a variable to store a cell’s value
01:06 – Understanding how `Cells(row, column)` works
01:30 – Accessing cell value at (1,1) and printing it
02:14 – Accessing value from another cell using row/column index
02:40 – Performing addition using values from two cells
03:05 – Declaring multiple variables to store cell input
03:40 – Performing the sum and storing the result in a variable
04:45 – Displaying result using `MsgBox`
05:15 – Writing the result to another Excel cell
06:05 – Writing to `Cells(5, 1)` (row 5, column 1)
06:40 – Final demo: Output shows up in Excel sheet
07:20 – Homework assignment: Try outputting to row 2, column 4
08:50 – Outro and contact info