آژانس هواپیماییexchanging

یه افکت جالب واسه آخر برنامه

شروع موضوع توسط Yasser80 ‏23 آپریل 2010 در انجمن Visual Basic 6

  1. Yasser80

    Yasser80 کاربر تازه وارد

    تاریخ عضویت:
    ‏30 مارس 2010
    نوشته ها:
    10
    تشکر شده:
    0
    کد:
    Private Sub Command1_Click()
    Dim GoToVal As Integer
    Dim Gointo As Integer
    GoToVal = Me.Height / 2
    
    For Gointo = 1 To GoToVal
        'NEW ADDITION NEXT LINE
        DoEvents
            Me.Height = Me.Height - 10
            Me.Top = (Screen.Height - Me.Height) \ 2
            If Me.Height <= 11 Then GoTo horiz
        Next Gointo
        
        'This is the width part of the same sequence above
    horiz:
        Me.Height = 30
        GoToVal = Me.Width / 2
        
        For Gointo = 1 To GoToVal
            'NEW ADDITION NEXT LINE
            DoEvents
                Me.Width = Me.Width - 10
                Me.Left = (Screen.Width - Me.Width) \ 2
                If Me.Width <= 11 Then End
            Next Gointo
    End
    End Sub