get data from closed workbook then add to current cell then sum

jmendenhall1960

New Member
Joined
Feb 14, 2012
Messages
41
So what I am tring to do is to get results (a number) from a cell which is a result of a formula. This is in a workbook that is not open but in the same network drive and folder as active workbook. I have searched past posts and have had no luck. This is the formula I have tried. ='network/CINRPC1/users/CINMendej2/MasterCopy of Cynthia's Schedule PP 12 and 13/sheet1'!AE4+AF4
. I get a formula error. What I want to do is get number from sheet1!AF4 (which is the result of a formula) and then add (sum) to active sheet AE4 . I have tried =SUM then click on the workbook to open and this did not work either. If this is possible Thanks for looking and your help.
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
You can do it via VBA code like this:

Code:
With GetObject("c:\test path\other workbook.xls")
    Thisworkbook.Activesheet.Range("AE5") = .Sheets(Sheet1").Range("AF4") + Thisworkbook.Activesheet.Range("AE4")
    .Close False
End With

Totally untested haha, but should work if I wrote it out correctly.
 
Upvote 0
I have to do this for AE4: AE39 (35) different rows. Will this work for each one. I have to add the scheduled OT hours from last month schedule to this months schedule for each person.

You can do it via VBA code like this:

Code:
With GetObject("c:\test path\other workbook.xls")
    Thisworkbook.Activesheet.Range("AE5") = .Sheets(Sheet1").Range("AF4") + Thisworkbook.Activesheet.Range("AE4")
    .Close False
End With

Totally untested haha, but should work if I wrote it out correctly.
 
Upvote 0

Forum statistics

Threads
1,223,909
Messages
6,175,315
Members
452,634
Latest member
cpostell

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top