| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1575 人关注过本帖
标题:求助提示错误框:tellme当前提供程序不支持"索引"功能的界面
只看楼主 加入收藏
xjb_test
Rank: 1
等 级:新手上路
帖 子:5
专家分:0
注 册:2012-5-18
收藏
 问题点数:0 回复次数:0 
求助提示错误框:tellme当前提供程序不支持"索引"功能的界面
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
   '点击时自动打开相应的功能,相应的功能 已经保存在项目的lbItemCargo属性中
    If Not IsNull(ctExplorer1.lbItemCargo(nList, nItem)) Then
       mdl = ctExplorer1.lbItemCargo(nList, nItem)
       '调用openCmd打开相应功能(窗体或报表或函数)
       OpenCmd mdl
       Exit Sub
    End If
End With

    Exit Sub
TC_Err:
    glMessageBox "错误:" & Err.Description
    Exit Sub
End Sub

'根据参数打开对应的窗体/报表/函数
Public Sub OpenCmd(mdl As String)
On Error GoTo OC_Err

   Dim Rs As ADODB.Recordset, func As String
   Dim Stemps As String
   Dim cn As ADODB.Connection
   DoCmd.Hourglass False
   Set Rs = New ADODB.Recordset
   Set cn = Application.CurrentProject.Connection
   Stemps = "select * from tblZstmProgItem"
   Rs.Open Stemps, cn, adOpenKeyset, adLockOptimistic
   Rs.Index = "ModuleID"

   Rs.Seek "=", mdl
   
   If DCount("func", "tblSysRightUserRight", "uname='" & LogUser & "' and func='" & mdl & "'") = 0 Then
      glMessageBox "你没有权限使用这个功能!"
      Exit Sub
   End If

   If Not IsNull(Rs!Form) Then

      gOpenForm Rs!FInModule, Rs!Form
      'DoCmd.OpenForm rs!Form
      Exit Sub
   Else
      glMessageBox "此功能不存在,或是演示版!"
      Exit Sub
   End If
   If Not IsNull(Rs!Qry) Then
      gOpenQuery Rs!FInModule, Rs!Qry
      'DoCmd.OpenQuery rs!Qry
      Exit Sub
    Else
      glMessageBox "此功能不存在,或是演示版!"
      Exit Sub
   End If

   If Not IsNull(Rs!func) Then
      func = Rs!func & "()"
      UnUsed = Eval(func)
      Exit Sub
    Else
      glMessageBox "此功能不存在,或是演示版!"
      Exit Sub
   End If
   Exit Sub
OC_Err:
   glMessageBox "tellme" & Err.Description
   Exit Sub
End Sub

搜索更多相关主题的帖子: tellme 项目 
2012-05-18 15:12
快速回复:求助提示错误框:tellme当前提供程序不支持"索引"功能的界面
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.018863 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved