Check Version Against 2nd File

RandyD123

Active Member
Joined
Dec 4, 2013
Messages
296
Office Version
  1. 2016
Platform
  1. Windows
I have a file called Travel Orders which when opened checks another file called "FL_Version_Checker". If the version numbers match then the Travel Orders file stays open and can be used. If they do not match, the Travel Orders file closes and gives an error message. The problem is that the status bar keeps showing the message "Checking Travel Orders Version. Please Wait...." even if they match. I would like the status bar to update if they match and show a message that says "Version Match Please Continue" Not sure how to do that. My VB code is as follows:

VBA Code:
Private Sub Workbook_Open()
    Sheets("Travel Orders").Activate
    With Application
        .EnableEvents = False
        .ScreenUpdating = False
        .StatusBar = "Checking Travel Orders Version.  Please wait..."
    End With
    Workbooks.Open "https://path to/FL_Version_Checker.xlsm", , True
    Workbooks("Travel Orders.xlsm").Activate
    If Workbooks("Travel Orders.xlsm").Sheets("Travel Orders").Range("M1").Value <> Workbooks("FL_Version_Checker.xlsm").Sheets("Version").Range("C3").Value Then
        Application.StatusBar = "You are running an old version of 'Travel Orders'.  Please download the newest version from iShare."
        MsgBox "You are running an old version of 'Travel Orders'.  Please download the newest version from iShare.", 16, "Wrong Version"
        Workbooks("FL_Version_Checker.xlsm").Close SaveChanges:=False
        With Application
            .EnableEvents = True
            .StatusBar = ""
        End With
        Workbooks("Travel Orders.xlsm").Close SaveChanges:=False
    End If
    Workbooks("FL_Version_Checker.xlsm").Close SaveChanges:=False

End Sub

I'm not sure how to add the "Version Match Please Continue" part?
 
So the version check works fine. The "user and date" in M2 and M3 (Travel Orders) need to change but ONLY when a drop down is actually used. Saving the "Travel Orders" sheet alone should not change M2 or M3 if no drop downs were used.
On the hidden Data Sheet, E10 and E11 SHOULD change, but only when someone has made a change and saved it. Making a change on this sheet and not saving it should not alter E10 or E11

Users will ONLY see the Travel Orders sheet. Most will never know about the hidden Data Sheet. All sheets will be set to read only and password protected (pass). If a user was to save the workbook to their desktop, it should open locked. All sheets are using "pass" as the temp password.

Links to sheets are: https://drive.google.com/file/d/1IgvGUArXS2chZH-wE_88aOA6m41zQ8uw/view?usp=drivesdk

https://drive.google.com/file/d/1Ih9Lt_t7CTAFW-IcFdL8a3p9Pi803Kny/view?usp=drivesdk

Thank You!
 
Upvote 0

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.
What is the "table" on the Travel Orders sheet? I can't seem to refer to any of it's cells? Dave
There is nothing that "table" all drop downs are feed through Data Validation. The travel orders sheet is simply a grid. Maybe something google did?
 
Upvote 0
Unfortunately, Google sheets and Google VBA are not the same and apparently can't be easily interchanged. Sorry I don't have Google sheets and will be unable to provide any further assistance. Perhaps, others may be of assistance. Good luck. Dave
 
Upvote 0
Unfortunately, Google sheets and Google VBA are not the same and apparently can't be easily interchanged. Sorry I don't have Google sheets and will be unable to provide any further assistance. Perhaps, others may be of assistance. Good luck. Dave
Ok. But those file were uploads from MS Excel, not Google Sheets.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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