Sign Up |  Live StatsLive Stats    Articles 35,345| Comments 159,791| Members 17,821, Newest cdotkhn| Online 203
Home Contact
 (Forgotten?): 
    Sikhism

   
                                                                     Your Banner Here!    

SAPI 5.1: Voice - Enabled Applications

Our Donation Goal : Why Donate? : Donate Today! : Donate Anonymously (ਗੁਪਤ) : Our Family of Supporters
Goal this month: 400 USD, Received: 35 USD (9%)
Please Donate...
Related Topics...
Thread Thread Starter Forum Replies Last Post
NRIs will soon be able to file RTI applications online rajneesh madhok Legal & Advisory 5 18-Feb-2010 00:45 AM
Access 2007 and older database applications Mike1958 Information Technology 2 28-Jul-2006 08:30 AM
maintaining deployed runtime access applications jyk Information Technology 2 28-Jul-2006 08:25 AM
Create instance of other applications using Developers edition Mr B Information Technology 1 28-Jul-2006 08:09 AM


Tags
sapi, voice, enabled, applications
Reply Post New Topic In This Forum Stay Connected to Sikhism, Click Here to Register Now!
  #1 (permalink)  
Old 04-Nov-2005, 15:20 PM
PC User's Avatar PC User
Guest
 
Posts: n/a
   
   
SAPI 5.1: Voice - Enabled Applications

  Donate Today!   Email to Friend  Tell a Friend   Show Printable Version  Print   Contact sikhphilosophy.net Administraion for any Suggestions, Ideas, Feedback.  Feedback  

Register to Remove Advertisements
I'm trying to apply some code that I've found on Text Reading and
Speech Recongnition. I don't know what version of VB that it was
develop. I've posted my project that I'm working on and I was hoping
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/information-technology/6675-sapi-5-1-voice-enabled-applications.html
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
someone could help me get it to work. It can be found at:
http://www.access-programmers.co.uk/...chmentid=11527

The code is from:
SAPI 5.1: Voice - Enabled Applications With VB
By Peter A. Bromberg, Ph.D.
http://www.eggheadcafe.com/articles/20011124.asp

Thanks for your time.
PC




 
Do share your immediate thoughts or reactions on this issue? We value your views! Login Now! or Sign Up Today! to share your views with us.. Gurfateh!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 05-Nov-2005, 12:48 PM
Douglas J Steele's Avatar Douglas J Steele
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

I'm not about to download and open the attachment, but the code outlined in
the eggheadcafe article worked fine for me in Access 97, so I'd assume it'll
work in newer versions as well.

What problem are you having?

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675


"PC User" wrote in message
news:1131069553.938580.188580@g44g2000cwa.googlegr oups.com...
> I'm trying to apply some code that I've found on Text Reading and
> Speech Recongnition. I don't know what version of VB that it was
> develop. I've posted my project that I'm working on and I was hoping
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
> someone could help me get it to work. It can be found at:
>

http://www.access-programmers.co.uk/...chmentid=11527
>
> The code is from:
> SAPI 5.1: Voice - Enabled Applications With VB
> By Peter A. Bromberg, Ph.D.
> http://www.eggheadcafe.com/articles/20011124.asp
>
> Thanks for your time.
> PC
>



Reply With Quote
  #3 (permalink)  
Old 05-Nov-2005, 12:48 PM
Tom Wickerath's Avatar Tom Wickerath
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

Hi Doug,

I downloaded PC User's sample last night and tried it in Access 2002. I
could not get it to work properly. I found something really strange. I could
get the btnReadToMe_Click() and btnSpeakToMe_Click() procedures to work, in
Access, only in break mode (ie. setting a break point and then executing each
line with the F8 key). When I removed the break point, I didn't hear anything:

Private Sub btnReadToMe_Click()
Dim Voice As SpVoice
Set Voice = New SpVoice
Voice.Speak Nz(Me.Text0, ""), SVSFlagsAsync
End Sub

Private Sub btnSpeakToMe_Click()
Dim Voice As SpVoice
Set Voice = New SpVoice
Voice.Speak "Hello. My name is Peter.", SVSFlagsAsync
End Sub

I converted the sample to Access 97. The same thing is happening....no voice
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
heard unless I run the code in break mode. In addition, I received an
ambiguous name detected error in Access 97 when I attempted to compile the
code. This occurred on the line of code that reads:

Dim WithEvents RecoContext As SpSharedRecoContext

which was found in two Private Subs. I commented out these two declarations
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
and moved this line of code to the top of the module, to declare this at the
module level. When I attempt to compile in Access 97, I'm now receiving
"Automation type not supported in Visual Basic" error on the following:

' the following is the event handler for the recognition event
Private Sub RecoContext_Recognition(ByVal StreamNumber As Long, _
ByVal StreamPosition As Variant, _
ByVal RecognitionType As SpeechRecognitionType, _
ByVal Result As ISpeechRecoResult _
)


In short, I'm not having much luck getting this to work in either Access 97
or 2002. I thought last night that perhaps this code only works in VB, not
VBA, but your mention that you can get it to work in Access 97 seems to
indicate that something else is the problem.

Is there any chance that you would be willing to post your working sample in
Access 97 to your web site?

Thanks,

Tom
______________________________________________

"Douglas J Steele" wrote:

I'm not about to download and open the attachment, but the code outlined in
the eggheadcafe article worked fine for me in Access 97, so I'd assume it'll
work in newer versions as well.

What problem are you having?

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)


Reply With Quote
  #4 (permalink)  
Old 05-Nov-2005, 12:49 PM
Douglas J Steele's Avatar Douglas J Steele
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

Actually, I noticed that too, so I removed the svsFlagsAsync parameter from
the invocation of the Voice.Speak method.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)


"Tom Wickerath" wrote in message
news6BD4FF9-D90F-4660-AF69-3E4772137691@microsoft.com...
> Hi Doug,
>
> I downloaded PC User's sample last night and tried it in Access 2002. I
> could not get it to work properly. I found something really strange. I

could
> get the btnReadToMe_Click() and btnSpeakToMe_Click() procedures to work,

in
> Access, only in break mode (ie. setting a break point and then executing

each
> line with the F8 key). When I removed the break point, I didn't hear

anything:
>
> Private Sub btnReadToMe_Click()
> Dim Voice As SpVoice
> Set Voice = New SpVoice
> Voice.Speak Nz(Me.Text0, ""), SVSFlagsAsync
> End Sub
>
> Private Sub btnSpeakToMe_Click()
> Dim Voice As SpVoice
> Set Voice = New SpVoice
> Voice.Speak "Hello. My name is Peter.", SVSFlagsAsync
> End Sub
>
> I converted the sample to Access 97. The same thing is happening....no

voice
> heard unless I run the code in break mode. In addition, I received an
> ambiguous name detected error in Access 97 when I attempted to compile the
> code. This occurred on the line of code that reads:
>
> Dim WithEvents RecoContext As SpSharedRecoContext
>
> which was found in two Private Subs. I commented out these two

declarations
> and moved this line of code to the top of the module, to declare this at

the
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
> module level. When I attempt to compile in Access 97, I'm now receiving
> "Automation type not supported in Visual Basic" error on the following:
>
> ' the following is the event handler for the recognition event
> Private Sub RecoContext_Recognition(ByVal StreamNumber As Long, _
> ByVal StreamPosition As Variant, _
> ByVal RecognitionType As SpeechRecognitionType, _
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
> ByVal Result As ISpeechRecoResult _
> )
>
>
> In short, I'm not having much luck getting this to work in either Access

97
> or 2002. I thought last night that perhaps this code only works in VB, not
> VBA, but your mention that you can get it to work in Access 97 seems to
> indicate that something else is the problem.
>
> Is there any chance that you would be willing to post your working sample

in
> Access 97 to your web site?
>
> Thanks,
>
> Tom
> ______________________________________________
>
> "Douglas J Steele" wrote:
>
> I'm not about to download and open the attachment, but the code outlined

in
> the eggheadcafe article worked fine for me in Access 97, so I'd assume

it'll
> work in newer versions as well.
>
> What problem are you having?
>
> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele
> (no e-mails, please!)
>
>



Reply With Quote
  #5 (permalink)  
