Came across this error today which left me scratching my head for a bit. Basically, I have a Gridview with a Select column, two Button columns, and a few Bound columns. I gave each button column a unique CommandName property, and one of them was “Delete”, because I was using it to delete the row (I was doing it manually). I am handling the buttons’ click events in the RowCommand event and discerning which is which by
e.CommandName. However, every time I clicked the delete button, I would get the error:
The Gridview [x] Fired Event RowDeleting Which Wasn’t Handled
This struck me as odd, because I wasn’t doing anything with a “RowDeleting” event. I tried putting some random code in there, nothing worked, although the code was getting executed every time. After trying any and everything I could think of, I decided to change the CommandName “Delete” to “Delort” (courtesy of Strongbad 🙂 ) and viola! It worked!
Apparently, the CommandName “Delete” is reserved for the Built-In Editing Functionality of the GridView. I’m sure there are others reserved, too, but I didn’t really look into it any further. Who knew?
I’ll lay it out very simply:
- On your .aspx page, include the following:
<%@ MasterType virtualpath="~/myMasterPage.master" %>
- To reference the members, simply type
That’s it! It’s better than casting a new master page object for every function, that’s for sure.
NOTE: Content pages load BEFORE master pages, so if you’re going to reference something on your master page, be sure you don’t need it during your content page’s Page_Load event!
I ran into this problem that I simply could not for the life of me figure out. My main site, www.columbussupply.com, has never had any problems sending email via my usual SMTP server. However, I have a couple sites using the same host in my account at Successful Hosting (a FANTASTIC webhost, by the way, if for no other reason than the spectacular customer service [no they did not pay me a dime to say this]), and I was having problems with my new site, www.proudwearsports.com, sending email. The error I kept receiving was:
System.Net.Mail.SmtpFailedRecipientException: Mailbox name not allowed. The server response was: sorry, that domain isn’t allowed to be relayed thru this MTA (#5.7.1)
After talking with Wade (at Successful Hosting) about my issue, he quickly diagnosed the problem. Apparently, their server requires authentication (ie, logging in) before sending any mail. The server was simply not allowing me to send mail from the site without the proper authentication. So, we went through my code, and there just wasn’t anywhere in the System.Net.Mail class that would allow me to authenticate the email before I sent it, which had me confused (if there is, in fact, a way to do this programmatically, please correct me!). But, after a bit of searching I came up with the following magical Web.config code:
<network host=”whatever.yoursmtphostis.com” password=”yourpassword” userName=”email@example.com” />
And that’s it! Once I put that in, the email was sent and everyone went on with their day with a big ol’ smile on their face.
While working on my newest creation, PROUDWear Sports, I’ve run into a little snag trying to implement the ModalPopupExtender. Of course it works fine in IE7 and FireFox, but in IE6, it just refuses to work correctly. I’m pretty sure that I’ve implemented it correctly, but one can never be too sure. I watched the How Do I: Use the ASP.NET AJAX ModalPopup Extender Control video provided by Microsoft and followed it pretty much exactly, except including my own functionality (which is essentially nothing! Basically showing a picture in the hidden panel with a close button, that’s it.) and still it refuses to work in IE6.
I posted in the ASP.NET forums about my issue a few minutes ago, detailing my total problem (6th post down, you can find it by searching for “.NET Discussion”). If you don’t want to go there, basically what happens is in IE6, instead of properly displaying the chosen modal panel, it displays the panel inline with the rest of the page and then goes modal, rendering the page inaccessible to the user.
If anyone has any suggestions, please please let me know. Thanks!
Status: Solved! (8/17/07)
Solution: Upgrade your AJAX Toolkit DLL. This version is not the newest version, but the ModalPopupExtender functions correctly in IE6 when this one is applied. I am not using the latest version because the accordion control does not function correctly in the newer versions. When they fix that, I will go to the newest version.
This may be a bit of a stretch, but I was wondering if anyone knew of any way to accept input from a writing tablet and display it dynamically as it is happening, or at least to submit it after you’re done. If you know how to do this, you are officially a .NET god (or just a computer god). I suppose this could be used for signing receipts when you pay for something online (and to be honest, I’m sure if this was available, big name companies would already have it) or to play games involving drawing. If you have any idea how to do this, I would absolutely love to hear it, and you will get full credit on this site (which is getting surprisingly popular as of late, considering how recently I started it). So get to it!