Click here to Skip to main content
15,881,424 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hai,

Im my app i have two forms, in the first form i have the button ADD,
i want to use that button in my second form, It is possible?
if u know help me.

Thanks & Regards
Honey
Posted
Comments
Albin Abel 20-Feb-11 23:48pm    
you can call the first button event from second form using delegates. But tell us why you want to do that, then we can give you the best answer
Ankur\m/ 21-Feb-11 2:29am    
Reply from OP:
hai Abel, in my second form i have only Node Deletion code only, after Deletion Operation Performed i want to Disable the ADD button which is exists in Form1 i think now u understand my requirement,
Sunasara Imdadhusen 20-Feb-11 23:49pm    
Good suggestion by AlbinAbel
Albin Abel 21-Feb-11 0:03am    
Thanks Sunasara Imdadhusen
Ankur\m/ 21-Feb-11 2:30am    
Use 'Reply' link (which can be seen when you mouse over a comment) to reply to a comment because that will notify the user and adding a comment below your answer won't.

1 solution

Based on the fact you are using ASP.Net going by your tags, and you say you want to use the SAME button, one option might be to use Master Pages, create a Master page with a content section, the master page would have your button, the content section would be the placeholder for your forms page. When you create your forms page link it to the Master Page.

Alternatively, you could create a custom user control which would contain your button. This would then be placed on each page you want the button to appear on.

Without any more information on what exactly you are trying to achieve, that is the best i can suggest at the moment.
 
Share this answer
 
Comments
Ankur\m/ 21-Feb-11 5:35am    
Someone 1-voted your 'correct' answer. Let me fix it!
DaveAuld 21-Feb-11 5:52am    
thanks.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900