Page 1 of 1

Windows Vista Problem

Posted: Sun May 15, 2011 12:46 am
by alharbi
hi

after we moved from windows XP to Windows Vista we facing this Error in All Our report Pages
[FileNotFoundException: تعذر تحميل الملف أو التجميع 'System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' أو أحد التبعيات الخاصة به. ‏‏يتعذر على النظام العثور على الملف المحدد.]
Reports.MgrApprove.InitializeComponent() +0
Reports.MgrApprove..ctor() +19

[TargetInvocationException: تم طرح استثناء بواسطة هدف استدعاء.]
System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandle& ctor, Boolean& bNeedSecurityCheck) +0
System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean fillCache) +86
System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache) +230
System.Activator.CreateInstance(Type type, Boolean nonPublic) +67
Stimulsoft.Base.StiActivator.CreateObject(Type type) +13
Stimulsoft.Report.StiReport.GetReportsFromAssembly(Assembly assembly) +263
Stimulsoft.Report.StiReport.GetReportFromAssembly(Stream assemblyStream) +218
Stimulsoft.Report.StiReport.GetReportFromAssembly(String assemblyFile, Boolean lockFile) +290
Stimulsoft.Report.StiReport.GetReportFromAssembly(String assemblyFile) +27
HRIS.mgrapprove.Page_Load(Object sender, EventArgs e) in C:\Special\Human Resurce Information System\HRIES\HRIES\rpt\mgrapprove.aspx.cs:97
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +50
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627
the error accure in this point
StiReport report = StiReport.GetReportFromAssembly(sFullFileName);
how we can solve this problem ?

Windows Vista Problem

Posted: Sun May 15, 2011 4:37 am
by Martin Hart Turner
Do you have .NET 4 installed on this computer?

Windows Vista does not come with version 4 installed, and it looks like the report is looking for this version.

HTH,
Martin.

Windows Vista Problem

Posted: Sun May 15, 2011 5:46 am
by alharbi
thank you,

i will install .Net 4 and reply the result .

Windows Vista Problem

Posted: Sun May 15, 2011 9:36 am
by Andrew
Hello,

Ok! Let us know about the results.

Windows Vista Problem

Posted: Mon May 16, 2011 12:13 am
by alharbi
i have installed .net 4 but the error still occurs!

Windows Vista Problem

Posted: Mon May 16, 2011 3:29 am
by Ivan
Hello,

This error occurs because due to mismatch of versions of the .NET Framework.
This error appears if an application, compiled under one version of the .NET Framework, attempts to load a report from an assembly that is compiled under another version of the .NET Framework.

For example, by default, our designer is launched under the latest version of the installed Framework and assembly of the report is saved in this version.
If your application uses a different version of the .NET Framework, then you must save the report under the same version.
To do this, you can adjust the "Designer.exe.config" file: for example, for Net 2.0 please open the "Designer.exe.config" file and delete lines with "v3.0", "v3.5" and "v4.0", then the designer should start with. Net 2.0.

Thank you.

Windows Vista Problem

Posted: Mon May 16, 2011 3:49 am
by alharbi
Thank You

the problem was solved by your solution.

thank you againe


Windows Vista Problem

Posted: Mon May 16, 2011 6:12 am
by Alex K.
Hello,

Ok.
Let us know if you need any additional help.