A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook - Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

The instruction at "0x7c82f8c7" referenced memory at "0x00000586".



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old February 2nd 07, 05:11 PM posted to microsoft.public.outlook.program_forms
mv
external usenet poster
 
Posts: 3
Default The instruction at "0x7c82f8c7" referenced memory at "0x00000586".

Error Message :The instruction at "0x7c82f8c7" referenced memory at
"0x00000586". . The memory could not be "read"

Platform: Windows 2003 server sp1, Visual Studio 2005 using VB (SP1)

I developed a simple appication in vb2005, using crystal reports
ReportDocument Object. The program running fine, in debug and release mode,
but when you close the program, the above error message appears. I use the
debug mode to trace the problem, understand that some memory leakage. So I
used the close and dispose methods of Reportdocument object in Form1_Disposed
event, but the program indefenitely waiting for something. So I commented
the statements in form1_Disposed event

The following is the code,

Imports CrystalDecisions.CrystalReports.Engine
Imports CrystalDecisions.Shared

Public Class Form1

Private northwindCustomersReport As ReportDocument


Private Sub ConfigureCrystalReports()
northwindCustomersReport = New ReportDocument()
Dim reportPath As String = Application.StartupPath & "\myReport.rpt"
northwindCustomersReport.Load(reportPath)
Dim myConnectionInfo As ConnectionInfo = New ConnectionInfo()
myConnectionInfo.ServerName = "myserver"
myConnectionInfo.DatabaseName = "myDatabase"
myConnectionInfo.IntegratedSecurity = True
SetDBLogonForReport(myConnectionInfo, northwindCustomersReport)
myCrystalReportViewer.ReportSource = northwindCustomersReport
End Sub

Private Sub SetDBLogonForReport(ByVal myConnectionInfo As
ConnectionInfo, ByVal myReportDocument As ReportDocument)
Dim myTables As Tables = myReportDocument.Database.Tables
For Each myTable As CrystalDecisions.CrystalReports.Engine.Table In
myTables
Dim myTableLogonInfo As TableLogOnInfo = myTable.LogOnInfo
myTableLogonInfo.ConnectionInfo = myConnectionInfo
myTable.ApplyLogOnInfo(myTableLogonInfo)
Next
End Sub

Private Sub Form1_Disposed(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Disposed
'If northwindCustomersReport IsNot Nothing Then
' northwindCustomersReport.Close()
'End If
GC.Collect()
End Sub


Private Sub Form1_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load
ConfigureCrystalReports()
End Sub
End Class



Ads
 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Include "Telecommuting" or "Teleworking" as a "Show time as" statu Gordon Greene Outlook - Calandaring 0 July 31st 06 03:37 PM
Cannot "Open" "Import/Export' or use "Data File Management" Ed Isenberg Outlook - Installation 3 July 16th 06 12:31 AM
Outlook "freezes" on "reply" when I set Word as my HTML editor? louis11 Outlook - Installation 0 May 12th 06 04:43 PM
Outlook express address book, "tools", "option" feature missing f. Brad Outlook - Using Contacts 3 March 11th 06 11:46 PM
Only when i forward emails with attachements "550 relaying mail to" [domain] "is not allowed" Alchemy Outlook - General Queries 4 March 8th 06 11:47 PM


All times are GMT +1. The time now is 04:11 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.