|
-
March 29th, 2007, 07:13 PM
#1
saving an image file
I have written an aspx web app which generates a bitmap and then saves it to the images folder. The app works fine when I run it within VS 2005. When I browse to the application using a web url, I get a "Generic error occured in GDI+ when it tries to save the file. The line of code is
Code:
imgPath = Server.MapPath("~/images/Brot.bmp")
<snip>
PlotBmp(bmp, siz, rectD, 2, imax)
bmp.save(imgPath) '<--Error occurs here.
-
March 30th, 2007, 11:40 AM
#2
Re: saving an image file
have you checked permissions on the /images folder. Making sure the ASP.NET Worker process Or the IUSR Machine account actually has permissions to save the file to this folder.
A Generic GDI+ error generally means you dont have permissions to write to that folder.
hth,
mcm
rate my posts!
mcm
-
April 2nd, 2007, 11:41 AM
#3
Re: saving an image file
What exactly should I check for? I think the settings are the same on on another computer where it actually works.
-
April 2nd, 2007, 11:48 AM
#4
Re: saving an image file
check the permissions on the folder where you are storing the images. Make sure your IUSR_MACHINENAME or ASPNET worker process has sufficient rights to write to that folder.
hth,
mcm
rate my posts!
mcm
-
April 9th, 2007, 10:24 AM
#5
Re: saving an image file
I've tried giving all kinds of permissions, but it still doesn't work.
-
April 9th, 2007, 10:32 AM
#6
Re: saving an image file
 Originally Posted by bsaucer
I've tried giving all kinds of permissions, but it still doesn't work.
Your answer is hardly enough for me to help you. One line answers are not going to yield you much help. How about some specifics regarding your infastructure, the code your using, the ACTUAL permissions you have tried, etc. We are offering help but we are not mind readers, "All kinds of permissions" tells me absolutly nothing.
mcm
rate my posts!
mcm
-
April 9th, 2007, 10:48 AM
#7
Re: saving an image file
Also post the IIS settings for the site. Specifically the identity of the application pool that is hosting your application.
The version of windows also matters.....
TheCPUWizard is a registered trademark, all rights reserved. (If this post was helpful, please RATE it!)
2008, 2009,2010
In theory, there is no difference between theory and practice; in practice there is.
* Join the fight, refuse to respond to posts that contain code outside of [code] ... [/code] tags. See here for instructions 
* How NOT to post a question here
* Of course you read this carefully before you posted
* Need homework help? Read this first
-
April 20th, 2007, 09:27 AM
#8
Re: saving an image file
Now that I got it working in XP Pro, how do I get it working in Vista?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|