ActiveReports Developers 7 Now Available in Beta!! (click for details)

ActiveReports 6 Support

Started by pfalcon at 03-11-2010 9:23 AM. Topic has 5 replies.

Print Search Rate
Sort Posts:    
   03-11-2010, 9:23 AM
pfalcon is not online. Last active: 2/27/2012 2:55:12 PM pfalcon

Top 500 Posts
Joined on 08-29-2004
Mellbourne, Australia
Posts 43
Problems running in Medium trust

Attachment: configPF.zip
I am trying to get a report working in my web application, which must run under a medium trust hosted environment. It works in the development environment, but when I deploy to my test server (using config files supplied by my host which simulate their host), I get the following crash when trying to use the PDF viewer.

What is wrong here? I've attached the config arrangement in use - I have little choice over this - though obviously my one has a lot of other custom controls being used - but its unlikely these are conflicting with the report? The report is a simple code behind that retrieves data using unbound code/events.

Security Exception

Description: The application attempted to perform an operation not allowed by the security policy.  To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.

Exception Details: System.Security.SecurityException: Request failed.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[SecurityException: Request failed.]
System.Reflection.CustomAttribute._CreateCaObject(Void* pModule, Void* pCtor, Byte** ppBlob, Byte* pEndBlob, Int32* pcNamedArgs) +0
System.Reflection.CustomAttribute.CreateCaObject(Module module, RuntimeMethodHandle ctor, IntPtr& blob, IntPtr blobEnd, Int32& namedArgs) +63
System.Reflection.CustomAttribute.GetCustomAttributes(Module decoratedModule, Int32 decoratedMetadataToken, Int32 pcaCount, RuntimeType attributeFilterType, Boolean mustBeInheritable, IList derivedAttributes) +604
System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeType type, RuntimeType caType, Boolean inherit) +129
System.RuntimeType.GetCustomAttributes(Type attributeType, Boolean inherit) +65
System.ComponentModel.ReflectTypeDescriptionProvider.ReflectGetAttributes(Type type) +133
System.ComponentModel.ReflectedTypeData.GetAttributes() +583
System.ComponentModel.DefaultTypeDescriptor.System.ComponentModel.ICustomTypeDescriptor.GetAttributes() +58
System.ComponentModel.TypeDescriptor.GetAttributes(Type componentType) +32
System.ComponentModel.ReflectedTypeData.GetConverter(Object instance) +95
System.ComponentModel.ReflectTypeDescriptionProvider.GetConverter(Type type, Object instance) +24
System.ComponentModel.DefaultTypeDescriptor.System.ComponentModel.ICustomTypeDescriptor.GetConverter() +50
System.ComponentModel.TypeDescriptor.GetConverter(Type type) +23
System.ComponentModel.PropertyDescriptor.get_Converter() +112
System.Web.Compilation.CodeDomUtility.GenerateExpressionForValue(PropertyInfo propertyInfo, Object value, Type valueType) +362
System.Web.UI.SimplePropertyEntry.GetCodeStatement(BaseTemplateCodeDomTreeGenerator generator, CodeExpression ctrlRefExpr) +125
System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildBuildMethodInternal(ControlBuilder builder, Type ctrlType, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse, CodeStatementCollection statements, Boolean fStandardControl, Boolean fControlFieldDeclared, String deviceFilter, Boolean fControlSkin) +2407
System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildBuildMethod(ControlBuilder builder, Boolean fTemplate, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse, Boolean fControlSkin) +536
System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) +1187
System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) +1051
System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) +552
System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) +552
System.Web.Compilation.TemplateControlCodeDomTreeGenerator.BuildMiscClassMembers() +61
System.Web.Compilation.PageCodeDomTreeGenerator.BuildMiscClassMembers() +12
System.Web.Compilation.BaseCodeDomTreeGenerator.BuildSourceDataTree() +920
System.Web.Compilation.BaseCodeDomTreeGenerator.GetCodeDomTree(CodeDomProvider codeDomProvider, StringResourceBuilder stringResourceBuilder, VirtualPath virtualPath) +45
System.Web.Compilation.BaseTemplateBuildProvider.GenerateCode(AssemblyBuilder assemblyBuilder) +102
System.Web.Compilation.AssemblyBuilder.AddBuildProvider(BuildProvider buildProvider) +99




   Report 
   03-11-2010, 11:08 AM
pfalcon is not online. Last active: 2/27/2012 2:55:12 PM pfalcon

