Results 1 to 21 of 21

Search through database and display results in userform

Threaded View

karthikcoep Search through database and... 01-17-2009, 01:33 PM
Leith Ross Hello karthikcoep, You can... 01-18-2009, 05:01 AM
MickG Hi, I can't compete with... 01-18-2009, 08:55 AM
lyzieaa_mkj88 Search & Display records on... 08-18-2011, 04:21 AM
royUK See the database form example... 01-18-2009, 03:07 PM
Leith Ross Hello karthikcoep, If you... 01-18-2009, 04:51 PM
karthikcoep Thank to everyone 01-20-2009, 11:10 AM
karthikcoep Sorry need some change 01-22-2009, 02:48 PM
Leith Ross Hello karthikcoep, I have... 01-22-2009, 09:24 PM
karthikcoep Need this for a particular... 01-23-2009, 02:30 PM
Leith Ross Hello karthikcoep, I have... 01-23-2009, 04:37 PM
karthikcoep NOt working 01-24-2009, 04:19 AM
Leith Ross Hello karthikcoep, The... 01-24-2009, 05:14 AM
karthikcoep Re: Search through database... 01-29-2009, 02:42 AM
sick stigma Re: Search through database... 01-29-2009, 11:22 AM
dmanatee Re: Search through database... 07-09-2010, 04:52 PM
Leith Ross Re: Search through database... 07-09-2010, 05:49 PM
bari Re: Search through database... 10-11-2011, 04:59 AM
arthurbr Re: Search through database... 10-11-2011, 05:10 AM
gkaty28 Re: Search through database... 05-24-2012, 04:10 AM
arlu1201 Re: Search through database... 05-24-2012, 05:08 AM
  1. #13
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259
    Hello karthikcoep,

    The problem is the reference library isn't loaded on the other machines. The workbook I posted has the reference saved. I have added a macro that will automatically load the library reference when the workbook is opened. Here is the auto loading macro which is called by the Workbook_Open() event procedure. This macro is located in Module1.
    Sub AddListViewControl()
    
      Dim P As Variant
      Dim Paths As Variant
      Dim RefFile As String
      Dim X As String
      
        RefFile = "MSCOMCTL.OCX"
        
        Paths = Split(Environ("Path"), ";")
          For Each P In Paths
            X = Dir(P & "\" & RefFile)
            If X = RefFile Then Exit For
          Next P
      
          If X = "" Then
             MsgBox "The directory for " & RefFile & " could not be found."
             Exit Sub
          Else
             RefFile = P & "\" & RefFile
          End If
          
        On Error Resume Next
          Application.VBE.ActiveVBProject.References.AddFromFIle RefFile
          If Err = 0 Or Err = 32813 Then Err.Clear
        On Error GoTo 0
      
    End Sub
    Workbook Open Event - ThisWorkbook Module
    Private Sub Workbook_Open()
      Call AddListViewControl
    End Sub
    Sincerely,
    Leith Ross
    Attached Files Attached Files

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