home *** CD-ROM | disk | FTP | other *** search
- VERSION 5.00
- Object = "{F5BE8BC2-7DE6-11D0-91FE-00C04FD701A5}#2.0#0"; "AGENTCTL.DLL"
- Begin VB.Form Form1
- Caption = "Microsoft Agent"
- ClientHeight = 3195
- ClientLeft = 60
- ClientTop = 345
- ClientWidth = 4680
- LinkTopic = "Form1"
- ScaleHeight = 3195
- ScaleWidth = 4680
- StartUpPosition = 3 'Windows Default
- Begin VB.Frame Frame1
- Caption = "Actor"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = -1 'True
- Strikethrough = 0 'False
- EndProperty
- ForeColor = &H000000FF&
- Height = 1695
- Left = 480
- TabIndex = 3
- Top = 840
- Width = 1575
- Begin VB.OptionButton optPapagal
- Caption = "Papagal"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = -1 'True
- Strikethrough = 0 'False
- EndProperty
- ForeColor = &H00FF0000&
- Height = 375
- Left = 120
- TabIndex = 6
- Top = 1200
- Width = 1215
- End
- Begin VB.OptionButton optVrajitor
- Caption = "Vrajitor"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = -1 'True
- Strikethrough = 0 'False
- EndProperty
- ForeColor = &H00FF0000&
- Height = 375
- Left = 120
- TabIndex = 5
- Top = 720
- Width = 1095
- End
- Begin VB.OptionButton optGeniu
- Caption = "Geniu"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = -1 'True
- Strikethrough = 0 'False
- EndProperty
- ForeColor = &H00FF0000&
- Height = 375
- Left = 120
- TabIndex = 4
- Top = 240
- Width = 1215
- End
- End
- Begin VB.CommandButton cmdText
- BackColor = &H0080FFFF&
- Caption = "Introduceti textul"
- BeginProperty Font
- Name = "Arial"
- Size = 9
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = -1 'True
- Strikethrough = 0 'False
- EndProperty
- Height = 615
- Left = 3000
- MaskColor = &H000000FF&
- TabIndex = 2
- Top = 2160
- Width = 1335
- End
- Begin VB.CommandButton cmdStop
- BackColor = &H0080FFFF&
- Caption = "STOP"
- BeginProperty Font
- Name = "Arial"
- Size = 9
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = -1 'True
- Strikethrough = 0 'False
- EndProperty
- Height = 615
- Left = 3000
- MaskColor = &H000000FF&
- TabIndex = 1
- Top = 1320
- Width = 1335
- End
- Begin VB.CommandButton cmdStart
- BackColor = &H0080FFFF&
- Caption = "START"
- BeginProperty Font
- Name = "Arial"
- Size = 9
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = -1 'True
- Strikethrough = 0 'False
- EndProperty
- Height = 495
- Left = 3000
- MaskColor = &H000000FF&
- TabIndex = 0
- Top = 480
- Width = 1335
- End
- Begin AgentObjectsCtl.Agent Agent1
- Left = 120
- Top = 0
- _cx = 847
- _cy = 847
- End
- Attribute VB_Name = "Form1"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- Option Explicit
- Dim agent As IAgentCtlCharacter
- Dim txt As String
- Const GENIEPATH = "C:\WINDOWS\MSAGENT\CHARS\Genie.acs"
- Const PEEDYPATH = "C:\WINDOWS\MSAGENT\CHARS\Peedy.acs"
- Const MERLINPATH = "C:\WINDOWS\MSAGENT\CHARS\Merlin.acs"
- Private Sub Form_Deactivate()
- Set agent = Nothing
- End Sub
- Private Sub cmdStart_Click()
- agent.Show
- agent.MoveTo 200, 200
- agent.Speak txt
- End Sub
- Private Sub cmdStop_Click()
- agent.MoveTo 500, 500
- agent.Hide
- End Sub
- Private Sub cmdText_Click()
- txt = InputBox("Introduceti textul:")
- If Len(txt) <> 0 Then
- agent.Speak txt
- End If
- End Sub
- Private Sub Form_Load()
- Set agent = Nothing
- Agent1.Characters.Load "Genie", GENIEPATH
- optGeniu.Enabled = True
- Set agent = Agent1.Characters("Genie")
- txt = "Hello Boss!!! My name is Genie."
- End Sub
- Private Sub optGeniu_Click()
- agent.Hide
- Agent1.Characters.Unload agent.Name
- Set agent = Nothing
- optGeniu = True
- Agent1.Characters.Load "Genie", GENIEPATH
- Set agent = Agent1.Characters("Genie")
- txt = "Hello Boss!!! My name is Genie."
- End Sub
- Private Sub optPapagal_Click()
- agent.Hide
- Agent1.Characters.Unload agent.Name
- Set agent = Nothing
- optPapagal = True
- Agent1.Characters.Load "Peedy", PEEDYPATH
- Set agent = Agent1.Characters("Peedy")
- txt = "Hello Boss!!! My name is Peedy."
- End Sub
- Private Sub optVrajitor_Click()
- agent.Hide
- Agent1.Characters.Unload agent.Name
- Set agent = Nothing
- optVrajitor = True
- Agent1.Characters.Load "Merlin", MERLINPATH
- Set agent = Agent1.Characters("Merlin")
- txt = "Hello Boss!!! My name is Merlin."
- End Sub
-