I've been trying to correct errors in an ASP page that calls data from an Access database. See the earlier post titled "Data type mismatch...". I was unable to correct the problem, and am trying a different approach (which, obviously, I can get to work either, or I wouldn't be here! )
Here's the picture...our website has a list of projects. When the user double-clicks one of the projects a page pops up displaying data regarding that project. My ASP page worked fine when I had a single Access table...but for a variety of reasons I have split the data up into two. They are linked by the field Project_ID, which is an autonumber field in the main table (ProjectData), and a number field (foreign key) in the secondary table (Comments). A project has one set of data in the ProjectData table, but has multiple Comments (plus a Comment_Date) per project.
So I'm trying to accomplish two things: (a) get the popup page to display the data and the comments as it did when it was all on a single table, and (b) to create the Comment boxes dynamically, i.e. if there is one Comment for the project, then display one box; if there are six Comments for the project, display six boxes.
This is the code I currently have:
var Comment_String = '<TABLE BORDER="0" ALIGN="center" WIDTH="761" HEIGHT="100" CELLSPACING="0" CELLPADDING="0">';
Set rst = Nothing
Set rst2 = Nothing
Set Conn= Nothing
...and then the BODY, which creates the page, comes after this. When I run this page, the popup opens with the top half (the Project_Data) correctly populated, but then a second, separate popup appears that displays the HTML code, with the correct "Comments" plugged in. So although it's apparently pulling the data correctly, it's not building the second half of hte page where the "Comments" should appear.