Skip to Content
avatar image
Former Member

Make Push button to do AT EXIT-COMMAND

Is there a way to mimic, the exit command push button?

For example:

Input field1 _________ (required field)

PB_CONTINUE PB_EXIT

if the user clicks PB_CONTINUE -> the user asked to enter the input field1.

if the user clicks PB_EXIT -> the user did not asked to enter the input field1.

I only managed to get validation (using doValidate) for ALL push button.

Any idea?

Thanks,

Iwan

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Jun 16, 2004 at 11:30 AM

    Is this BSP related? If yes, give us maximum 25 line program to demonstrate the question.

    ++bcm

    Add comment
    10|10000 characters needed characters exceeded

    • Yes, I have an idea. It will be some work from yourside.

      Why not read all the appends in this forum for the last week or so? Somewhere there is a series of appends that describe how to intercept Javascript functions. What you want to do, is to intercept the htmlbSubmit function, and then do this same trick there. For signature, etc of this htmlbSubmit you will have to read the .js file we render.

      My personal opinion: this is becoming messy. Remove all this client-side validation. Just do it at the server, and if the values are not ok, return page with error message. The extra roundtrip is no problem, it is only in error case.

      ++bcm

  • avatar image
    Former Member
    Jun 17, 2004 at 01:12 PM

    Hi Brian,

    Thanks again for the tip. I was under the assumption that it's better do as much as possible at the client side, since there will be no communication to the server side. I guess, I was wrong 😊

    Regards,

    Iwan

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Brian McKellar

      Brian,

      As always, it's an excellent explanation you gave about round trip to server in the event of an error. Even in our applications mostly we do server side validations, some times it is not possible to have client side validation after submitting the request and prevent submitting half the way when error is detected at server.

      Could you please tell me why there is an error page in the BSP page/controller attribute and How to use it. Right now I am collecting all the errors from server and display them in the view usin textview control.

      thanks,

      suresh