Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

C# -- MenuStrip (Reusing on Form2)

Posted on 2009-07-15
3
Medium Priority
?
921 Views
Last Modified: 2013-12-17
I created a new WindowsAPP, dropped a "MenuStrip" onto Form1, and changed it to have the buttons I needed.

How can I reuse this same "MenuStrip" on Form2, Form4, etc ?
0
Comment
Question by:finance_teacher
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 1

Expert Comment

by:mattyg_mb
ID: 24862169
Using the form designer click the menu strip copy it (ctrl-c). Then paste (ctrl-v) onto the other forms. Note that this only captures the UI though, the code is not transferred to the new form.
0
 

Author Comment

by:finance_teacher
ID: 24863577
Doing a "copy/paste" requires me to "re-copy/paste" onto 50+ forms every time I make a change to the menuStrip.

Do you have a better way ?

0
 
LVL 1

Accepted Solution

by:
mattyg_mb earned 2000 total points
ID: 24863859
If the behavior is always the same, then putting it into a User Control should work well. You just update the one control, and the changes are replicated when you rebuild the application. This control can be selected from your toolbox and added to all of your forms.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question