Prevent same window open more than once?

Posted on 2006-04-28
Last Modified: 2012-06-27
I need to open a licensing window for a project, however it needs a restriction to prevent hackers from simply opening several windows.
Question by:kvnsdr
    LVL 4

    Accepted Solution

    make the form class a singleton so there can't be more than 1 at a time

    if this screen is the first screen in the app, an alternative might be to check on start-up for another instance of your program, if you find one give it focus and exit otherwise show your start form
    LVL 44

    Expert Comment

    Hello kvnsdr,

    assuming you mean to prevent a seocnd instance of your application you could look into creating a named mutex for your app, and for a very thorough overview of how to implement

    hope this helps a bit
    LVL 4

    Expert Comment

    Dear kvnsdr,
    Have a look at it if it could help your idea.
    LVL 1

    Author Comment

    Thanks jmeyer43.

    Here's the perfect link for others to follow.....

    Featured Post

    Why You Should Analyze Threat Actor TTPs

    After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

    Join & Write a Comment

    Introduction                                                 Was the var keyword really only brought out to shorten your syntax? Or have the VB language guys got their way in C#? What type of variable is it? All will be revealed.   Also called…
    Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    745 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

    Need Help in Real-Time?

    Connect with top rated Experts

    13 Experts available now in Live!

    Get 1:1 Help Now