Results 1 to 2 of 2
  1. #1
    jansonfly is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2012
    Posts
    1

    Question (It does not support ‘”index”interface function ,)please give the directions.

    I used access+sql2000. It will be appear to administer the code, (It does not support ‘”index”interface function ,)please give the directions.
    Private Sub ctExplorer1_lbItemClick(ByVal nList As Integer, ByVal nItem As Integer)
    On Error GoTo TC_Err
    Dim func As String, mdl As String
    With ctExplorer1

    //when we clicked, The corresponding function will be opend automatically,and it has been already saved in the project in the ilbem cargo attribute.
    If Not IsNull(ctExplorer1.lbItemCargo(nList, nItem)) Then
    mdl = ctExplorer1.lbItemCargo(nList, nItem)
    // calls the open cmd to open the corresponding function (function of the form or repor)


    OpenCmd mdl
    Exit Sub
    End If
    End With
    Exit Sub
    TC_Err:
    glMessageBox "mistake:" & Err.Description
    Exit Sub
    End Sub

    //According to the parameters,open corresponding the form or function or report.
    Public Sub OpenCmd(mdl As String)
    On Error GoTo OC_Err
    Dim rs As New ADODB.Recordset
    Dim conn As New ADODB.Connection
    Dim func As String
    Dim strsql As String
    Set conn = CurrentProject.Connection
    strsql = "select * from tblProgItem"
    rs.Open strsql, conn, adOpenStatic, adLockReadOnly
    rs.Index = "ModuleID"
    rs.Seek "=", mdl
    If DCount("func", "tblSysRightUserRight", "uname='" & LogUser & "' and func='" & mdl & "'") = 0 Then
    glMessageBox "You do not have permission to use this function "
    Exit Sub
    End If
    Exit Sub
    OC_Err:
    glMessageBox "tellme" & Err.Description
    Exit Sub
    End Sub

  2. #2
    Rawb is offline Expert
    Windows XP Access 2000
    Join Date
    Dec 2009
    Location
    Somewhere
    Posts
    875
    What is lbItemCargo()?

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 3
    Last Post: 05-16-2012, 10:20 AM
  2. DB will not give Unique ID's
    By DICKBUTTONS in forum Access
    Replies: 1
    Last Post: 02-07-2012, 02:12 PM
  3. Should I give Up on This Form?
    By Palomino33 in forum Forms
    Replies: 25
    Last Post: 11-09-2011, 05:37 AM
  4. Replies: 3
    Last Post: 10-13-2011, 08:40 AM
  5. Replies: 3
    Last Post: 06-22-2011, 01:59 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums