Locations of visitors to this page


Onteora Software - September 2006

Onteora Software

Ken Tucker's Blog

About the author

Author Name is someone.
E-mail me Send mail

Recent posts

Recent comments

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008

.Net Framework 3.0 Text to Speech

.Net Framework 3.0 Text to Speech



The dot net framework 3.0 now has a managed provider for text to speech. I tested this app on a machine with windows xp service pack 2 and the Dot Net FrameWork 3.0 RC1. The link is to set up instructions for the .net framework 3.0

 

For this sample add a reference to system.speech, place a textbox named txtSay, a button named btnSay, and listbox named lstVoice. The application fills a list box with the installed voices on the system at startup. When you click on the button it says the text in the textbox with the selected voice.




VB Sample

Imports System.Speech.Synthesis

Public Class Form1

    Private Sub btnSay_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSay.Click
        Dim spk As New SpeechSynthesizer
        spk.SelectVoice(lstVoice.SelectedItem.ToString)
        spk.Speak(txtSay.Text)
    End Sub

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Dim spk As New SpeechSynthesizer
        For Each voice As InstalledVoice In spk.GetInstalledVoices
            lstVoice.Items.Add(voice.VoiceInfo.Name)
        Next
        lstVoice.SelectedIndex = 0
        txtSay.Text = "Hello World!"
    End Sub
End Class

 

C# Sample

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Speech.Synthesis;

namespace CS3._Speech
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            SpeechSynthesizer spk = new SpeechSynthesizer();
            foreach(InstalledVoice voice in spk.GetInstalledVoices())
            {
                lstVoice.Items.Add(voice.VoiceInfo.Name);
            }
            lstVoice.SelectedIndex = 0;
            txtSay.Text = "Hello World";
        }

        private void btnSay_Click(object sender, EventArgs e)
        {
            SpeechSynthesizer spk = new SpeechSynthesizer();

            spk.SelectVoice(lstVoice.SelectedItem.ToString());
            spk.Speak(txtSay.Text);
        }
    }
}

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Categories: General | VB | C#
Posted by Ken Tucker on Thursday, September 21, 2006 10:12 PM
Permalink | Comments (0) | Post RSSRSS comment feed

Microsoft Visual Basic 2005 Power Packs

Microsoft Visual Basic 2005 Power Packs



Visual Basic 2005 Power Packs are free Add-Ins, Controls, Components, Tools or Samples for you to use with Visual Basic 2005 to make developing great applications even easier!



Microsoft Interop Forms Toolkit 1.0

This toolkit is aimed at simplifying the use of Visual Basic.NET WinForms within a Visual Basic 6 application. The toolkit is targeted specifically at providing tools and guidance for performing a phased migration of a VB6 forms-based application to VB.NET. The goal of a phased migration is a production release at the end of each phase that has both VB6 and .NET forms running in the same VB6 .exe process.




Microsoft PrintForm Component 1.0

The PrintForm component is designed to bring back the ability to easily print a Windows Form. With this the new PrintForm component you can once again layout the Windows Form exactly as you want it and allow your users to print the form as a quick report.

Currently rated 1.0 by 1 people

  • Currently 1/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Categories: VB
Posted by Ken Tucker on Thursday, September 21, 2006 1:12 AM
Permalink | Comments (0) | Post RSSRSS comment feed

Beta Certification Exam

Beta Certification Exam



I took the beta exam for Microsoft Windows Mobile 5.0 - Application Development (exam number 70-540) with the visual basic option. The exam had 81 questions with a 4 hour time limit. There was one c# question slipped in there.



There were questions on the creating menus, smart phone connection status to the network, interacting with contact list, listing items in the task list, serial port, xml, and httpwebrequests.


SQL Everywhere (formerly SQL Mobile) was a topic which had a few questions. You will need to know how to repair a database, and sync with a sql 2005 database.

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Categories: General | Archive
Posted by Ken Tucker on Wednesday, September 06, 2006 10:12 PM
Permalink | Comments (0) | Post RSSRSS comment feed