Help with VB .net

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Mike Busch

    Help with VB .net

    I am a newbie, I have a project that askes for the name of the most pieces
    produced by an employee to be displayed when you click the calculate button.
    Ok here is is , I have the following text boxes and labels, txtName, and
    txtQuanity, and a label lblEarnedMost. A name is entered into the txtName
    and a quanity of Pieces Completed are entered into txtQuanity. Total earned
    is figured by Quanity * a constant Rate. There is a summary, for this
    project and they are asking for the Employee who earns the most. After you
    calculate the first employee you clear the two text boxes, then enter a new
    employee's name and quantity. I am having a problem of finding out which
    employees name will go into the lblEarnedMost.t ext. I created two variables,
    decMostEarned and decMostPieces. So I have a if statement that starts with
    the Variable for Quantity called decPiecesComple ted. So here is what I have
    so far.

    If decPieceseCompl eted > decMostPieces then
    ? = ?
    esleif ? ?
    lblEarnedMost.t ext = txtName.text
    End If

    Any help. thanks


  • Rick Rothstein

    #2
    Re: Help with VB .net

    Almost everybody here is using VB6 or lower. While you may get a stray
    answer to VB.NET questions here, you should ask them in newsgroups devoted
    exclusively to .NET programming. Look for newsgroups with the word "dotnet"
    in their name.

    For the news.devx.com news server, try these

    vb.dotnet.discu ssion
    vb.dotnet.techn ical

    For the microsoft news server, try these newsgroups...

    microsoft.publi c.dotnet.genera l
    microsoft.publi c.dotnet.langua ges.vb

    There are some others, but these should get you started.

    Rick - MVP




    "Mike Busch" <wizof103@veriz on.net> wrote in message
    news:k75fb.1847 8$yU5.14919@nwr dny01.gnilink.n et...[color=blue]
    > I am a newbie, I have a project that askes for the name of the most pieces
    > produced by an employee to be displayed when you click the calculate[/color]
    button.[color=blue]
    > Ok here is is , I have the following text boxes and labels, txtName, and
    > txtQuanity, and a label lblEarnedMost. A name is entered into the txtName
    > and a quanity of Pieces Completed are entered into txtQuanity. Total[/color]
    earned[color=blue]
    > is figured by Quanity * a constant Rate. There is a summary, for this
    > project and they are asking for the Employee who earns the most. After you
    > calculate the first employee you clear the two text boxes, then enter a[/color]
    new[color=blue]
    > employee's name and quantity. I am having a problem of finding out which
    > employees name will go into the lblEarnedMost.t ext. I created two[/color]
    variables,[color=blue]
    > decMostEarned and decMostPieces. So I have a if statement that starts with
    > the Variable for Quantity called decPiecesComple ted. So here is what I[/color]
    have[color=blue]
    > so far.
    >
    > If decPieceseCompl eted > decMostPieces then
    > ? = ?
    > esleif ? ?
    > lblEarnedMost.t ext = txtName.text
    > End If
    >
    > Any help. thanks
    >
    >[/color]


    Comment

    • Tony Vitonis

      #3
      Re: Help with VB .net

      It sounds as if this is a homework problem, so I hesitate to give
      anything like a full solution, but maybe some pseudocode will help:

      If the current employee completed more pieces than the most so far,
      then he's the new record-holder, so:

      Display his name
      Remember how many pieces he completed

      Otherwise

      The current employee's information is irrelevant, so forget it

      Remember that the most-pieces-so-far variable has to retain its value
      until you're done evaluating all of the employees.
      [color=blue]
      > Mike Busch wrote...
      >
      > I am a newbie, I have a project that askes for the name of the most
      > pieces produced by an employee to be displayed when you click the
      > calculate button. Ok here is is , I have the following text boxes and
      > labels, txtName, and txtQuanity, and a label lblEarnedMost. A name is
      > entered into the txtName and a quanity of Pieces Completed are
      > entered into txtQuanity. Total earned is figured by Quanity * a
      > constant Rate. There is a summary, for this project and they are
      > asking for the Employee who earns the most. After you calculate the
      > first employee you clear the two text boxes, then enter a new
      > employee's name and quantity. I am having a problem of finding out
      > which employees name will go into the lblEarnedMost.t ext. I created
      > two variables, decMostEarned and decMostPieces. So I have a if
      > statement that starts with the Variable for Quantity called
      > decPiecesComple ted. So here is what I have so far.
      >
      > If decPieceseCompl eted > decMostPieces then
      > ? = ?
      > esleif ? ?
      > lblEarnedMost.t ext = txtName.text
      > End If
      >
      > Any help. thanks[/color]


      Comment

      Working...