Home
Get Started
Learn
Downloads
AJAX
MVC
Community
Wiki
Forums
Sign in
|
Join
Home
›
ASP.NET Forums
›
Search
Search
You searched for the word(s): userid:778880
More Search Options
RSS Available
Matching Posts
File not attaching to email
I am working on allowing a user to attach a file to an email via web form. I have the following code: protected void Page_Load(object sender, EventArgs e) { } #region UploadFile(string, FileUpload, string) public static bool UploadFile(string folder, FileUpload control, string FileNamePlusExtension) { if (!control.HasFile) return false; int length = Convert.ToInt32(control.FileContent.Length); byte[] origImageData = new byte[length]; control.FileContent.Read(origImageData, 0, length); string path
Posted to
Web Forms
(Forum)
by
the.one
on 6/6/2009
Filed under: file email attach web form
Re: File Upload control errors
Malcolms - That cleared it up. Thanks for your speedy response!
Posted to
Web Forms
(Forum)
by
the.one
on 6/2/2009
Re: File Upload control errors
Thanks for your responses. I removed the line: control.PostedFile.SaveAs(string path = (Server.MapPat("~/uploads/") + "/" + FileNamePlusExtension); and replaced it with: string path = Server.MapPath("~/uploads/") + FileNamePlusExtension; control.PostedFile.SaveAs(path); My only error now is with 'Server' in string path = Server.MapPath(...). The error is " An object reference is required for the non-static field, method, or property 'System.Web.UI.Page
Posted to
Web Forms
(Forum)
by
the.one
on 6/2/2009
File Upload control errors
I'm getting errors compiling the following code (specifically the control.PostedFile.SaveAs line): using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using System.Net; using System.Net.Mail; public partial class employment : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } #region UploadFile(string, FileUpload, string) public static bool UploadFile(string folder, FileUpload control
Posted to
Web Forms
(Forum)
by
the.one
on 6/2/2009
Filed under: control.postedfile.saveas, file upload control
Re: Image Map not working in IE7
I am using the same lines in my code as well. Here are the lines verbatim as they appear before my image map: <?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <title>Coconut
Posted to
Master Pages, Themes and Navigation Controls
(Forum)
by
the.one
on 8/8/2008
Re: Image Map not working in IE7
Shail - Did what you said (good tip by the way) and narrowed it down to the DOCTYPE line. As soon as I took that line away, IE allowed me to click on the image map. Without the DOCTYPE being defined, the page doesn't load correctly (obviously) and there aren't many choices to choose from for DOCTYPES. I tried changing the page from the current <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> to the Transitional
Posted to
Master Pages, Themes and Navigation Controls
(Forum)
by
the.one
on 8/8/2008
Image Map not working in IE7
I have a fairly simple image map that I'm using in a web page. It works in Firefox, but not in IE7. Here is the code: <div id="logo"> <asp:ImageMap ID="Menu_Links" runat="server" HotSpotMode="Navigate" Height="330px" Width="850px" ImageUrl="~/images/header_blank.gif"> <asp:RectangleHotSpot AlternateText="Home" HotSpotMode="Navigate" Bottom="330" Left="50" NavigateUrl="main
Posted to
Master Pages, Themes and Navigation Controls
(Forum)
by
the.one
on 8/7/2008
Filed under: Image Map Control
Page 1 of 1 (7 items)
WindowsClient:
HTTP 403.9 with ADO.NET Data Services
WindowsClient:
xml syntax highlighting in Silverlight
Channel 9:
Channel 9 Emerges in China
WindowsClient:
Overlaying Icons on the Windows 7 Taskbar with WPF 4
Channel 9:
The Outlook calendar starts in 1601 - But Why?
ASP.NET:
Bytes by MSDN: Brad Abrams Interview with Billy Hollis: Silverlight 4, RIA Services and VS2010
Mix Online:
Pictures or it Didn't Happen
Channel 9:
Reactive Extensions API in depth: even more Zip
TechNet Edge:
SDL For Agile
Mix Online:
Test Lab Note
Channel 9:
Enabling Help in the Visual Studio 2010 Shell
Channel 9:
Office Casual - Smart Art
WindowsClient:
Prism and MEF
IIS.NET:
Overcoming the Challenges Enterprises Face with Streaming Video
Silverlight:
MEF, Silverlight and the HVP
TechNet Edge:
Client and Cloud Security
TechNet Edge:
Client and Cloud Security
Channel 9:
Building on Azure: Persistent Systems
Channel 9:
Building on Azure: Persistent Systems
TechNet Edge:
AD RMS Certificate Hierarchy and the Protection Process
Microsoft Communities
ASP.NET
Channel 8
Channel 9
Channel 10
IIS.NET
Silverlight
TechNet Edge
WindowsClient
Mix Online