Help on tripatches

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mfshake
    New Member
    • Nov 2007
    • 16

    Help on tripatches

    What are tripatches?
    i am seeing if i can do one on my program
    i have to make a user enter a balance and then make them withdraw or depoist
    if they over withdraw the balance, how do i ask them to insert a smaller numer?


    thanks
  • r035198x
    MVP
    • Sep 2006
    • 13225

    #2
    Originally posted by mfshake
    What are tripatches?
    i am seeing if i can do one on my program
    i have to make a user enter a balance and then make them withdraw or depoist
    if they over withdraw the balance, how do i ask them to insert a smaller numer?


    thanks
    Do you mean try/catch blocks?

    Comment

    • mfshake
      New Member
      • Nov 2007
      • 16

      #3
      Originally posted by r035198x
      Do you mean try/catch blocks?
      yea i just need to make a user enter a balance and then make them withdraw or depoist
      if they over withdraw the balance, how do i ask them to insert a smaller numer?

      Comment

      • r035198x
        MVP
        • Sep 2006
        • 13225

        #4
        Originally posted by mfshake
        yea i just need to make a user enter a balance and then make them withdraw or depoist
        if they over withdraw the balance, how do i ask them to insert a smaller numer?
        Have a look at this article

        Comment

        • JosAH
          Recognized Expert MVP
          • Mar 2007
          • 11453

          #5
          Originally posted by r035198x
          Have a look at this article
          Note though that incorrect user input does not necessarily lead to throwing all
          sorts Exceptions around. Simple if then else logic and proper decomposition
          in separate methods can do the same, and less expensive.

          kind regards,

          Jos

          Comment

          • r035198x
            MVP
            • Sep 2006
            • 13225

            #6
            Originally posted by JosAH
            Note though that incorrect user input does not necessarily lead to throwing all
            sorts Exceptions around. Simple if then else logic and proper decomposition
            in separate methods can do the same, and less expensive.

            kind regards,

            Jos
            Certainly. I'm still wondering what the OP means by "tripatches ". I've seen typos before but this one is new to me. That's why I haven't renamed the thread yet.

            Comment

            • JosAH
              Recognized Expert MVP
              • Mar 2007
              • 11453

              #7
              Originally posted by r035198x
              Certainly. I'm still wondering what the OP means by "tripatches ". I've seen typos before but this one is new to me. That's why I haven't renamed the thread yet.
              I don't know either; 'tripatch' sort of rhymes with 'try-catch' and the OP confirmed
              the correctness of your clever guess but ...

              kind regards,

              Jos

              Comment

              • r035198x
                MVP
                • Sep 2006
                • 13225

                #8
                Originally posted by JosAH
                ..... but ...

                kind regards,

                Jos
                Yep, this might turn out to be one of those where the relevant information is only released at the last minute ... as in the other thread.

                Comment

                • JosAH
                  Recognized Expert MVP
                  • Mar 2007
                  • 11453

                  #9
                  Originally posted by r035198x
                  Yep, this might turn out to be one of those where the relevant information is only released at the last minute ... as in the other thread.
                  Goodygoody! Another round of "Guess The Problem"! ;-)

                  kind regards,

                  Jos

                  Comment

                  Working...