Search

You searched for the word(s): userid:778880

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
  • 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
  • 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)