Wrox Programmer Forums
|
ASP.NET 3.5 Basics If you are new to ASP or ASP.NET programming with version 3.5, this is the forum to begin asking questions. Please also see the Visual Web Developer 2008 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 3.5 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 14th, 2008, 07:09 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default Upload prbolem

Hello all
I try to have an uplaod form wich uplaods pdf files on my site.I want to use this form on our LAN and the program will be run on my computer(my computer will be the server). I test my upload page on my computer and it is working but other users can't upload any pdf files.my programes are in:C:\inetpub\wwwroot\1\forms
and pdf files should be uploaded to : C:\inetpub\wwwroot\1\ITP
but when users want to upload they recive error:file not found.
my code for form is a below:
<form id="form1" runat="server" method=post enctype="multipart/form-data">
 <asp:FileUpload ID="FileUpload1" runat="server"/>
 <asp:Button ID="Insert" runat="server" Text="Insert" />
 Protected Sub Insert_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Insert.Click
        Dim s1 As String
            s1 = "C:\inetpub\wwwroot\1\ITP\" + Documenttxt.Text + ".pdf"
            FileUpload1.PostedFile.SaveAs(s1)
Would you please help me to solve my problem.
Thank you

Hasti Keyvan


 
Old April 14th, 2008, 12:50 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Quote:
quote:but when users want to upload they recive error:file not found.
When do they get this error exactly? When they browse to the ASPX page? When they try to upload a file? When they try to download an uploaded file?

Can you provide more information, such as how users access your site, the *exact* error message you get and so on. Without that, it's impossible to say what's going on....

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
 
Old April 14th, 2008, 11:25 PM
Friend of Wrox
 
Join Date: May 2005
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default

They get this error message when they click the insert button for uploading pdf files.and they recieve error404 (file not found). and ther url is: http://mycoputername/mysitename/form....../mypagename
I'm looking forward for your kindly reply.
Thank you
Hasti Keyvan

 
Old April 14th, 2008, 11:41 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

This is not the exact error message, is it? This is the URL, and your interpretation, right?

Go into your web.config and turn off custom errors. E.g. enable the customErrors section and set it to off:

<customErrors mode="Off" ..... />

Then try again.

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
 
Old April 15th, 2008, 12:43 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default

Dear Imar
Thank you for your kindly help.
I set customErrors mode=off and it gave me an error regarding to msgalert and I fixed and it's working now
Thank you again
Hasti Keyvan






Similar Threads
Thread Thread Starter Forum Replies Last Post
Upload pradeepbees Classic ASP Databases 0 May 15th, 2007 04:04 AM
Whole Folder upload(Multi file Upload) ramasamy_rams XML 1 September 9th, 2005 12:43 PM
UPLOAD HELP! HELP! HELP! msunnastood Dreamweaver (all versions) 5 November 25th, 2004 04:04 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.