SEARCH :

Custom Search

Thursday, September 18, 2008

Using MSAgent on Your VB .NET Aplication


MSAgent or Microsoft Agent is a software technology that enables an enriched form of user interaction that can make using and learning to use a computer, easier and more natural.

With the Microsoft Agent set of software services, developers can easily enhance the user interface of their applications and Web pages with interactive personalities in the form of animated characters. These characters can move freely within the computer display, speak aloud (and by displaying text onscreen), and even listen for spoken voice commands. When used effectively with a conversational interface approach, Microsoft Agent can be a powerful extension and enhancement of the existing interactive modalities of the Microsoft Windows interface.


Bellow is the example code To use MSAgent on Visual Basic .NET..
Public Class Form1
Inherits System.Windows.Forms.Form
Dim Character As AgentObjects.IAgentCtlCharacter
Dim sChar As String

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
try
' The path to the character file
sChar = Application.StartupPath & "\merlin.acs"
' Load the character
agtAgent.Characters.Load("merlin.acs", sChar)

' Set the "Character" declaration to be the character
' just loaded
Character = agtAgent.Characters("merlin.acs")

' Set the character's language to english
Character.LanguageID = &H409

'Show the Agent Character into Desktop
Character.Show()

'Make the agent to Move
Character.MoveTo(1100, 600, 5)

'Make the agent to play some animations..
Character.Play("Surprised")

Catch ex As Exception
MessageBox.Show("Description: " & _
ex.Message, "Error!", MessageBoxButtons.OK, _
MessageBoxIcon.Warning)
End Try

End Sub
End Class
If you didn't have MSAgent on your Computer, you can download it from http://www.microsoft.com/msagent/downloads/.

For demo Aplication Click here to download file

For Source Code Click here to download file

2 comments:

Anonymous said...

Maybe you want some information related with how to monetize your blog, CEO issue, and how to make a business web site just click here

shasa said...

wah baru nemu nih blog seru buat sharing..
seru mas.
mampir ke web saya yah mas.
filesearch.web.id