Old 05-Nov-2005, 12:49 PM
Tom Wickerath's Avatar Tom Wickerath
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

Thanks Doug,

I'm now successful in getting two of the three command buttons on PC User's
sample to function correctly: the buttons labelled "Read" and "RD". These
buttons have the following two click event procedures, respectively:

Private Sub btnReadToMe_Click()
Dim Voice As SpVoice
Set Voice = New SpVoice
Voice.Speak Nz(Me.Text0, "")
End Sub

Private Sub btnSpeakToMe_Click()
Dim Voice As SpVoice
Set Voice = New SpVoice
Voice.Speak "Hello. My name is Peter."
End Sub

I haven't gotten his button labelled "WT" to function. The click event for
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
this button is apparently intended to write something to a file. However,
this is a great start.

Thank You,

Tom
____________________________________________

"Douglas J Steele" wrote:
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675

Actually, I noticed that too, so I removed the svsFlagsAsync parameter from
the invocation of the Voice.Speak method.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)


Reply With Quote
  #6 (permalink)  
Old 05-Nov-2005, 12:49 PM
Douglas J. Steele's Avatar Douglas J. Steele
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

Now that I'm home, I'll grab it and take a look.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)



"Tom Wickerath" wrote in message
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
news:954C887A-BE77-495C-B1B2-FFAF22AE6503@microsoft.com...
> Thanks Doug,
>
> I'm now successful in getting two of the three command buttons on PC
> User's
> sample to function correctly: the buttons labelled "Read" and "RD". These
> buttons have the following two click event procedures, respectively:
>
> Private Sub btnReadToMe_Click()
> Dim Voice As SpVoice
> Set Voice = New SpVoice
> Voice.Speak Nz(Me.Text0, "")
> End Sub
>
> Private Sub btnSpeakToMe_Click()
> Dim Voice As SpVoice
> Set Voice = New SpVoice
> Voice.Speak "Hello. My name is Peter."
> End Sub
>
> I haven't gotten his button labelled "WT" to function. The click event for
> this button is apparently intended to write something to a file. However,
> this is a great start.
>
> Thank You,
>
> Tom
> ____________________________________________
>
> "Douglas J Steele" wrote:
>
> Actually, I noticed that too, so I removed the svsFlagsAsync parameter
> from
> the invocation of the Voice.Speak method.
>
> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele
> (no e-mails, please!)
>
>



Reply With Quote
  #7 (permalink)  
Old 05-Nov-2005, 12:49 PM
PC User's Avatar PC User
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

Thank you for your discussion on my project. I made the demo that you
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
downloaded based on interpretation of the article by Dr. Bromberg. I
may not have explained the buttons adequately. The Read button is
"Read To Me" from what is typed in the textbox. The RD button is
"Speak To Me" from the text in the onClick event of the RD button.
The WT button is "Write My Speech" for speech recognition to type
in your spoken word into the textbox when you have a microphone
attached to the computer. This is Dr. Bromber's code to convert the
spoken word into written text.
All the issues that Tom brought up are the ones that I experienced and
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
the questions that he has asked are the ones that I would have asked
also. It looks as though we are making progress on this.

Reply With Quote
  #8 (permalink)  
Old 06-Nov-2005, 12:37 PM
Douglas J. Steele's Avatar Douglas J. Steele
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

Afraid I don't have a microphone handy, so I can't do much with the
speech-to-text functionality.

In the routine InitializeGrammar, reference is made to App.Path &
"\newnums.xml". This is supposed to be the XML file mentioned in the
article. You'll need to replace App.Path with a reference to the path to
where the file is. If want to point to the same folder where the MDB file
is, and you're using Access 2000 or newer, you can use
Application.CurrentProject.Path & "\". (If you're using Access 97, you can
use Left$(CurrentDb.Name, Len(CurrentDb.Name) - Len(Dir$(CurrentDb.Name))))

In addition to moving the line Dim WithEvents RecoContext As
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
SpSharedRecoContext to the top of the module (so that it applies to all
modules), I believe it's also necessary to move Dim Grammar As
ISpeechRecoGrammar

