MS-Access application distribution with chart control

promod33

New member
Local time
Tomorrow, 01:51
Joined
Mar 26, 2006
Messages
7
I am developing a MS-Access stand alone application using MS-Access 2003,
which requires chart to be displayed. I can see chart control (
'MSCHRT20.OCX') available in MS-Access. I have used it sucessfully and
displayed the chart. Now, I want to distribute this application.

My question is :

1) Is this chart control ( 'MSCHRT20.OCX') part of MS-Access 2003
installtion ?

2) I have given some users to try out the application and they are getting
message while running the application - "Missing OCX file ( 'MSCHRT20.OCX')"
!!

What is the solution to it ?

3) In VB6, I can create installation file where I can include these OCX
files. Is there similar facility available in MS-Access 2003 ?

Thanks.
 
I am using the code mentioned below in open event of startup form. This code establish refrence with ReportSpecs and MSComCtl2.ocx kept in same folder.

Try to edit and use this code as per your requirement.

Dim refSpec, refOCX, RefDelete, Ref As Reference
Dim strRepSpecPath, StrComCtlPath As String

For Each Ref In Application.References
If Ref.Name = "ReportSpecs" Then
Set RefDelete = Application.References(Ref.Name)
Application.References.Remove RefDelete
ElseIf Ref.Name = "MSComCtl2" Then
Set RefDelete = Application.References(Ref.Name)
Application.References.Remove RefDelete
End If

Next Ref

strRepSpecPath = Application.CurrentProject.Path & "\A2K2ReportSpecs.mde"
StrComCtlPath = Application.CurrentProject.Path & "\MSCOMCT2.OCX"
Set refSpec = Application.References.AddFromFile(strRepSpecPath)
Set refOCX = Application.References.AddFromFile(StrComCtlPath)
 

Users who are viewing this thread

Back
Top Bottom