cristiander
New Member
- Joined
- Jul 4, 2017
- Messages
- 7
I'm working on a workbook that needs to make modifications on other workbooks, but I can't get the most rudimentary functions to work.
I think I might be defining my workbooks incorrectly.
As a start I have made:
But it's simply not working. It's not changing any values. I don't understand where the problem is.
Is there something wrong with the definitions?
I think I might be defining my workbooks incorrectly.
As a start I have made:
Code:
Sub Work_tables()
Dim tbl_a As Workbook
Dim tbl_b As Workbook
Set tbl_a = Workbooks.Open("C:\Users\...\table_a.xlsm")
Set tbl_b = Workbooks.Open("C:\Users\...\table_b.xlsm")
tbl_a.Sheets("sheet1").Range("A1").Value = 1
tbl_b.Sheets("sheet1").Range("A1").Value = 2
End Sub
But it's simply not working. It's not changing any values. I don't understand where the problem is.
Is there something wrong with the definitions?