• Moving from A2k to Access 2007 (12.0.6562.5005) SP2

    Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Moving from A2k to Access 2007 (12.0.6562.5005) SP2

    Author
    Topic
    #479389

    I’m starting to implement databases and code that have been working in Access 2000 through 2003 with
    Access 2007 (12.0.6562.5005) SP2

    Programmers worst nightmare, something that worked in an earlier version does not work the same way in a more current version

    Are there any notes/websites/papers available that reference any gotchas between Access 2000 and 2007?

    Thanks, John
    11397335

    Viewing 1 reply thread
    Author
    Replies
    • #1301364

      I don’t think there are any definitive lists, just postings here and there.

      What kind of problems are you having?

      • #1301368

        10/09/11

        Hi Mark

        No problems at the moment. But have stumbled across the following two problems:

        John

        This worked in 2000-2003, but errored in 2007
        Form, Event On Dbl Click =[lngIDJump]

        This worked in 2000-2003 & 2007
        Form, Event On Dbl Click =lngIDJump()

        Function lngIDJump() ‘ this is fired when user double clicks in any field

        Call lngID_DblClick(False)

        End Function

        ———————————-

        This worked in 2000-2003, but errored in 2007
        Public Function OpenReportToLastToFirstPagePreview2k(strRpt As String)

        Dim strPages As String
        Dim intLen As Integer
        Dim n As Integer

        DoCmd.OpenReport strRpt, acViewPreview
        ‘ Determine number of pages:
        strPages = CStr(Reports(strRpt).Pages)
        ‘ Specify Zoom percentage:
        DoCmd.RunCommand acCmdFitToWindow
        DoCmd.SelectObject acReport, strRpt
        ‘ Use SendKeys to select Navigation box Page number:

        SendKeys “{F5}”, True ‘select navigation box page number

        SendKeys strPages, True ‘last page number
        SendKeys “{ENTER}”, True ‘go last page

        ‘Pause 1 second, then go back to Page 1:
        Sleep 1000
        DoCmd.SelectObject acReport, strRpt

        SendKeys “{F5}”, True

        SendKeys “1”, True
        SendKeys “{ENTER}”, True
        SendKeys “%vzz” ‘ Alt v = Menu, z=Zoom, z = 100%

        End Function

        This worked in 2007

        Public Function OpenReportToLastToFirstPagePreview2007(strRpt As String)

        Dim strPages As String
        Dim intLen As Integer
        Dim n As Integer

        DoCmd.OpenReport strRpt, acViewPreview
        ‘ Determine number of pages:
        strPages = CStr(Reports(strRpt).Pages) ‘ save last page number
        ‘ Specify Zoom percentage:
        DoCmd.RunCommand acCmdFitToWindow
        DoCmd.SelectObject acReport, strRpt

        ‘Use SendKeys to select Navigation box Page number:

        SendKeys “%{F5}”, True ‘select navigation box page number
        SendKeys strPages, True ‘last page number
        SendKeys “{ENTER}”, True ‘go last page

        ‘Pause 2 second, then go back to Page 1:
        Sleep 2000
        DoCmd.SelectObject acReport, strRpt

        SendKeys “%{F5}”, True ‘select navigation box page number
        SendKeys “{BACKSPACE}”, True ’41 – clears 41 from box number
        SendKeys “{BACKSPACE}”, True ‘821 – clears 821 from box number, if over 9 checks
        SendKeys “{BACKSPACE}”, True ‘1251 – clears 1251 from box number if over 99 checks
        SendKeys “%{F5}”, True ‘select navigation box page number

        SendKeys “1”, True ‘set to page 1
        SendKeys “{ENTER}”, True ‘go to page 1

        SendKeys “%vzz” ‘ Alt v = Menu, z=Zoom, z = 100%

        End Function

        • #1301574

          What is the Declare statement for Sleep and where do you put it?

    • #1301370

      One of the most complete list of issues that I know of is Allen Browne’s Converting to Access 2007 or 2010.

    Viewing 1 reply thread
    Reply To: Moving from A2k to Access 2007 (12.0.6562.5005) SP2

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: