Results 1 to 3 of 3

Thread: transferring from VB6 question

  1. #1

    Thread Starter
    Frenzied Member maged's Avatar
    Join Date
    Nov 2002
    Location
    Egypt
    Posts
    1,040

    transferring from VB6 question

    hello all,

    I have been programming with VB6 for ages, now i found somethings within VB.NEt that i will need your help in.

    1 - when i was doing a lenght jobs i usuall used the followin :

    VB Code:
    1. screen.mousepointer = 11
    2. '''''dooing jobs
    3. screen.mousepointer = 0

    so i could make the waiting cursor. it seems i cant do it anymorein VB.net . how could i do that????

    2 - when i declare a form in vb.net , how could i load it in memory without showing it. The old command " Load form1" is not supported in more

    THX in advance

  2. #2
    Your Ad Here! Edneeis's Avatar
    Join Date
    Feb 2000
    Location
    Moreno Valley, CA (SoCal)
    Posts
    7,339
    VB Code:
    1. Me.Cursor = Cursors.WaitCursor
    2.         ''do jobs
    3.         Me.Cursor = Cursors.Default
    When you create an instance of a form it is created in memory. Note that this does not fire the load event, you should put any initialization code in the constructor which is fired at this time. Unless of course it doesn't matter if the form is shown or not in which is usually the case and you can still use the Load event.
    VB Code:
    1. Dim frm As New Form1 'it is now created and in memory

  3. #3
    PowerPoster hellswraith's Avatar
    Join Date
    Jul 2002
    Location
    Washington St.
    Posts
    2,464
    Edneeis's way, or this way:
    Code:
    Dim cur as Cursor = Cursor.Current
    Cursor.Current = Cursors.WaitCursor
    
    'Code here.
    
    Cursor.Current = cur
    If the cursor is other than default when you start the code, you would want to put it back how it was when you are done.

Posting Permissions

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



Click Here to Expand Forum to Full Width