rio
Registered User.
- Local time
- Tomorrow, 05:57
- Joined
- Jun 3, 2008
- Messages
- 124
hi.
I need some help with my database. here the problem:
1. I can't save all the graph for all record (StnName) by one click button cmd2PS01.
here the code
2. After i click the button, this error come out :
here I attach with the database.... can some one help me.!!!! please!!!
View attachment Save Graph As Jpeg.zip
I need some help with my database. here the problem:
1. I can't save all the graph for all record (StnName) by one click button cmd2PS01.
here the code
Code:
Private Sub cmd2PS01_Click()
Dim objChart As Object
Dim strDate As String
Dim strFolder As String
strDate = Format(Now(), "dd mmmm yyyy")
strFolder = "StnInfo" & " (" & strDate & ")"
MkDir (CurrentProject.Path & "\" & strFolder)
Set objChart = Me.Graph8.Object
Me.Graph8.Object.Export Filename:=(CurrentProject.Path & "\" & strFolder) & "\" & "GraphDO (" & StnName & ")" & ".jpg"
Me.Graph8.Locked = False
Me.Graph8.Enabled = True
Set objChart = Nothing
DoCmd.Close acForm, "Form1", acSaveNo
DoEvents
End Sub
2. After i click the button, this error come out :
The operation on the Chart object failed.
The OLE server may not be registered.
To register the OLE server, reinstall it.
here I attach with the database.... can some one help me.!!!! please!!!
View attachment Save Graph As Jpeg.zip