Good morning,
I hope someone can help me with this. I have been developing a macro enabled workbook that essentially is a template for a number of users across the organisation to use.
Essentially, the users will each be provided a version of this workbook that they will then use to enter data, and run the macros (which do Data validation checks and basic formatting) before they send their data back to me.
However, the code for the procedures and functions that are used within the document may (almost definitely will) be updated and modified by me during the project (but will always remain standard across all the different user versions) - and therefore I would currently need to resend new versions to each of the users and then also ensure that the document they return is the new version with the latest version of the VBA code.
Is there a way in which I am able to have a central "VBA code" workbook that stores the Functions and then have each User's individual workbook simply call this central VBA code and effectively run it - applying any formatting/calculations - within the users document?
(I really hope that makes sense, I have tried to be as descriptive as possible. Below is a very basic Pseudo Code example of what I want to achieve)
User doc:
Sub CallCentralVBA
Workbooks.Open "CentralVBA.xlsm"
Call ApplyFormattingAndValidation <-- This is a sub housed in the Cental Doc, but all formatting is applied within User doc
End Sub
Central Doc:
Public Function ApplyFormattingAndValidation
DoStuff
End Function
I hope someone can help me with this. I have been developing a macro enabled workbook that essentially is a template for a number of users across the organisation to use.
Essentially, the users will each be provided a version of this workbook that they will then use to enter data, and run the macros (which do Data validation checks and basic formatting) before they send their data back to me.
However, the code for the procedures and functions that are used within the document may (almost definitely will) be updated and modified by me during the project (but will always remain standard across all the different user versions) - and therefore I would currently need to resend new versions to each of the users and then also ensure that the document they return is the new version with the latest version of the VBA code.
Is there a way in which I am able to have a central "VBA code" workbook that stores the Functions and then have each User's individual workbook simply call this central VBA code and effectively run it - applying any formatting/calculations - within the users document?
(I really hope that makes sense, I have tried to be as descriptive as possible. Below is a very basic Pseudo Code example of what I want to achieve)
User doc:
Sub CallCentralVBA
Workbooks.Open "CentralVBA.xlsm"
Call ApplyFormattingAndValidation <-- This is a sub housed in the Cental Doc, but all formatting is applied within User doc
End Sub
Central Doc:
Public Function ApplyFormattingAndValidation
DoStuff
End Function