codetoad.com
  ASP Shopping CartForum & BBS
  - all for $20 from CodeToad Plus!
  
  Home || ASP | ASP.Net | C++/C# | DHTML | HTML | Java | Javascript | Perl | VB | XML || CodeToad Plus! || Forums || RAM 
Search Site:
Search Forums:
  Strange happenings in Visual Studio. Please Help!  jtencate at 19:58 on Wednesday, October 20, 2004
 

Ok this is a strange one and I'm at the end of my rope.

I am using delegates to cause an update event to fire on a aspx page when a button is clicked on an embedded user control.

The problem I am having is:

When ever I make a layout change in design view on the page, the line of code under initializeComponent that ties the delegate to the method that handles it gets erased and I have to rewrite it.

Has anyone ever come accross this problem and found a way to solve it.

TIA -John

  Re: Strange happenings in Visual Studio. Please Help!  t.manojp at 06:06 on Thursday, November 25, 2004
 

hi,

This kind of problem occures when the refernces are not properly added, as u said u used the embeded user control so chek out all the required dll's are there in ur project.

all the best.

  Re: Strange happenings in Visual Studio. Please Help!  tgreer at 14:23 on Thursday, November 25, 2004
 

I've seen this a lot, and never found a good reason for it. I've started writing my own method/function for assigning delegates, and using it in Page_Load. This way I stay out of the VS.NET authored/controlled "region". It works, but I'm not satisfied that I fully understand the "why" of the problem. It's too easy to call it a VS.NET bug. Let me know if you learn anything new.

I will typically assign all like events, "click" for example, the same method, and use the sender/eventargs references to figure out which one. It just seems tidier to me to have a single "something_clicked" method to maintain.










CodeToad Experts

Can't find the answer?
Our Site experts are answering questions for free in the CodeToad forums
//








Recent Forum Threads
•  Re: Problem with concatenation
•  how to genrates the crystal report by sending a id at runtime
•  help me
•  pls help me with this..
•  Re: Security - Code verify
•  Job @ EarlySail
•  Job @ EarlySail (perl)
•  IPC problem
•  Re: import contacts of msn/yahoo


Recent Articles
ASP GetTempName
Decode and Encode UTF-8
ASP GetFile
ASP FolderExists
ASP FileExists
ASP OpenTextFile
ASP FilesystemObject
ASP CreateFolder
ASP CreateTextFile
Javascript Get Selected Text


© Copyright codetoad.com 2001-2007