DNN Forums

Ask questions about your website to get help learning DNN and help resolve issues.

DnnImageHandler General Exception Error

 4 Replies
 1 Subscribed to this topic
 40 Subscribed to this forum
Sort:
Author
Messages
New Around Here
Posts: 3
New Around Here

DnnImageHandler doesn't work since I moved my website from my local server to a host. I have no Idea How to fix it. The Error occurs whenever DnnImageHandler calls a user's profile image or any other profile property of image type. No user images are shown. DnnImageHandler recurring Error:

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4075.0

DNN 9.4.1

AbsoluteURL:/DnnImageHandler.ashx

DefaultDataProvider:DotNetNuke.Data.SqlDataProvider, DotNetNuke

ExceptionGUID:d741bc90-73c2-4a85-af1c-d0f2e21547d4

AssemblyVersion:

 

ExceptionHash:7kgL5R6baI4X2Yh8vqcikOx2+Bs=

Message:Unhandled Error:

StackTrace:

InnerMessage:Parameter is not valid.

InnerStackTrace:

   at System.Drawing.Image.FromStream(Stream stream, Boolean useEmbeddedColorManagement, Boolean validateImageData)
   at DotNetNuke.Services.GeneratedImage.ImageHandlerInternal.GetImageThroughTransforms(Byte[] buffer)
   at DotNetNuke.Services.GeneratedImage.ImageHandlerInternal.HandleImageRequest(HttpContextBase context, Func`2 imageGenCallback, String uniqueIdStringSeed)
   at DotNetNuke.Services.GeneratedImage.ImageHandler.ProcessRequest(HttpContextBase context)
   at DotNetNuke.Services.GeneratedImage.ImageHandler.ProcessRequest(HttpContext context)
   at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step)
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

 

 

 

Veteran Member
Posts: 1182
Veteran Member
MVP
MVP
You're an MVP!

Did you check your web.config file if the image handler is added in the system.webServer/handlers section?

[add name="DnnImageHandler" 
    path="DnnImageHandler.ashx" 
    verb="*" 
    type="DotNetNuke.Services.GeneratedImage.DnnImageHandler, DotNetNuke"
    preCondition="integratedMode" /]

(replace [ by < and ] by >)

Happy DNNing!
Michael

Michael Tobisch
DNN★MVP

DNN Connect
New Around Here
Posts: 3
New Around Here

Yes, I have the following lines in Web.config file:

[add key="DnnImageHandler" value="EnableServerCache=false;" /]

[add name="DnnImageHandler" path="DnnImageHandler.ashx" verb="*" type="DotNetNuke.Services.GeneratedImage.DnnImageHandler, DotNetNuke" preCondition="integratedMode" /]
   

 

 

New Around Here
Posts: 3
New Around Here

Problem solved. I contacted the server administrator. Apparently "Enable 32-bit applications" was enabled in the IIS configuration. Disabling it solved the issue.

Veteran Member
Posts: 1182
Veteran Member
MVP
MVP
You're an MVP!
Great - thanks for sharing!

Happy DNNing!
Michael

Michael Tobisch
DNN★MVP

DNN Connect

These Forums are for the discussion of the open source CMS DNN platform and ecosystem.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. If you have (suspected) security issues, please DO NOT post them in the forums but instead follow the official DNN security policy
  2. No Advertising. This includes the promotion of commercial and non-commercial products or services which are not directly related to DNN.
  3. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  4. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  5. No Flaming or Trolling.
  6. No Profanity, Racism, or Prejudice.
  7. Site Moderators have the final word on approving / removing a thread or post or comment.
  8. English language posting only, please.

Would you like to help us?

Awesome! Simply post in the forums using the link below and we'll get you started.

Get Involved