Hi,
every time I run this line of code :
I get this error:
{"The type initializer for 'CrystalDecisions.CrystalReports.Engine.ReportDocument' threw an exception."}
Which happens in the report code here
The weird thing is, every backup copy that previously worked now errors in this way so it is something I think I have done while trying to get ClickOnce to work.
I have even gone back to 4th backup copy from last week which was working fine then but now does not.
Please can someone help me to locate the problem?

every time I run this line of code :
VB.NET:
Dim repReport as new MyReport
I get this error:
{"The type initializer for 'CrystalDecisions.CrystalReports.Engine.ReportDocument' threw an exception."}
Which happens in the report code here
VB.NET:
[SIZE=2][/SIZE][SIZE=2][COLOR=#0000ff]Public[/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff]Sub[/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff]New[/COLOR][/SIZE][SIZE=2]()
[/SIZE][SIZE=2][COLOR=#0000ff] MyBase[/COLOR][/SIZE][SIZE=2].New
[/SIZE][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff]Sub
[/COLOR][/SIZE]
The weird thing is, every backup copy that previously worked now errors in this way so it is something I think I have done while trying to get ClickOnce to work.
I have even gone back to 4th backup copy from last week which was working fine then but now does not.
Please can someone help me to locate the problem?