网络问题上的文本到语音 [英] text to speech on web question

查看:89
本文介绍了网络问题上的文本到语音的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这个代码,我在网上找到了Text To Speech!



代码在本地工作,但是如果加载到我的服务器,它会崩溃服务器的任何想法?

不确定什么我从本地到服务器缺少http://www.ralinder.com/talk1.aspx





i have this code i found on the web for Text To Speech!

The Code Works Locally but wen loaded to my server it crashes the server any ideas?
Not Sure What im Missing from local to server http://www.ralinder.com/talk1.aspx


using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Speech.Synthesis;
using System.Threading;

public partial class talk1 : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    protected void btmTalk_Click(object sender, System.EventArgs e)
    {
        try
        {
            System.ComponentModel.AsyncOperationManager.SynchronizationContext =
                new System.Threading.SynchronizationContext();

            SpeechSynthesizer synthesizer = new SpeechSynthesizer();
            synthesizer.Volume = 100;  // 0...100
            synthesizer.Rate = -2;     // -10...10

            // Synchronous
            //synthesizer.Speak("Welcome Guest To R A Linder.Com");

            // Asynchronous
            synthesizer.SpeakAsync("Welcome Guest To R A Linder.Com");
        }
        catch (System.Exception ex)
        {
            lblError.Text = ex.ToString();
            //throw;
        }

    }

}







System.Speech.Synthesis dll已到位错误来自





Sys.WebForms.PageRequestManagerServerErrorException




the System.Speech.Synthesis dlls is in place error is from


Sys.WebForms.PageRequestManagerServerErrorException

推荐答案

制作确定 System.Speech.Synthesis 服务器上可用的dll。
Make sure System.Speech.Synthesis dlls available on the server.


ty联系服务器!找出问题是否存在!
ty contacting the server! to find out if that is the problem!


这篇关于网络问题上的文本到语音的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