I could have just removed the elements file reference from the feature, but just chose to delete the elements file in its entirety. So folks, when you create an event receiver via the Share Point tools in Visual Studio, and you REALLY don’t want it associated to every single list, remember not to be a bone head like me.
I seem to have a problem with mode changing when using my detailsview control. protected void Detail View_Mode Changing(object sender, Details View Mode Event Args e) Now, when I click on edit or insert and trace, the program hits the right event, but I have to hit the button twice for the control to change mode.
uri=spotify:artist:4Kfw TCNq T3g Xele8WP3s5b&size=detail&theme=light So for the past week or so I’ve had this looming issue hanging over my head that I would try to nail down in-between other issues that I swear was going to be the death of me.
I knew whatever it was had to be something really simple that I kept overlooking and something that, when I finally figured it out, would be quite .
the above snippet should be changed like this: Just wanted to add my two cent for those still having this problem.
That happened to me as well whenever I changed the Data Source or Data Source ID in Page Load.
Even a simple app to enumerate the event receivers associated to the list only showed the one instance. Well, I had moved on to other things again, when all of a sudden, I noticed that new tasks were being created in the task list for some documents that I was uploading to a different document library. That’s pretty much the symptom for a receiver associated to a list template, but this was NOT a list template! It wasn’t going to show up in the Event Receivers collection for that list instance, because it was associated to the list type.
Scott I have to say I've had just about enough of this wizard-driven all-your-code-in-one-place orientation you find everywhere in the documentation and samples. Main idea is that after the state is changed you have to rebind your control to make it actually "see" the changes.Even when it does change mode, regardless of which control I hit, the program will randomly decide if it is going to go into edit mode or update mode.So I might hit update and get the insert mode, or vice versa.I had already covered all the basic things such as: I even went as far as completely emptying the body of the handler to see that in fact the event was firing twice.As with any problem, I always try to resolve it through the process of elimination by first isolating the core issue into a test project and therefore out of the primary project I’m experiencing it in because sometimes you can’t see the forest because of the trees. After creating the simple project, the problem was still there. The event wasn’t firing twice for the same list, it was firing for ALL Lists. I took another look at my event receiver I had added via Visual Studio to the project. Yes, I had left the file for the Event Receiver there, and therefore when the feature was activated for the project, the receiver got associated to ALL lists on the site.