Click here to Skip to main content
15,923,006 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How can I use "ISpTranscript" to train the speech recognition engine in C# for a word by a wav file?
I have a code that shows the use of "ISpTranscript" but it's for c++ programmers , can you convert it to C# code?

HRESULT hr = S_OK;

// Bind a stream to an existing wavefile
hr = SPBindToFile( FILENAME, SPFM_READ_ONLY, &cpStream);
// Check hr

hr = cpStream.QueryInterface(&cpTranscript);
// Check hr

PWCHAR pwszTranscript;
hr = cpTranscript->GetTranscript(&pwszTranscript);
// Check hr


thanks
Posted

You should perhaps do some reading on COM interop. All you need to do is add a reference to the COM object and you'll be able to create instances of the class and call it's methods.
 
Share this answer
 
Thanks my friend but can you say what exactly I have to do by code?
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900