novice needs urgent help

Results 1 to 2 of 2

Thread: novice needs urgent help

  1. #1
    Join Date
    Dec 1969

    Default novice needs urgent help

    Hello all <BR>I am doing ASP for the first time and am Quasi familiar with HTML, i am running into a couple of <BR>problems , will greatly appreciate if you can help me. <BR><BR><BR>Functionality. <BR>In the first entry screen the first Product name gets from the database the list of all Products <BR>and after the user selects from the list a Product name, <BR>then based on the id of the Product the items combo box fills up with list of all itemss for that Product. <BR>Now when the user selects the items , and enters a year and then clicks submit he gets directed to the second form. <BR>Where he makes changes to a few fields,his able to change values of those fields only if it is the current year. <BR><BR>QUestions <BR><BR><BR>1.Event driving: a.How can after i select the Product name from combo box ,immediately the items box gets filled up? <BR>b. if the user selects the Product name, how can i pass the corresponding Product id hidden. <BR>the same with items, if the user selects items name how can i pass items id hidden <BR><BR>2. Dialog Boxes, After the user clicks on the submit in the second form, i want a little dialog box pop up and ask do u really want to save it or create it. with Yes, no,cancel options. <BR>How can i create the dialog box, <BR><BR>3. Readonly dyanamically <BR>can i set the value of the HTML field, to readonly or not dyanamically based on a certain condition <BR>in the script, i tried putting it in a variable and adding it, it does not seem to be taking it. <BR><BR>Thanks Much in advance

  2. #2
    Join Date
    Dec 1969

    Default Mostly JavaScript questions...

    1. &#060;SELECT ... onChange="this.form.submit();"&#062;<BR><BR>For an example of this, see my demo at (it is the "categories" demo as I recall).<BR><BR>In the *second* drop down list, you use<BR><BR>&#060;SELECT ... onChange="this.form.action=&#039;NextPage.asp&#039 ;;this.form.submit();"&#062;<BR><BR>That is, you change *which* page the form submits to and then submit it.<BR><BR>**********<BR><BR>2. Assuming you *use* a SUBMIT button...instead of using the onChange I showed just above...<BR><BR>&#060;FORM ... onSubmit="return confirm(&#039;Are you sure?&#039;);"&#062;<BR><BR>**********<BR><BR>3. Only MSIE supports a readonly or disabled property on form fields. To make something that works universally, you need to do things such as &#060;INPUT ... onFocus="this.blur();"&#062; which, if the user tries to click on the field, moves the cursor right back off the field, so no modification is possible.<BR><BR>*************<BR><BR>Since all except your first question don&#039;t have anything to do with ASP (and even it is only partially ASP), you might find more help in a JS forum. You might also want to visit and the JavaScript FAQ that they maintain. It would answer a *lot* of similar questions.<BR><BR>Good luck!<BR><BR><BR><BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts