我有一个SQL数据库应用程序,我想要合并语音搜索功能.我已经知道如何搜索数据库,但我不知道如何从数据库中的表格中创建语法.到目前为止,这是我的代码.
Dim WithEvents reco As New Recognition.SpeechRecognitionEngine
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
reco.SetInputToDefaultAudioDevice()
Dim gram As New Recognition.SrgsGrammar.SrgsDocument
Dim RecipeRule As New Recognition.SrgsGrammar.SrgsRule("recipe")
Dim colorsList As New Recognition.SrgsGrammar.SrgsOneOf(DataSet1.Table.ToString)
RecipeRule.Add(colorsList)
gram.Rules.Add(RecipeRule)
gram.Root = RecipeRule
reco.LoadGrammar(New Recognition.Grammar(gram))
reco.RecognizeAsync()
End Sub
Private Sub reco_RecognizeCompleted(ByVal sender As Object, ByVal e As System.Speech.Recognition.RecognizeCompletedEventArgs) Handles reco.RecognizeCompleted
reco.RecognizeAsync()
End Sub
Private Sub reco_SpeechRecognized(ByVal sender As Object, ByVal e As System.Speech.Recognition.RecognitionEventArgs) Handles reco.SpeechRecognized
Try
Me.TableTableAdapter.Recipe(Me.DataSet1.Table, e.Result.Text & "%")
Catch ex As …Run Code Online (Sandbox Code Playgroud) 我正在使用 wordpress 插件“WooCommerce Product Sort and Display LITE”,我在其中做了一些修改以适应我的网站,但不幸的是,由于插件自动更新到新版本,我的网站每晚都会崩溃,我必须从备份中恢复它。我想弄清楚如何禁用插件自动更新,但到目前为止没有运气。
我尝试将以下过滤器添加到主题中function.php:
add_filter( 'auto_update_plugin', '__return_false' );- 没有帮助
试图增加版本号 - 没有帮助
还试图从源代码中找到禁用更新的位置,但我对 php 没有深入的了解,所以我希望这里有人可以帮助我解决这个问题。