SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Wizard Wolf_22's Avatar
    Join Date
    Jul 2005
    Posts
    1,714
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Form in VC# needs opacity changed...

    Yeah, so I'm new to this .NET stuff, so if my slang isn't to par, forgive me...

    I have a form that I'm messing around with in Visual Studio 2005 (making an alternative Notepad from a tutorial I'm working with). I set the form to 80% opacity (out of whim) because I thought it looked FANTABULOUS!

    Anyhoo, how would I make this change to something other than 80% if I clicked on "File" or "Edit" on the menustrip at the top?

    I tried to make it happen using something like Opacity = .10; in the "mnuFile_Click" routine or function or whatever, but of course, as luck or skill (or experience) would deem appropriate - it didn't work.

    This is all I have for the controller at present (where's the cream filling!?):
    Code:
            
    private void toolStripMenuItem1_Click(object sender, EventArgs e)
    {
    
    }

  2. #2
    SitePoint Wizard Mike Borozdin's Avatar
    Join Date
    Oct 2002
    Location
    Edinburgh, UK
    Posts
    1,743
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Code Csharp:
    private void toolStripMenuItem1_Click(object sender, EventArgs e)
    {
          Opacity = 0.1;
    }


  3. #3
    SitePoint Wizard Wolf_22's Avatar
    Join Date
    Jul 2005
    Posts
    1,714
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Mike Borozdin View Post
    Code Csharp:
    private void toolStripMenuItem1_Click(object sender, EventArgs e)
    {
          Opacity = 0.1;
    }


    * Thinks to himself, "...I thought I tried that..." *

    Well, I'll give it another go... Thanks Mike.

  4. #4
    SitePoint Wizard Mike Borozdin's Avatar
    Join Date
    Oct 2002
    Location
    Edinburgh, UK
    Posts
    1,743
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Why doesn't it work while it should? Check if the event occures, I mean if that method is ever executed.

  5. #5
    SitePoint Wizard Wolf_22's Avatar
    Join Date
    Jul 2005
    Posts
    1,714
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Okay... I think I know what I need to ask now...

    How can I make my form change the Opacity to '1' when I click on the mnuFile, but when the drop-down sub-menu of mnuFile is exited, make the form go back to the original Opacity of .8?

    What I'm trying to do here is make my Opacity settings reflect that of an anchor element behavior - when clicked on, event happens, but when the sub-menu goes back up, the event is reset.

    Do you understand me?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •