Click here to Skip to main content
15,890,557 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Sherdian controls Pin
ZurdoDev15-Aug-14 8:19
professionalZurdoDev15-Aug-14 8:19 
GeneralRe: Sherdian controls Pin
zuber ahmed16-Aug-14 2:11
zuber ahmed16-Aug-14 2:11 
QuestionVBScript Error Code 800A0046 Pin
ChriDo6130-Jul-14 20:57
ChriDo6130-Jul-14 20:57 
AnswerRe: VBScript Error Code 800A0046 Pin
thatraja30-Jul-14 21:37
professionalthatraja30-Jul-14 21:37 
GeneralRe: VBScript Error Code 800A0046 Pin
ChriDo6130-Jul-14 22:16
ChriDo6130-Jul-14 22:16 
QuestionHow to pass selected row from datagrid view into microsoft reports Pin
chronos1329-Jul-14 1:20
chronos1329-Jul-14 1:20 
QuestionGuidance... Pin
Member 1072866725-Jul-14 20:21
Member 1072866725-Jul-14 20:21 
AnswerRe: Guidance... Pin
Member 1072866725-Jul-14 22:11
Member 1072866725-Jul-14 22:11 
This is what I have so far... Am I on the right track?

VB
Public Class frmSalesData
    Dim intCars, intTickets, intPopcorn, intCandy As Integer

    Private Sub btnExit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnExit.Click
        Me.Close()
    End Sub

    Private Sub btnClear_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClear.Click
        Me.txtNumCars.Clear()
        Me.txtNumTickets.Clear()
        Me.txtNumPopcorn.Clear()
        Me.txtNumCandy.Clear()
        Me.lblTotal.Text = Nothing
        Me.txtNumCars.Focus()
    End Sub

    Private Sub btnCalculate_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCalculate.Click
        Dim strMessage As String
        Dim dblNumCars, dblNumTickets, dblNumPopcorn, dblNumCandy As Double
        Dim dblTotalSales As Double

        If radRegular.Checked = True Then
            Me.lblTotal.Text = "Tonight was a REGULAR night."
        ElseIf radCar.Checked = True Then
            Me.lblTotal.Text = "Tonight was a CAR night."

        End If

        Double.TryParse(Me.txtNumCars.Text, dblNumCars)
        Double.TryParse(Me.txtNumTickets.Text, dblNumTickets)
        Double.TryParse(Me.txtNumPopcorn.Text, dblNumPopcorn)
        Double.TryParse(Me.txtNumCandy.Text, dblNumCandy)

        dblTotalSales = dblNumTickets + dblNumPopcorn + dblNumCandy

        strMessage = "The total number of cars present was: " & dblNumCars.ToString() & _
                     "The total number of tickets sold was: " & dblNumTickets.ToString() & _
                     "The total popcorn sales were: " & dblNumPopcorn.ToString("N2") & _
                     "The total candy sales were: " & dblNumCandy.ToString("N2")

        Me.lblTotal.Text = strMessage


    End Sub
End Class

GeneralRe: Guidance... Pin
Eddy Vluggen26-Jul-14 10:28
professionalEddy Vluggen26-Jul-14 10:28 
GeneralRe: Guidance... Pin
Mycroft Holmes30-Jul-14 22:56
professionalMycroft Holmes30-Jul-14 22:56 
Questionvb filter Pin
Member 1097008124-Jul-14 19:08
Member 1097008124-Jul-14 19:08 
AnswerRe: vb filter Pin
Karen Mitchelle24-Jul-14 20:05
professionalKaren Mitchelle24-Jul-14 20:05 
JokeRe: vb filter Pin
Richard Deeming25-Jul-14 1:41
mveRichard Deeming25-Jul-14 1:41 
GeneralRe: vb filter Pin
Karen Mitchelle27-Jul-14 14:45
professionalKaren Mitchelle27-Jul-14 14:45 
AnswerRe: vb filter Pin
Eddy Vluggen24-Jul-14 22:25
professionalEddy Vluggen24-Jul-14 22:25 
QuestionCompile Excel File to Exe and Hide Excel Formula but Exe file work as actual File Pin
DEWESH23-Jul-14 19:38
DEWESH23-Jul-14 19:38 
AnswerRe: Compile Excel File to Exe and Hide Excel Formula but Exe file work as actual File Pin
Richard MacCutchan23-Jul-14 20:39
mveRichard MacCutchan23-Jul-14 20:39 
QuestionUnable to emit referenced assembly "AxInterop.mswinsocklib" doesn't have a strong name Pin
vamsee0323-Jul-14 0:10
vamsee0323-Jul-14 0:10 
AnswerRe: Unable to emit referenced assembly "AxInterop.mswinsocklib" doesn't have a strong name Pin
thatraja23-Jul-14 1:01
professionalthatraja23-Jul-14 1:01 
Questionvisual basic script for subversion server side precommit hook script Pin
Member 1096343422-Jul-14 3:46
Member 1096343422-Jul-14 3:46 
AnswerRe: visual basic script for subversion server side precommit hook script Pin
Eddy Vluggen22-Jul-14 5:08
professionalEddy Vluggen22-Jul-14 5:08 
QuestionHelp! Pin
Member 1072866721-Jul-14 9:51
Member 1072866721-Jul-14 9:51 
AnswerRe: Help! Pin
Wes Aday21-Jul-14 10:51
professionalWes Aday21-Jul-14 10:51 
GeneralRe: Help! Pin
Member 1072866721-Jul-14 11:20
Member 1072866721-Jul-14 11:20 
GeneralRe: Help! Pin
Wes Aday21-Jul-14 11:32
professionalWes Aday21-Jul-14 11:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.