Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 134427
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T06:36:40+00:00 2026-05-11T06:36:40+00:00

As I understand it when I create an Excel sheet with VBA code the

  • 0

As I understand it when I create an Excel sheet with VBA code the VBA code is saved as binary with the sheet. I therefore can’t put the code into source control in a useful way, have multiple devs working on the problems, diffing is difficult, etc.

Is there a way round this without switching to VSTO, COM addins etc? E.g. for the sheet to load all is VBA in at runtime from a web service, shared drive, etc? Any ideas appreciated.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T06:36:41+00:00Added an answer on May 11, 2026 at 6:36 am

    I wrote a kind of build system for Excel which imports the VBA code from source files (which can then be imported into source control, diffed, etc.). It works by creating a new Excel file which contains the imported code, so it might not work in your case.

    The build macro looks like this, I save it in a file called Build.xls:

    Sub Build()     Dim path As String     path = 'excelfiles'      Dim vbaProject As VBIDE.VBProject     Set vbaProject = ThisWorkbook.VBProject      ChDir 'C:\Excel'     ' Below are the files that are imported     vbaProject.VBComponents.Import (path & '\something.frm')     vbaProject.VBComponents.Import (path & '\somethingelse.frm')      Application.DisplayAlerts = False     ActiveWorkbook.SaveAs 'Output.xls'     Application.DisplayAlerts = True      Application.Quit End Sub 

    Now, the VBIDE stuff means you have to import a reference called “Microsoft Visual Basic for Applications Extensibility 5.3′, I think.

    Of course you still have the problem with having to start Excel to build. This can be fixed with a small VB script:

    currentPath = CreateObject('Scripting.FileSystemObject') _     .GetAbsolutePathName('.') filePath = currentPath & '\' & 'Build.xls'  Dim objXL Set objXL = CreateObject('Excel.Application') With objXL     .Workbooks.Open(filePath)     .Application.Run 'Build.Build' End With Set objXL = Nothing 

    Running the above script should start the build Excel file which outputs the resulting sheet. You problably have to change some things to make it movable in the file system. Hope this helps!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 66k
  • Answers 67k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • added an answer Eclipse has built-in support for Emacs key-bindings. The only support… May 11, 2026 at 11:43 am
  • added an answer Since SHA1 is a common, standard algorithm, it is implemented… May 11, 2026 at 11:43 am
  • added an answer You can do SELECT * INTO #MyTable_tmp FROM MyTable Then… May 11, 2026 at 11:43 am

Related Questions

As I understand it, when asked to reserve a larger block of memory, the
As I understand it, .bat is the old 16-bit naming convention, and .cmd is
As I understand it, anything created with an alloc , new , or copy
As I understand it, the command to ignore the content of a directory using
I'm no crypto expert, but as I understand it, 3DES is a symmetric encryption
How secure is it to use self-signed certificates? As far as I understand it,
Why was C# designed this way? As I understand it, an interface only describes
PHP has a number of opcode caches, which as i understand it are scripts
Both Session.Clear() and Session.Abandon() get rid of session variables. As I understand it, Abandon()
It seems I don't understand javascript callbacks quite as well as I thought. In

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.