I am working on a site with MS Access and ASP that needs to have data selected from a listbox, populate several span fields. I can do it with JavaScript but the array data is hard coded, I want the data brought in dynamically from an Access database. Here is my JavaScript code:
I m trying to use select statement in order to select a distinct word like 'c', but in the database i only want to select c when it occurs on its own not when it appears in another word.
eg i need to select the alphabet 'c' in 'the cat category is c' but not the 'c' in 'cat' or 'category'. I have used the code below but this seem to count all 'c'
select set rsTypes2 = con.execute("SELECT COUNT(two) AS total FROM march where two like '%c%'")
When the user clicks on this link I make a <span> visible.
Within my span I have a series of textboxes.
In Netscape 6.0 and 7.0 these textboxes are invisible. When I set focus to them and start typing they come visible. Any ideas why this is? I can see teh cursor flashing in the textbox but the textbox is invisile.
Having type something and tabbed out the become visible?
I am building a site in which users will submit articles. Like a cms. However, I want the ability for articles that are over one page long to span or continue on the next page. That is, a link is provided at the end of page 1 that links to page 2 etc of same article?
I have 4 response writes in a row and I want to distinguish between them better, so I want to wrap them in a span tag. What is the correct syntax. Code:
I nwant to pull out the description form the table orders where the first letter is A. I dont have any script tried, because I dont have a clue, I was told it's simple to do though.
strquery = SELECT description FROM orders WHERE ...?
-- I have a database with user records (name, photo, etc. etc.)
I want to use asp to generate (on the homepage) a series of 4 randomly selected 'user records' from the database -- say just the headshot photo or name from the database.
In addition to the recordset being randomly generated (i.e. our of about 50 records, only records 4, 18, 23 and 26 are displayed) I need to MAKE SURE they are not duplicated (i.e. out of the 50 records, records 4, 18, 23 and 23 -- where the last two are duplicates).
Is there a way I can pull this off and how do I go about it exactly?
I'm building a form select from a record set and then using the selected result to call another record set. This a maybe a dumb problem but it has me stumped. The first record always has a comma after it, theres no comma in the database and no comma in the code. Can someone tell where this comma is coming from? Code:
I am looking for the basic code to open, select and close a mySQL database using asp code. I am experienced in php and have a site using php to access this database but this client would like one page using asp.
Does anyone know how to update a session variable to the database.
I can get the session variable to appear on the screen but I can't seem to get it to be send to the database using a form and hidden fields. Does anyone know how to go about this. What do I need to do to maken it work. I'm using ASP/ VBScript & an access database.
I have an asp page that has a function that connects to an Access database. I am using Javascript. Is there any way to reference the field name in the database through a variable in a sql statement? Code:
Is there any way you can put a variable in the values in an update command?
If oRS("n4") <> 0 then Response.Write ("<tr>") Response.Write ("<td>4</td>") Dim qn4 qn4 = oRS("n4")*intQuantity strsql = "INSERT INTO report (q1) VALUES (qn4)" Set oRS2 = oConn.Execute(strSQL) Response.Write ("<td>Meter box, meter and test block</td>") Response.Write "<td>" & oRS("n4")*intQuantity & "</td></tr>" end If
i'm new here and i'd like to ask if there's someone who knows how to compare date() function and date from database with date/time type inside select statement so i don't have to do if..then..else
I have an array in ASP and I am populating the array with the values from database on checking a condition. Lets say i have array of arr(5). Initially I made all the array items null ...
I have an array in ASP called WordsArray() which contains several words. What I would like to do is search the array for a word, and if its not there, add it to another array ResultsArray()
So far, a loop in my code only checks the current array value, and not the rest of the array, adding the search word to the end of the resultsArray regardless.
I have two related tables in my database. One stores events and the other stores a list of key topics.
I have an interface set up where users can add / edit events.
In the add event page, I am querying the "key topics" table and returning them as options (array of checkboxes). The user makes their pick, and submits. All the data saves in the 'event" table, including the primary id of the "topics".
That part works great. The problem I am having is when the EDIT event page resolves, I am trying to "check" the options that were previously saved.
First thing I do (at the top of the page) is to query the events table to pull all of the data out. I use the 'events" table to do this.
For the checkboxes, I am once again looping through them in a query that uses the "key topics" table. So the boxes are displayed, but I can't seem to get the logic right to have the appropriate ones checked. here is my current code:
i want to create a dynamic list or array in asp as we have arraylist in asp.net. what i want is that i want to hold the values selected by the user in a list and in advance i dont know that how much values the user will select. i also tried to use array with redim but that did not work as we can create array with only constant integer parameter.
at the moment i am creating a shopping cart of sorts. Simply the user selects the check boxes of the items he wants and clicks submit. The items are dynamically created and they could select anything from 1 to 100 items..
so processing the form is clear not possible by hard coding. How could i read all the values from the POST into an array instead of processing each item at a time.