PROGRAMACIÓ D'APLICACIONS EDUCATIVES AMB VISUAL BASICMÒDUL 1

Fitxer: m1p2.frm

Definició dels objectes. Interfície d'usuari

Recordeu que això no ho podeu editar directament. Per fer-ho incorporeu nous objectes de la paleta en el vostre formulari. I per canviar els valors seleccioneu l'objecte i escolliu la propietat a canviar en la finestra Properties.

VERSION 5.00
Begin VB.Form frmPaisatge 
   Appearance      =   0  'Flat
   BackColor       =   &H80000005&
   BorderStyle     =   1  'Fixed Single
   Caption         =   "Paisatge"
   ClientHeight    =   3630
   ClientLeft      =   1875
   ClientTop       =   1485
   ClientWidth     =   6765
   BeginProperty Font 
      Name            =   "MS Sans Serif"
      Size            =   8.25
      Charset         =   0
      Weight          =   700
      Underline       =   0   'False
      Italic          =   0   'False
      Strikethrough   =   0   'False
   EndProperty
   ForeColor       =   &H80000008&
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   PaletteMode     =   1  'UseZOrder
   Picture         =   "M1P2.frx":0000
   ScaleHeight     =   3630
   ScaleWidth      =   6765
   Begin VB.CommandButton cmdFí 
      Appearance      =   0  'Flat
      Caption         =   "Fí"
      Height          =   375
      Left            =   240
      TabIndex        =   5
      Top             =   2880
      Width           =   1095
   End
   Begin VB.CommandButton cmdCap 
      Appearance      =   0  'Flat
      Caption         =   "Cap"
      Height          =   375
      Left            =   240
      TabIndex        =   4
      Top             =   2400
      Width           =   1095
   End
   Begin VB.CommandButton cmdTotes 
      Appearance      =   0  'Flat
      Caption         =   "Totes"
      Height          =   375
      Left            =   240
      TabIndex        =   3
      Top             =   1920
      Width           =   1095
   End
   Begin VB.CommandButton cmdDisgust 
      Appearance      =   0  'Flat
      Caption         =   "Disgust"
      Height          =   375
      Left            =   240
      TabIndex        =   2
      Top             =   1440
      Width           =   1095
   End
   Begin VB.CommandButton cmdSomriu 
      Appearance      =   0  'Flat
      Caption         =   "Somriu"
      Height          =   375
      Left            =   240
      TabIndex        =   1
      Top             =   960
      Width           =   1095
   End
   Begin VB.CommandButton cmdNormal 
      Appearance      =   0  'Flat
      Caption         =   "Normal"
      Height          =   375
      Left            =   240
      TabIndex        =   0
      Top             =   480
      Width           =   1095
   End
   Begin VB.Image imgSomriu 
      Appearance      =   0  'Flat
      Height          =   645
      Left            =   1980
      Picture         =   "M1P2.frx":45542
      Top             =   1080
      Visible         =   0   'False
      Width           =   645
   End
   Begin VB.Image imgDisgust 
      Appearance      =   0  'Flat
      Height          =   645
      Left            =   3330
      Picture         =   "M1P2.frx":460E8
      Top             =   1080
      Visible         =   0   'False
      Width           =   645
   End
   Begin VB.Image imgNormal 
      Appearance      =   0  'Flat
      Height          =   645
      Left            =   2640
      Picture         =   "M1P2.frx":46C8E
      Top             =   420
      Visible         =   0   'False
      Width           =   645
   End
End


Codi del programa. Programació de respostes a events

Attribute VB_Name = "frmPaisatge"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Private Sub cmdCap_Click()
    imgNormal.Visible = False
    imgNormal.Left = 2520
    imgNormal.Top = 1380
    imgSomriu.Visible = False
    imgSomriu.Left = 2520
    imgSomriu.Top = 1380
    imgDisgust.Visible = False
    imgDisgust.Left = 2520
    imgDisgust.Top = 1380
End Sub

Private Sub cmdDisgust_Click()
    imgNormal.Visible = False
    imgSomriu.Visible = False
    imgDisgust.Visible = True
End Sub

Private Sub cmdFí_Click()
    End
End Sub

Private Sub cmdNormal_Click()
    imgNormal.Visible = True
    imgSomriu.Visible = False
    imgDisgust.Visible = False
End Sub

Private Sub cmdSomriu_Click()
    imgNormal.Visible = False
    imgSomriu.Visible = True
    imgDisgust.Visible = False
End Sub

Private Sub cmdTotes_Click()
    imgNormal.Left = 2640
    imgNormal.Top = 420
    imgNormal.Visible = True
    imgSomriu.Left = 1980
    imgSomriu.Top = 1080
    imgSomriu.Visible = True
    imgDisgust.Left = 3330
    imgDisgust.Top = 1080
    imgDisgust.Visible = True
End Sub