Delimters, Arrays, Variables

Results 1 to 2 of 2

Thread: Delimters, Arrays, Variables

  1. #1
    Join Date
    Dec 1969

    Default Delimters, Arrays, Variables

    The gist of this is a user can come to my web page, enter in their information. The user&#039s position title and report choices are passed to a stored procedure on the response page and depending on their selections, an e-mail will be sent to an appropriate party to grant the user access to these reports. I have the e-mail program hammered out. Everything works great but this:<BR><BR>I have this drop-down menu with multiple selection ability within each section ("3010", let&#039s say). The choices in the menu are database-generated report titles. The user can choose more than one report title, which is assigned to an array ("a3010").<BR><BR>My question is this:<BR><BR>1) How am I going to take these choices, split them up, assign each to a variable for use by a stored procedure on another page?<BR><BR>2) Am I allowed to choose what delimiter character to use?<BR><BR>3) The stored procedure only looks for one incident of report series (like "3010"). But I also have 3020 and 3600 report sections to worry about, and a user could very well choose reports from all three sections at one time. What do I do, run the stored procedure three times for each section? What&#039s the best way to handle this and return the results of each section into (and out of) the stored procedure?<BR><BR>I inherited this page and I&#039m not sure I&#039m savvy enough to figure out a better way than to use arrays, and the client is also excited to get this done, so I have to pretty much work with what I&#039ve got (although I&#039m always anxious to hear about better ways to do things for "next time").<BR><BR>I hope this makes sense.

  2. #2
    Join Date
    Dec 1969

    Default RE: Delimters, Arrays, Variables

    Ok...I&#039m not exactly sure where you&#039re at but here are a few things that might help.<BR><BR>First of all you can access the multiple selection from your form element with request.form("name").count and request.form("name")(index)<BR><BR>So maybe for each item in request.form().count you could execute your SP.<BR><BR>To pass an array to another page, you could choose a delimiter write out the delimited string and then use the VB split() function to recreate the array on the subsequent page.

Posting Permissions

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