+ Reply to Thread
Results 1 to 6 of 6

vbModeless Question

  1. #1
    MWS
    Guest

    vbModeless Question

    By design, I have a splash screen being displayed while data is being
    formatted in my program - this is purely cosmetic, since I wanted the user to
    not view the "flashing" of the screen as the code executed. The splashscreen
    is displayed via:

    frmOpportunitySplash.Show vbModeless

    The issue I'm having is, when the splash is displayed, it is all white. In
    design mode you can see the clored background and the label, but when it's
    executed, the splash is all white. I thought maybe there was a property I
    would have to change due to the "vbmodeless", but I'm completely puzzled.

    Can anyone tell me how to rectify this situation?

    Any and All Help Will Be Appreciated

  2. #2
    Jim Thomlinson
    Guest

    RE: vbModeless Question

    You can suppress the flashing of the screen by adding

    Application.screenupdating = false

    at the beginning of the code and

    Application.screenupdating = true

    at the end. I don't know if this removes your need for a splash screen, but
    just for your reference. so if the code takes a while to execute you could
    just unhide and select a sheet with your message on it kinda like this

    sub DoYourStuff
    on error goto ErrorHandler
    with sheets("Wait Message")
    .visible = xlVisible
    .select
    end with
    application.screenupdating = false
    'Do your stuff here
    ErrorHandler:
    sheets("Wait Message").visible = xlVeryHidden
    application.screenupdating = true
    End sub
    --
    HTH...

    Jim Thomlinson


    "MWS" wrote:

    > By design, I have a splash screen being displayed while data is being
    > formatted in my program - this is purely cosmetic, since I wanted the user to
    > not view the "flashing" of the screen as the code executed. The splashscreen
    > is displayed via:
    >
    > frmOpportunitySplash.Show vbModeless
    >
    > The issue I'm having is, when the splash is displayed, it is all white. In
    > design mode you can see the clored background and the label, but when it's
    > executed, the splash is all white. I thought maybe there was a property I
    > would have to change due to the "vbmodeless", but I'm completely puzzled.
    >
    > Can anyone tell me how to rectify this situation?
    >
    > Any and All Help Will Be Appreciated


  3. #3
    Tom Ogilvy
    Guest

    Re: vbModeless Question

    Issue a doevents right after displaying it


    frmOpportunitySplash.Show vbModeless
    doevents

    --
    Regards
    Tom Ogilvy

    "MWS" <MWS@discussions.microsoft.com> wrote in message
    news:F5F4C905-5102-4AC3-A856-4E92C5E05D1B@microsoft.com...
    > By design, I have a splash screen being displayed while data is being
    > formatted in my program - this is purely cosmetic, since I wanted the user

    to
    > not view the "flashing" of the screen as the code executed. The

    splashscreen
    > is displayed via:
    >
    > frmOpportunitySplash.Show vbModeless
    >
    > The issue I'm having is, when the splash is displayed, it is all white. In
    > design mode you can see the clored background and the label, but when it's
    > executed, the splash is all white. I thought maybe there was a property I
    > would have to change due to the "vbmodeless", but I'm completely puzzled.
    >
    > Can anyone tell me how to rectify this situation?
    >
    > Any and All Help Will Be Appreciated




  4. #4
    ben
    Guest

    RE: vbModeless Question

    also

    frmOpportunitySplash.Show vbModeless
    application.doevents


    try that

    --
    When you lose your mind, you free your life.


    "MWS" wrote:

    > By design, I have a splash screen being displayed while data is being
    > formatted in my program - this is purely cosmetic, since I wanted the user to
    > not view the "flashing" of the screen as the code executed. The splashscreen
    > is displayed via:
    >
    > frmOpportunitySplash.Show vbModeless
    >
    > The issue I'm having is, when the splash is displayed, it is all white. In
    > design mode you can see the clored background and the label, but when it's
    > executed, the splash is all white. I thought maybe there was a property I
    > would have to change due to the "vbmodeless", but I'm completely puzzled.
    >
    > Can anyone tell me how to rectify this situation?
    >
    > Any and All Help Will Be Appreciated


  5. #5
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Hello MWS,

    Another trick is to repaint the UserForm...

    frmOpportunitySplash.RePaint

    Sincerely,
    Leith Ross

  6. #6
    MWS
    Guest

    Re: vbModeless Question

    Thank You for Your Help - I Appreciate It!!!!

    "Tom Ogilvy" wrote:

    > Issue a doevents right after displaying it
    >
    >
    > frmOpportunitySplash.Show vbModeless
    > doevents
    >
    > --
    > Regards
    > Tom Ogilvy
    >
    > "MWS" <MWS@discussions.microsoft.com> wrote in message
    > news:F5F4C905-5102-4AC3-A856-4E92C5E05D1B@microsoft.com...
    > > By design, I have a splash screen being displayed while data is being
    > > formatted in my program - this is purely cosmetic, since I wanted the user

    > to
    > > not view the "flashing" of the screen as the code executed. The

    > splashscreen
    > > is displayed via:
    > >
    > > frmOpportunitySplash.Show vbModeless
    > >
    > > The issue I'm having is, when the splash is displayed, it is all white. In
    > > design mode you can see the clored background and the label, but when it's
    > > executed, the splash is all white. I thought maybe there was a property I
    > > would have to change due to the "vbmodeless", but I'm completely puzzled.
    > >
    > > Can anyone tell me how to rectify this situation?
    > >
    > > Any and All Help Will Be Appreciated

    >
    >
    >


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1