Updating the filepath on formulas automatically

Buoyana

New Member
Joined
Jan 25, 2022
Messages
2
Office Version
  1. 2016
Platform
  1. Windows
I'm new to macros and I think the solution to my problem requires one... Please be thorough! I use VLOOKUP to pull from a data base that is shared on Dropbox, so every time the document is being opened from another computer, the formulas are no longer compatible. The name of the file I'm using is "EVALUATION_FEB_2022" and the file I'm pulling data from is "DATABASE_2022". In case it's useful, the formula I use is =VLOOKUP($C2,'[DATABASE_2022.xlsx]February'!$C$8:$W$81, 8, false). This formula spreads out across many columns and rows with different targets, so automation would be really useful. The current filepath is C:\Users\OOSB\Dropbox\OOSB\February\[DATABASE_2022.xlsx]February.
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
You have not said what the filepath of that database is on another computer? And also, why is not the same filepath - or am I not understanding the filepaths from computer to computer with Dropbox?
 
Upvote 0
It's not the same Filepath because it isn't the same Dropbox account, it is only a shared folder. The filepath would remain the same with the exception of a different username (e.g. C:\Users\Marie\Dropbox\MarieAntoinette\February\[DATABASE_2022.xlsx]February. Even if we shared the same account, the computer's username is also different.
 
Upvote 0
It's not the same Filepath because it isn't the same Dropbox account, it is only a shared folder. The filepath would remain the same with the exception of a different username (e.g. C:\Users\Marie\Dropbox\MarieAntoinette\February\[DATABASE_2022.xlsx]February. Even if we shared the same account, the computer's username is also different.
That doesn't answer my question. In fact it brings my question into focus - how does the macro know what the new filepath is to be? Is it based on username - as your example seems to be?
 
Upvote 0

Forum statistics

Threads
1,214,990
Messages
6,122,625
Members
449,093
Latest member
catterz66

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