Results 1 to 5 of 5
  1. #1
    MikeV is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Oct 2017
    Posts
    3

    Post Activex error - Microsoft Common Dialog Control (You don't have the license required....)

    Trying to insert the ActiveX control onto a form (Microsoft Common Dialog).

    Attached is what I am selecting and the error message I am receiving.

    I have added the file to references.
    I have turned trust center all the way down for activex controls.
    I have registered it on the pc (regsvr23).
    Ran windows update and it says everything is current.

    Still cannot get it to work.
    What am I missing?



    Click image for larger version. 

Name:	WCD.png 
Views:	9 
Size:	32.3 KB 
ID:	30965Click image for larger version. 

Name:	EM.png 
Views:	9 
Size:	26.6 KB 
ID:	30964

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,521
    skip the control, and just use the FileDialog code below:
    note, in VBE,tools, references : you must add reference to Microsoft Office 11.0 Object Library

    Code:
    Public Function UserPick1File(ByVal pvFilter, Optional pvPath)
    Dim strTable As String
    Dim strFilePath As String
    Dim sDialog As String, sDecr  As String, sExt As String
    
    
    getFilterTxt pvFilter, sDecr, sExt, sDialog
    If IsMissing(pvPath) Then pvPath = getMyDocs()
    
    
    
    
    With Application.FileDialog(msoFileDialogFilePicker)   'MUST ADD REFERENCE : Microsoft Office 11.0 Object Library
        .AllowMultiSelect = False
        .Title = "Locate a file to Import"
        .ButtonName = "Import"
        .Filters.Clear
        .Filters.Add sDecr, sExt
        .InitialFileName = pvPath
        .InitialView = msoFileDialogViewList    'msoFileDialogViewThumbnail
    
    
            If .show = 0 Then
               'There is a problem
               Exit Function
            End If
    
    
        'Save the first file selected
        UserPick1File = Trim(.SelectedItems(1))
    End With
    End Function

  3. #3
    MikeV is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Oct 2017
    Posts
    3
    Maybe I am way off base here.
    I am looking to add the mscomm control to access a serial port switch that I can then set what port is active via code.
    Do I have the wrong control?

  4. #4
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,521
    ok, no, you dont need CommonDialog to read serial ports. It can be done w just code.
    see:
    https://docs.microsoft.com/en-us/dot...m-serial-ports
    or
    https://www.mrexcel.com/forum/excel-...-com-port.html

  5. #5
    MikeV is offline Novice
    Windows 7 64bit Access 2013 64bit
    Join Date
    Oct 2017
    Posts
    3
    Thank you for the example. I can use it elsewhere I am sure.
    But I need to write to only for this application.
    Not read anything.
    How would I go about that?
    This is all in VBA.

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

Similar Threads

  1. loading an ActiveX control error
    By AeroProDrive in forum Access
    Replies: 3
    Last Post: 10-01-2014, 12:52 PM
  2. Replies: 1
    Last Post: 01-09-2011, 02:04 AM
  3. Replies: 5
    Last Post: 12-27-2010, 06:59 PM
  4. Replies: 4
    Last Post: 08-02-2010, 06:31 AM
  5. Common Dialog control / ShowOpen method
    By phuile in forum Forms
    Replies: 0
    Last Post: 04-10-2009, 12:16 AM

Tags for this Thread

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