+ Reply to Thread
Results 1 to 4 of 4

Excel 2007 Compatability Checker

  1. #1
    Forum Contributor
    Join Date
    04-12-2006
    Location
    Morgan Hill CA
    Posts
    107

    Excel 2007 Compatability Checker

    I have a customer using some code I developed and they just switched to Office 2007 and Excel 2007. Seems that now my program is prone to "Compatability Checks" - see this Microsoft blog link on the error which is now received

    http://blogs.msdn.com/excel/archive/...11/694891.aspx

    This worked beautifully with eearlier versions of Excel and now I have issues....

    I understand that when this compatability dialog comes up I can have my customer click the check box the click Continue - basically turn off Compatibility Mode during the ActiveWorkbook.save. But this is a nice workaround... I'd rather not.

    What I'd rather do is programatically turn off Compatibility Checking when my customer is using Excel 2007 to run my program.

    So first - determine if Excel 2007 is running.
    Second - turn off Compatibility Checking.

    Any hints on if this is possible and how?

    Thanks,

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    Personally, I am not using any code developed in earlier versions in 2007, without first checking it.

    You can check the version like this

    Please Login or Register  to view this content.
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Forum Contributor
    Join Date
    04-12-2006
    Location
    Morgan Hill CA
    Posts
    107
    Thanks - First part solved... determining when Excel 2007 is running.

    Second part still needs to be answered - turning OFF the Compatability Checker.

  4. #4
    Forum Contributor
    Join Date
    04-12-2006
    Location
    Morgan Hill CA
    Posts
    107
    Code for checking version is below. I have someone checking against an Excel 2000 system.

    Private Sub VersionCheck_Click()

    Dim excelVersion(12) As String
    Dim iVer As Integer

    excelVersion(7) = "95"
    excelVersion(8) = "97"
    excelVersion(9) = "2000"
    excelVersion(10) = "2002"
    excelVersion(11) = "2003"
    excelVersion(12) = "2007"

    iVer = 0

    On Error GoTo weDone

    'Attemp to create an Excel object
    Dim objExcel As Object
    Set objExcel = CreateObject("Excel.Application")

    'Retrieve the version
    iVer = objExcel.version

    'Destroy the object
    Set objExcel = Nothing


    weDone:
    If iVer < 7 Or iVer > 12 Then
    MsgBox "You are using an unsupported version of Excel."
    Else
    MsgBox "You are using Excel " + excelVersion(iVer) + "."
    End If


    End Sub
    Still looking for a way to turn off the COMPATIBILTY CHECKER programatically...
    Last edited by JWM6; 07-03-2007 at 12:02 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1