Optional Fields In A Form, Converting To ASP And SQL
I am trying to incorporate a search feature, and I am having problems thinking up some code to accomplish a certain thing: I have a page that allows a user to search for Industry-specific locations.
It is a basic form with City, State, Zip, radius fields. I also want to incorporate optional fields, such as the different types of amenities/facilities that the building offers. These amenities/facilities will have checkboxes. Code:
Using ASP,VB Script,Access 2000. I have a macro which imports Fox Pro 2.6 databases into Access on a daily basis and then these tables are uploaded to the website.
When the tables are imported the fields which store numerical values with 2 decimal places are converted to text fields and it drops any zeros after the decimal point (e.g 124.40 becomes 124.4 and 110.00 becomes 100).
I am querying these new tables in my ASP pages but I want to convert these text fields back into numerical values with two decimal places. This is so that product price list on my page is all formatted the same. Is there a function I can use in my SQL statement to achieve this, or will I have to run a macro which re-designs the tables before I upload them to my website?
I have an Access application which need to be converted to asp-sql server application. This Access application uses a single form. This form has got a SS number with names and age.
The form has two subforms. One of the subform uses a physical test score which is basically four different fields while the other subform is one that has a written test score with three fields. Entry to both physical and written scores are done through this form. Both the forms can have multiple entries to make sure we are tracking historical scores.
The relationship between the ssn table and the physical test score table is 1: n while that between ssn table and the written score table is 1: n. With this scenario what is the best way to design form in asp pages?
I have a form which submits to my ASP page, which uses the Persits ASPupload. When using the form, it works great. I want to run the submission from a program on a client instead of through IE. I am having trouble converting the form to VBS. Here is the form: Code:
Would anyone be able to give some guideance in ASP code as to how I would repeat a section of input fields in a form based upon the number of guests that are attending an event?
Basically, what needs to happen is if 3 guests are attending, I need the Name, address, city, state fields to repeat so they can be filled in with information.
Then all of the information from the whole form is submitted which returns an email to the administrator of the event.
I like to validate 2 textboxes. Users ken choose to enter either one. Therefore if nothing is entered for both, im suppose to prompt him to enter at least one. If he enters value into both txt boxes, I'll prompt him again. Dunno to post this here or @ javascript forum.
I have an asp page which has a number of form fields on it (about 50). 2/3rds of these fields are used to store username (windows username) and date (todays date). I want these fields to be locked so the user cannot enter any info into them. The infor will be grabbed from the current user and the current date.
However, I only want these fields to be populated only when the left most field is changed. Once the fields have been populated the username and date fields will change with however is logged in and the new date.
I have a form that will be filled out by users, what I would like to do is when the user selects a state from a dropdown list i want to have the City field show select options based on their state. I know this can be done but I dont remember how.
next response.write(myVariable) The problem with that is that response.write(myVariable) only prints the last field in the form.
I know that if I move the response.write(myVariable) INSIDE of the loop it will print correctly but I am not trying to print the form fields BUT I AM TRYING to store them in ONE variable.
Code to email form data via ASP. Forced to use CDOSYS by 2003 server at host. It sends an email fine, but the form data is missing. Where my going wrong? Could it be the html file's form actuating the .asp file? Could it be an enctype issue? Or bad ASP syntax... Code:
I have about 30 names of workers (and their IDs in hidden fields, that depend on their departments) in one form, beside them there is one dropdown list for each worker, with same items. I want to select item from dropdown list for each worker, that will write item ID in another hidden field... and then I want to submit worker's ID, ID from dropdown list etc....into another .asp page and sql db. If I use next way : <% FOR EACH name IN Request.Form Response.Write("<BR>") Response.Write(Request.Form(name)) NEXT %> I get only values of IDs from dropdown lists. But I need workers' IDs, too.
how can I send the whole form using the script below, without listing every NAME of the form. Basically I wondered if you can just put a certain code in that will send all the fields of the form without putting each NAME of the fields down indiv individualy??
My forms Name is 'conf', so I was wondering if there was a code like SENDWHOLEFORM="conf", (I know it obviously won't be that, but just to put the point across!)
<% DIM strNAME, Mailer strFirstName = Upload.Form("NAME")
I have about 30 worker names (and their IDs in hidden fields) in one form, beside each worker I have a dropdown list with same items. When I select an item from dropdown list its ID is written in another hidden field. I want to submit values from hidden fields into another .asp page and sql db. If I use :
<% FOR EACH name IN Request.Form Response.Write("<BR>") Response.Write(Request.Form(name)) NEXT %>
I get only values from dropdown lists IDs. how to loop through all fields and get IDs of workers, too.
I have created an email form in which all fields must be completed. If all the fields are not completed "submit" causes a refresh using response.redirect, Problem is allthe fields that were previously filled in are empty.How do I keep the values of the fields on refresh?
I have a form submitted with a form field called contents. This could have loads of text in. What i need to do is scan this field for words that match the text in a database record called PAC_WORD. This could match 3 or 4 of the words put. Basically for each word picked up I want to write " This item found is not allowed
I have a asp page that has a form that I have to submit to a third party website.if their is a way to create form values using asp to submit the secure data without having it in a hidden field where it can be seen when viewing page source?
Currently I have my asp code writing out hidden form fields using the response.write when the page loads then after everything is loaded JavaScript submits the form.
I am creating a form that uses a postcode lookup that opens in another window to confirm an address how would I pass back the address and populate the form?
I have a web form which is quite long. My first field is required. If my user submits the form the page just sits there and the do not see my validation message at the top of my page. how I can reposition teh page so they see teh message i.e.scroll back up the page?
i wrote a script in asp/vb script that validates form fields. all works fine, apart from the fact that alerts are being shown against the empty form fields when the page loads the first time.
so, validation should not be carried out when the page loads the first time. my friend challenged me and said i can achieve this "using a hidden form field or even the submit button" and submitting the page to itself
i was more thinking of using session variables or a session cookie, but does anyone know how you could accomplish this using a hidden form field?
Here's what I want to do ... or here's my problem. I have a 'ICQ' on my user's profile, so it's a number, now when I update the database it DOES NOT use the single quotes, so it looks like:
Now, the prob with it is when a user DOES NOT type anything in it, since he doesn't have a ICQ number, then it gives a syntax error because your inserting nothing without any single quotes. How do i fix it? Or how can I NOT make it update if it doesn't have anything in the text box?
have a problem of concantenating two form fields. I have 3 text boxes,which is supposed to grab the user date of birth information. One text box for the day, the other for the month and last one for the year.
I want a situation where i can just concantenate them into one variable to be picked up by my sql query like this 04-05-1982 into an access database. Now this is my code: PHP Code:
I can get all fields, but how do I not get the button in the loop
Dim FormFields Set FormFields = request.form Dim Field if request.form("Button2") = "Update Order" then For each Field in FormFields response.write Field & " = " & Request.Form(Field) & "<br>" Next end if
I'm working on a form where if a client makes an entry in one field, it causes another field to become unusable. The fields most likely will be drop-down lists. The form will be filled out online then mailed to me using the post method.