Top 500 Posts
Joined on 08-29-2004
Mellbourne, Australia
Posts 43
Re: Problems running in Medium trust
I tried to get the Professional Web example app working in Medium trust (seriously guys - if you really support Medium trust, why can't you own sample apps just cpmpile when the switch is thrown in  web.config??)

I removed the code that wouldn't permit a compile, and relocated the NWind.mdb file to App_Data. I get pretty much the same error on WebControl.aspx, this time with more detail: This isn't helping me that the sample code provided won't work with medium trust - have you got a sample web application that DOES - if so please provide it?? I am in the middle of a critcal development, and based my decisions on the announcement that the latest patch WAS compliant with medium trust environments.

Stack Trace:

[SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
#jre.#ire.#Sre(String receipt) +446
#jre.#ire.#3re(String receipt, OutputFormat outputFormat, String pageRange, Object exportObj, Int32& pageCount, HttpContext context, Object instance) +70
DataDynamics.ActiveReports.Web.WebViewer.#Ore(HtmlTextWriter output) +316
DataDynamics.ActiveReports.Web.WebViewer.RenderChildren(HtmlTextWriter output) +729
System.Web.UI.WebControls.WebControl.RenderContents(HtmlTextWriter writer) +10
System.Web.UI.WebControls.WebControl.Render(HtmlTextWriter writer) +32
System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +27
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +99
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +25
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +134
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +19
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer) +163
System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) +32
System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output) +51
System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +27
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +99
System.Web.UI.HtmlControls.HtmlForm.RenderControl(HtmlTextWriter writer) +40
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +134
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +19
System.Web.UI.Page.Render(HtmlTextWriter writer) +29
System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +27
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +99
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +25
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +6785
System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +242
System.Web.UI.Page.ProcessRequest() +80
System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +21
System.Web.UI.Page.ProcessRequest(HttpContext context) +49
ASP.webcontrol_aspx.ProcessRequest(HttpContext context) +50
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +181
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75


   Report 
   03-12-2010, 12:49 PM
AashishB is not online. Last active: 12/24/2010 3:51:14 PM AashishB

Top 25 Posts
Joined on 12-11-2008
Posts 818
Re: Problems running in Medium trust
pfalcon,

which build of Active Reports 6 do you use? Medium Trust supported was provided from build 6.0.2250.0. It is available for download here.
I would also suggest you to take a look at this link which tells you which features are not supported on Medium Trust.
I have also emailed you a sample which you can deploy on your sever to test flash viewer and PdfExport.

If you have more questions, please feel free to ask.

Regards,
Aashish


   Report 
   03-12-2010, 3:05 PM
pfalcon is not online. Last active: 2/27/2012 2:55:12 PM pfalcon

Top 500 Posts
Joined on 08-29-2004
Mellbourne, Australia
Posts 43
Re: Problems running in Medium trust
Just an FYI for anyone following this thread, The Data Dynamics support staff provided me a test app for Medium Trust, and have confirmed that an additional PrintingPermissions problem has been resolved, but is still undergoing internal testing. I've been able to locate the problem with my app (one of those silly things that you don't spot until you have a working example to compare with...sigh. I think I got the Assembly references in web.config wrong).

Aashish, would it be possible for a variation on the sample Medium Trust App you provided to be put in the next live release? I think this would go a long way to resolving issues.

   Report 
   03-15-2010, 3:18 PM
AashishB is not online. Last active: 12/24/2010 3:51:14 PM AashishB

Top 25 Posts
Joined on 12-11-2008
Posts 818
Re: Problems running in Medium trust
From your last email, it looks like you would be able to run on medium trust with the interim build after configuring HTTP handlers.

The sample application I sent you was a simple web application, as long as the unsupported features are not used in Medium Trust, the webapplication will run fine.

Regards,
Aashish

   Report 
   03-17-2010, 7:48 AM
SankalpS is not online. Last active: 3/30/2012 11:17:34 PM SankalpS

Top 10 Posts
Joined on 12-11-2008
Posts 2,587

DDStaff
Re: Problems running in Medium trust
pfalcon,

I have opened a new Feature Request Case 144143 which has been opened to add a sample application demonstrating how ActiveReports 6 works in medium trust environment. I have also added your E-mail address to the list of affected users for this case. You will be notified once this case gets implemented.

Regards,
Sankalp

Sankalp Sen
GrapeCity- DataDynamics
   Report 
GrapeCity » Product Support » ActiveReports 6... » Re: Problems running in Medium trust

Privacy Policy | Copyright © 1997-2012 — GrapeCity, inc.
All trademarks mentioned are the property of their respective owners.