in

Quark Forums

How can i make a check on empty fields in a form with a pop-up warning

Last post 08-12-2011 6:10 AM by Matthias Guenther (Quark). 10 replies.
Page 1 of 1 (11 items)
Sort Posts: Previous Next
  • 07-13-2009 1:45 AM

    How can i make a check on empty fields in a form with a pop-up warning

    Hello, Does someone know how i can make a form (e-mailform) with fields that have to be filled in. So if someone leaves the field empy and pushes the submit button a warning pop-up with a message. I'll like to use it on my website on the e-mailform. This is the link to it. http://digital2solutions.nl WIth Kind regards, from Holland
    With kind regards

    Frans van Huizen
    Digital Solutions
  • 07-13-2009 2:04 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hoi, Frans,

    yes, with Interactive layout you can make a form (in SWF, so Flash) that has text fields and you can check the validity of the fields and onyl then fire it off to a web server.

    Is a Flash form what you are looking for? 

    Groetjes
    Matthias

    Matthias Günther
    Senior Product Manager
    Quark Software Inc.

    (Please note: As I am traveling and do not have access to the forums, I will not be able to respond to forum posts currently.)


    Want to easily publish for the iPad, using high-fidelity designs with stunning interactivity? See here:
    English: http://youtu.be/Gldk5lvXXTA
    French: http://youtu.be/nsgB4Q7lQzg
    German: http://youtu.be/lecdenqaUGY
    Italian: http://youtu.be/wjBpYZsF-8s


    Need immediate help? Please contact Quark's support: http://support.quark.com/contact_us.html

  • 07-15-2009 12:18 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hi, Frans,

    Frans van Huizen:
    Maybe you have a pre-confired sample ( if a field is empty a message alert)
     

    It is actually quite easy, if you just want to look for "not empty". It gets a bit more difficult if you want to check for valid email address or so.

    Not empty check:

    Prerequisiste: An editable text box (named datafield) and a submit button.

    When you press the submit button, run the following check (script):

    Control > If Expression datafield.GetText() == ""
    <Do something> (beep, display error message etc.)
    Control > End If

    And you are done!

    Best
    Matthias

    Matthias Günther
    Senior Product Manager
    Quark Software Inc.

    (Please note: As I am traveling and do not have access to the forums, I will not be able to respond to forum posts currently.)


    Want to easily publish for the iPad, using high-fidelity designs with stunning interactivity? See here:
    English: http://youtu.be/Gldk5lvXXTA
    French: http://youtu.be/nsgB4Q7lQzg
    German: http://youtu.be/lecdenqaUGY
    Italian: http://youtu.be/wjBpYZsF-8s


    Need immediate help? Please contact Quark's support: http://support.quark.com/contact_us.html

  • 08-11-2011 4:00 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hi Matthias,

     

    How would this apply to a drop down menu option?

    If the first option is "Please Select:" and I want the script to stop if the field contains "Please Select:" (i.e. no option has been selected)

     

    I have used this expression in my script

    ...

    Sector.GetText()="Please Select:" - Check that the field does not contain "Please Select:"

    Show Object "sectorrequired"- show a text box which says "required field"

    Stop Script "Datasubmit"

    End If

    ...

    but it does not work.

    Any advice??

  • 08-12-2011 3:32 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hi jayntree,

    "Stop Script" probably is the wrong method, unless the other script is already running.

    Can you please let me know a bit more about the two scripts you are using so that I can comment on this?

    Thanks
    Matthias

    Matthias Günther
    Senior Product Manager
    Quark Software Inc.

    (Please note: As I am traveling and do not have access to the forums, I will not be able to respond to forum posts currently.)


    Want to easily publish for the iPad, using high-fidelity designs with stunning interactivity? See here:
    English: http://youtu.be/Gldk5lvXXTA
    French: http://youtu.be/nsgB4Q7lQzg
    German: http://youtu.be/lecdenqaUGY
    Italian: http://youtu.be/wjBpYZsF-8s


    Need immediate help? Please contact Quark's support: http://support.quark.com/contact_us.html

  • 08-12-2011 3:58 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hi Matthias,

    The 'Stop Script' action is being used to stop this script. Therefore, once the submit button is pressed, it activates this script and if one of the 'required' fields is left blank, it shows a'required' text box object and stops the script from continuing.

    The script works great for Manual Text boxes - it should do, I borrowed it from one of YOUR excellent tutorials Smile but it does not work for a drop-down form box.

    What I need it to do is...

    I have a form, most of the boxes are text boxes, but 2 of the 'required' fields are drop down menu boxes.  These boxes (for clarity) have the first menu item as "Please Select:" So I assumed that the script would simply GetText from that box and if it still said "Please Select:" then it would stop running the script, until another option was chosen.

    Hope this maks more sense, I'm still learning scripting and explaining it is, at present, not very easy!!

    Thanks

    Jamie


     

     

  • 08-12-2011 4:33 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hi Jamie,

    now I understand.

    I am not sure that a Popup menu is a textbox. And you seem to miss an IF statement.

    You could fix it this way: Create another text box for yourpopup menu, called "Field1checker" or whatever.

    Then your script should be:

    Hide "Warning box"
    "Popup > Get Selection", "Your menu", "Item Name", "Field1checker", "Replace All".
    If Field1checker.GetText == "Please Select..."
       Show "Warning box"
       End Script "this"
    EndIf
    If Field1checker.GetText == ""
       Show "Warning box"
       End Script "this"
    EndIf

    Does that work?

    Thanks
    Matthias

    Matthias Günther
    Senior Product Manager
    Quark Software Inc.

    (Please note: As I am traveling and do not have access to the forums, I will not be able to respond to forum posts currently.)


    Want to easily publish for the iPad, using high-fidelity designs with stunning interactivity? See here:
    English: http://youtu.be/Gldk5lvXXTA
    French: http://youtu.be/nsgB4Q7lQzg
    German: http://youtu.be/lecdenqaUGY
    Italian: http://youtu.be/wjBpYZsF-8s


    Need immediate help? Please contact Quark's support: http://support.quark.com/contact_us.html

  • 08-12-2011 6:03 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Absolutely Brilliant,

    I'd never noticed the  'Get Popup Menu Selection' action.  That is a godsend -I assume that can be used, in some way, to create a "Thank You, [firstname] [lastname]" confirmation box. I'll try that next...

    I did have to amend your script slightly by replacing '=' with '==' in both 'If' lines (don't know the difference but I know it works!!)

    Many, Many Thanks,

    Your help today has been fantastic.

    Jamie

    (If your interested the website is www.swiftuk.co.uk/tradeshow)


  • 08-12-2011 6:05 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hi Jamie,

    jayntree:
    I did have to amend your script slightly by replacing '=' with '==' in both 'If' lines (don't know the difference but I know it works!!)

    Of course. How embarrassing, I even held a seminar about this once. Thanks for catching that, I just used my (aging? ;-) memory.

    Regards
    Matthias

    Matthias Günther
    Senior Product Manager
    Quark Software Inc.

    (Please note: As I am traveling and do not have access to the forums, I will not be able to respond to forum posts currently.)


    Want to easily publish for the iPad, using high-fidelity designs with stunning interactivity? See here:
    English: http://youtu.be/Gldk5lvXXTA
    French: http://youtu.be/nsgB4Q7lQzg
    German: http://youtu.be/lecdenqaUGY
    Italian: http://youtu.be/wjBpYZsF-8s


    Need immediate help? Please contact Quark's support: http://support.quark.com/contact_us.html

  • 08-12-2011 6:07 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

     e-Seminar8 by any chance!!!Big Smile

  • 08-12-2011 6:10 AM In reply to

    Re: How can i make a check on empty fields in a form with a pop-up warning

    Hi Jamie,

    jayntree:
    (If your interested the website is www.swiftuk.co.uk/tradeshow)

     

    Interesting design, it looks almost like a Tablet App.

    One tip: You might want to set the cursor to OS (in preferences), otherwise it sometimes doubles up.

    Thanks
    Matthias

    Matthias Günther
    Senior Product Manager
    Quark Software Inc.

    (Please note: As I am traveling and do not have access to the forums, I will not be able to respond to forum posts currently.)


    Want to easily publish for the iPad, using high-fidelity designs with stunning interactivity? See here:
    English: http://youtu.be/Gldk5lvXXTA
    French: http://youtu.be/nsgB4Q7lQzg
    German: http://youtu.be/lecdenqaUGY
    Italian: http://youtu.be/wjBpYZsF-8s


    Need immediate help? Please contact Quark's support: http://support.quark.com/contact_us.html

Page 1 of 1 (11 items)
Powered by Community Server (Commercial Edition), by Telligent Systems