Другие языки программирования и технологии

Как создать программу движущийся прямоугольник на языке Бейсик. Показать, или кде можно ее увидеть как это выглядит

Aziat Para
Aziat Para
157
на бейсике то уж почти никто не пишет, не популярный это язык
Женя Рыженко
Женя Рыженко
55 207
ну как как и везде
рисуем квадрат цветом отличным от цвета экрана
рисуем квадрат цветом экрана
изменяем координаты квадрата и в новь рисуем
Вот пример на Visual Basic .Net:
Public Class Form1
Inherits System.Windows.Forms.Form

#Region " Windows Form Designer generated code "

Public Sub New()
MyBase.New()

'This call is required by the Windows Form Designer.
InitializeComponent()

'Add any initialization after the InitializeComponent() call

End Sub

'Form overrides dispose to clean up the component list.
Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing Then
If Not (components Is Nothing) Then
components.Dispose()
End If
End If
MyBase.Dispose(disposing)
End Sub

'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer

'NOTE: The following procedure is required by the Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
Friend WithEvents Panel1 As System.Windows.Forms.Panel
Friend WithEvents Timer1 As System.Windows.Forms.Timer
<system.diagnostics.debuggerstepthrough()> Private Sub InitializeComponent()
Me.components = New System.ComponentModel.Container
Me.Panel1 = New System.Windows.Forms.Panel
Me.Timer1 = New System.Windows.Forms.Timer(Me.components)
Me.SuspendLayout()
'
'Panel1
'
Me.Panel1.Location = New System.Drawing.Point(72, 24)
Me.Panel1.Name = "Panel1"
Me.Panel1.Size = New System.Drawing.Size(80, 32)
Me.Panel1.TabIndex = 0
'
'Timer1
'
Me.Timer1.Enabled = True
'
'Form1
'
Me.AutoScaleBaseSize = New System.Drawing.Size(5, 13)
Me.ClientSize = New System.Drawing.Size(344, 301)
Me.Controls.Add(Me.Panel1)
Me.Name = "Form1"
Me.Text = "Form1"
Me.ResumeLayout(False)

End Sub

#End Region

Private Sub Panel1_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles Panel1.Paint
e.Graphics.DrawRectangle(New Pen(Color.Black), 1, 1, Panel1.Width - 2, Panel1.Height - 2)
End Sub

Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
Panel1.Top = Panel1.Top + 1
End Sub
End Class
ненаю я на dеlphi видил!
Александр Ghost11
Александр Ghost11
2 364