?
Solved

MsComm32

Posted on 1997-12-13
9
Medium Priority
?
808 Views
Last Modified: 2008-02-01
Did anyone know the us of mscomm32.ocx in access97.
How do i initalisize this ocx?
Dim oCom1 As ????
Set oCom1 = ????
If have the ocx-file, but there's alos a file called "comm96.hlp", fomerly shipped by Microsoft.
0
Comment
Question by:JochenKramer
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 3
9 Comments
 
LVL 4

Accepted Solution

by:
ozphil earned 400 total points
ID: 1962259
if you insert the ocx, you can use it without any vba initialisation.

insert/activex control and select 'microsoft communications control version 5.0'.

give the name of control a sensible name like oCom1 and you can use its properties and methods as you would any other control.
0
 
LVL 4

Expert Comment

by:ozphil
ID: 1962260
You can also refer to object without inserting ocx in a form.

To include the mscomm32.ocx library references, make sure you  viwinf any module in desing mode and do tools/references/ and check 'Micorsoft Comm Control 5.0'. if its not in the list, browse for it in c:\windows\system\mscomm.ocx.

MSComm is the name of the comms object class.


You can code like this:
Sub comms()
Dim i As Integer
Dim oCom As New MSComm
i = oCom.CommPort
Set oCom = Nothing
End Sub



0
 
LVL 4

Expert Comment

by:ozphil
ID: 1962261
If you desire further elaboration please provide a comment.
0
Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

 

Author Comment

by:JochenKramer
ID: 1962262
Hi,
thanks for your answer, but i have still problems

i entered the your code and get error
"cannot create object from activex"

mscomm32 is registered by regsvr32
in access it is in the object-catalog and a testprogramm for listing references shows me the name of the library and the version (1.1)
Whats wrong now?
Do i need other files or dlls?

Greetings
Jochen

0
 
LVL 4

Expert Comment

by:ozphil
ID: 1962263
You havent quite installed this animal's activeX and references.

I have reproduced your error by removing the activeX/references installation.

I did not register using regsvr32.

For activeX registration please do following via Access 97 module design mode:
tools/activeX controls.../Register/navigate to mscomm32.ocx and OK it. it should now register. You should then see' Microsoft Communications Control, version 5.0' in list.

For References registration please do following via Access 97 module design mode:
tools/references/browse/navigate to mscomm32.ocx and OK it.
You should then see' Microsoft Comm control 5.0' in list. If at beginning you see 'MISSING:Microsoft Comm control 5.0', uncheck it, OK it, and repeat registration.

If you follow the above two procedures the code willl work.

0
 

Author Comment

by:JochenKramer
ID: 1962264
Sorry, but it did't work.
I made a proc for testing the references like this:

Sub ShowMeAll()
Dim ref As Reference
For Each ref In References
    If ref.IsBroken = False Then
        Debug.Print "Name: ", ref.Name
        Debug.Print "Fullpath: ", ref.FullPath
        Debug.Print "Version: ", ref.Major & "." & ref.Minor
    Else
        Debug.Print "Verweis ist ungültig: ", ref.Guid    
    End If
Next ref        
End Sub
Output (last two)
Name:         Msacal20
Fullpath:     D:\WINPROGS.16\ACCESS20\ADT\MSACAL20.OCX
Version:      1.0
Name:         MSCommLib
Fullpath:     C:\WINNT\system32\mscomm32.ocx
Version:      1.1

i think the ocx is active in access, but i have still the same error message "cannot create object from activex"

What can i do now? Is there a difference between the american  and my german access version?
Thank you for your help
Jochen
0
 
LVL 4

Expert Comment

by:ozphil
ID: 1962265
Is the activeX installed also via tools/activeX controls.

the error message can appear if supporting dlls are incorrect.

this type of error is a real pain.

By the way  im running win95.
0
 

Author Comment

by:JochenKramer
ID: 1962266
It's also installed by tools/activeX Controls
Im running win95 too with same problems.
Which dlls i need too, i think i have only mscomm32.ocx
0
 
LVL 4

Expert Comment

by:ozphil
ID: 1962267
who knows.

i found this file mscomm32.dep in system directory, look at contents below and see if you can work out what your country dependency is and whats missing. good luck.

contents of mscomm32.dep:
--------------------------------------------

; Dependency file for setup wizards.

[Version]
Version=5.0.37.14

; Dependencies for MSComm32.ocx

; Default Dependencies ----------------------------------------------

[MSComm32.ocx]
Dest=$(WinSysPath)
Register=$(DLLSelfRegister)
Version=5.0.37.14
Uses1=ComCat.dll
Uses2=
CABFileName=MSComm32.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComm32.inf

[ComCat.dll]
Dest=$(WinSysPathSysFile)
Register=$(DLLSelfRegister)
Uses1=

; Localized Dependencies --------------------------------------------

; ** German (DE) ***
; (0007 = German)
;
[MSComm32.ocx <0007>]
Uses1=MSComDE.dll
Uses2=

[MSComDE.dll <0007>]
Uses1=
CABFileName=MSComDE.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComDE.inf

; ** French (FR) ***
; (000C = French)
;
[MSComm32.ocx <000C>]
Uses1=MSComFR.dll
Uses2=

[MSComFR.dll <000C>]
Uses1=
CABFileName=MSComFR.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComFR.inf

; ** Italian (IT) ***
; (0010 = Italian)
;
[MSComm32.ocx <0010>]
Uses1=MSComIT.dll
Uses2=

[MSComIT.dll <0010>]
Uses1=
CABFileName=MSComIT.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComIT.inf

; ** Spanish (ES) ***
; (000A = Spanish)
;
[MSComm32.ocx <000A>]
Uses1=MSComES.dll
Uses2=

[MSComES.dll <000A>]
Uses1=
CABFileName=MSComES.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComES.inf

; ** Japanese (JP) ***
; (0011 = Japanese)
;
[MSComm32.ocx <0011>]
Uses1=MSComJP.dll
Uses2=

[MSComJP.dll <0011>]
Uses1=
CABFileName=MSComJP.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComJP.inf

; ** Korean (KO) ***
; (0012 = Korean)
;
[MSComm32.ocx <0012>]
Uses1=MSComKO.dll
Uses2=

[MSComKO.dll <0012>]
Uses1=
CABFileName=MSComKO.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComKO.inf

; ** Chinese Traditional (CHT) ***
; (0404 = Chinese Traditional)
;
[MSComm32.ocx <0404>]
Uses1=MSComCHT.dll
Uses2=

[MSComCHT.dll <0404>]
Uses1=
CABFileName=MSComCHT.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComCHT.inf

; ** Chinese Simplified (CHS) ***
; (0804 = Chinese Simplified)
;
[MSComm32.ocx <0804>]
Uses1=MSComCHS.dll
Uses2=

[MSComCHS.dll <0804>]
Uses1=
CABFileName=MSComCHS.cab
CABDefaultURL=http://activex.microsoft.com/controls/vb5
CABINFFile=MSComCHS.inf
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
It’s the first day of March, the weather is starting to warm up and the excitement of the upcoming St. Patrick’s Day holiday can be felt throughout the world.
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question