error BC30451: Name 'voice' is not declared.
according to turtorials i have everything right, but i am still gettiing this error. here is my code;
Imports SpeechLib
Public Class Form1
Private Sub ReservButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ReservButton.Click
Dim ad As New Ad
Dim AdPrice As Double
If Not IsNumeric(TeleTextBox) And TeleTextBox.Text <> vbNullString Then
MsgBox("Sorry, only numbers allowed")
TeleTextBox.Text = vbNullString
End If
If Not IsDate(RundateTextBox) = False Then
MsgBox("Sorry, date format is mm/dd/yy")
RundateTextBox.Text = vbNullString
End If
' Radiobutton restrictions set
If InsdfrRadioButton.Checked = True Then
OutbkRadioButton.Enabled = False
End If
If BusRadioButton.Checked = True Then
IntpgRadioButton.Enabled = False
InsdfrRadioButton.Enabled = False
InsbkRadioButton.Enabled = False
OutbkRadioButton.Enabled = False
End If
' Make sure all Textbox's have been filled out
If CompTextBox.Text = String.Empty Or TeleTextBox.Text = String.Empty Or RundateTextBox.Text = String.Empty Then
MessageBox.Show(" You must enter all information", "Buzz Advertising", MessageBoxButtons.OK, MessageBoxIcon.Error)
End If
'Determine base price based on checked ad size radiobutton
If FullRadioButton.Checked = True Then
ad.Size = 225.0
End If
If HalfRadioButton.Checked = True Then
ad.Size = 225.0 * 0.65
End If
If QtrRadioButton.Checked = True Then
ad.Size = 225.0 * 0.4
End If
If BusRadioButton.Checked = True Then
ad.Size = 35.0
End If
' Determine markup based upon checked location radiobutton
If OutbkRadioButton.Checked = True Then
ad.Location = 1.4
End If
If InsbkRadioButton.Checked = True Then
ad.Location = 1.15
End If
If InsdfrRadioButton.Checked = True Then
ad.Location = 1.2
End If
If IntpgRadioButton.Checked = True Then
ad.Location = 1.0
End If
AdPrice = ad.CalculateAd()
If ad.Size = 35.0 Then
AdPrice = 35.0
End If
'Display total price and Text to Voice'
AdpriceTextBox.Text = AdPrice.ToString("C2")
voice.Speak("Your final ad price is" & AdpriceTextBox.Text)
the very last "voice.speak" is the problem child. anyone has any suggestions???

New Topic/Question
Reply




MultiQuote







|