It looks as though there might be no way around the "Automation type not
supported" message in Access 97 for the RecoContext_Recognition sub. That
error doesn't occur in Access 2003, though, so if you're using Access 2000
or newer, I think you might be okay.

If I can steal my daughter's microphone sometime this weekend, I'll see
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
whether I can get any further.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)



"PC User" wrote in message
news:1131159699.461879.79380@o13g2000cwo.googlegro ups.com...
> Thank you for your discussion on my project. I made the demo that you
> downloaded based on interpretation of the article by Dr. Bromberg. I
> may not have explained the buttons adequately. The Read button is
> "Read To Me" from what is typed in the textbox. The RD button is
> "Speak To Me" from the text in the onClick event of the RD button.
> The WT button is "Write My Speech" for speech recognition to type
> in your spoken word into the textbox when you have a microphone
> attached to the computer. This is Dr. Bromber's code to convert the
> spoken word into written text.
> All the issues that Tom brought up are the ones that I experienced and
> the questions that he has asked are the ones that I would have asked
> also. It looks as though we are making progress on this.
>



Reply With Quote
  #9 (permalink)  
Old 06-Nov-2005, 12:37 PM
PC User's Avatar PC User
Guest
 
Posts: n/a
   
   
Re: SAPI 5.1: Voice - Enabled Applications

  Donate Today!  
I've made some progress, but I still need help. I'm trying to make the
voices change and I'm also trying to get it to recognize my speech
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
through a microphone. My current file is posted at:
http://www.access-programmers.co.uk/...chmentid=11551
Reference:: Sikh Philosophy Network http://www.sikhphilosophy.net/showthread.php?t=6675
and I'm using the documentation from:
http://download.microsoft.com/downlo...EN-US/sapi.chm

Thanks,
PC

Reply With Quote
   Click Here to Donate Now!

Support Us!
Become a Promoter!
Gurfateh ji, you can become a SPN Promoter by Donating as little as $10 each month. With limited resources & high operational costs, your donations make it possible for us to deliver a quality website and spread the teachings of the Sri Guru Granth Sahib Ji, to serve & uplift humanity. Every contribution counts. Donate Generously. Gurfateh!
ReplyPost New Topic In This Forum Stay Connected to Sikhism, Click Here to Register Now!

Bookmarks


(View-All Members who have read this thread : 0
There are no names to display.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Tools Search
Search:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On

» Gurbani Jukebox
Listen to Gurbani while surfing SPN!
» Active Discussions
sikhism need urgent advice.......
Today 10:03 AM
7 Replies, 87 Views
sikhism Who is "Mohan"?
Today 08:46 AM
22 Replies, 348 Views
sikhism How important is Matha...
Today 08:12 AM
59 Replies, 1,041 Views
sikhism ਨਾਮਾ
Today 06:37 AM
2 Replies, 53 Views
sikhism Sikh Diamonds Video...
Today 04:23 AM
6 Replies, 120 Views
sikhism Are Creator and Creation...
Today 01:30 AM
44 Replies, 2,837 Views
sikhism Herman Hesse,...
Today 00:54 AM
13 Replies, 230 Views
sikhism On a Scale of Most...
Yesterday 21:42 PM
30 Replies, 1,277 Views
sikhism I became victim by...
Yesterday 19:50 PM
0 Replies, 46 Views
sikhism Sikh Books downloads
Yesterday 15:39 PM
2 Replies, 66 Views
sikhism Salok Sheikh Farid ji...
Yesterday 09:35 AM
0 Replies, 47 Views
sikhism In Punjab, three farmers...
Yesterday 05:36 AM
0 Replies, 49 Views
sikhism Supernatural Sikhs, what...
Yesterday 03:45 AM
19 Replies, 416 Views
sikhism Sukhmani Sahib Astpadi...
26-May-2012 22:57 PM
0 Replies, 51 Views
Do You Think You Are...
26-May-2012 09:59 AM
94 Replies, 8,258 Views
» Books You Should Read...
Powered by vBadvanced CMPS v3.2.2

All times are GMT +6.5. The time now is 10:27 AM.
Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.5.2 Copyright © 2004-12, All Rights Reserved. Sikh Philosophy Network


Page generated in 0.52393 seconds with 30 queries