Visit Map

Friday, April 22, 2005

Using Microsoft Agent from .NET

Download the microsoft agent from http://www.microsoft.com/msagent/default.asp. If not present at /msagent\chars
Add a reference to Microsoft Agent server using tools - references - Microsoft Agent server 2.0
Here is the code

IAgentCtlCharacterEx Genie;
Keep a textbox on form and a button in the button click keep the following code

IAgentCtlCharacterEx Genie;
if(textBox1.Text!="")
{
Agent1=new AgentClass();
try
{
Agent1.Connected = true;
string strPath=ConfigurationSettings.AppSettings.Get("path").ToString();
//strPath is /msagent\chars
Agent1.Characters.Load("Merlin",strPath);
Genie=Agent1.Characters.Character("Merlin");
Genie.Show(true);
Genie.Speak(textBox1.Text,"");
}
catch(Exception ex)
{
throw ex;
}


This is just an idea to share

Sunday, April 17, 2005

Checklist:ADO.NET Performance

While browsing the Net i came across one book
Improving .NET Application Performance and Scalability called ScaleNet.pdf
You can download the same from www.microsoft.com/practices
The book is very goood. I suggest you to read that book

In that they given a checklist
Here is checklist for ADO.NET Performance

Design your data access layer based on how the data is used.
Cache data to avoid unnecessary work.
Connect by using service accounts.
Acquire late, release early.
Close disposable resources.
Reduce round trips.
Return only the data you need.
Use Windows authentication.
Choose the appropriate transaction type.
Use stored procedures.
Prioritize performance, maintainability, and productivity when you choose how to pass data
across layers.
Consider how to handle exceptions.
Use appropriate normalization
If you follow the above checklist you can increase the performence of a .NET Application

Thursday, April 07, 2005

Session State

Recently i had doubt on a session is handled between Classic ASP and Classic ASP.NET.The session management between ASP and ASP.NET is sticky issues. An article from Egghead Café cleared by doubts.
http://www.eggheadcafe.com/articles/20021207.asp
I also went through the article in MSDN how a session is managed in ASP.NET
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconsessionstate.asp

Microsoft User Group Hyderabad is conducting a session on Existing and Emerging technologies the session in Cyber towers, Chip Auditorium Madhapur Hyderabad.
One can register at www.mugh.net/devcon.htm.