So what are the undocumented SysCmd items?

In my previous posting I linked to Undocumented SysCmd Functions.  So I was curious and created my own code to go through the various SysCmds.   I came up with the following code.

Sub FindSysCmds()

Dim ReturnCode As Variant, i As Long
On Error GoTo tagError

‘ 1 through 13 are document in A2003
For i = 14 To 1024
    ‘ The following caused A2003 to crash
    If i = 602 Or i = 605 Or i = 606 Then _
        GoTo tagNextLoop
    ReturnCode = SysCmd(i)
    Debug.Print i & ” ” & ReturnCode
    If i > 605 Then
‘        Stop
‘        If i Mod 10 = 0 Then _
‘            MsgBox i
    End If
Next i
Exit Sub

    Select Case Err.Number
    Case 2439 ‘ The expression you entered has a function containing the wrong numb
        Debug.Print i & ” – wrong number of arguments.”
        Resume tagResume
    Case 7952 ‘ You made an illegal function call.
        Resume tagResume
    Case Else
    End Select
    Resume Next
End Sub

This code returned the following items.

14 – wrong number of arguments.
603 – wrong number of arguments.
604 – wrong number of arguments.
607 252
609 5912
610 – wrong number of arguments.
611 – wrong number of arguments.
612 – wrong number of arguments.
701 – wrong number of arguments.
710 0
711 67699721
713 – wrong number of arguments.
714 True
715 6566

Most of those are on Wayne’s list.   A few aren’t such as 14 and 713.   And his list hasn’t been updated as a few on his list appear to not work in Access 2003. 

Now I’m sure the folks at Microsoft are going to see the crash reports regarding codes 602, 605 and 606.   And I suspect a few on the Access team follow my blog.  So it’ll be interesting to see if I get any comments.

Anyhow I don’t have the time today to continue this research on what syscmd(14) does or which crash or don’t crash in other versions of Access.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>