listbox and sql stored procedure

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: John (stomss2003_at_yahoo.com)
Date: 06/30/04


Date: Wed, 30 Jun 2004 16:30:16 +0100

Hi,
First of all sorry for my not perfect english.

I've got listbox in my .aspx page where the users can make multiple
selection.
So, Users can select 7 items in listbox, I have to take value from items and
pass it to stored procedure to delete 7 rolls in my table. Thats simple,
but what if user select 3 or 30 items in listbox? The problem is that I dont
know the number of the parameters, and how to pass them. can I use array
or is there some different solution?

Of course I can take the collection of items and for every item, I can call
stored procedure, but this is no good in performance reason.
Please help me



Relevant Pages

  • Multiple Select listbox and sql stored procedure -Help needed
    ... I've got listbox in my .aspx page where the users can make multiple ... selection. ... 3.How to concatenate and send to SQL Procedure. ...
    (microsoft.public.dotnet.languages.csharp)
  • Multiple Select listbox and sql stored procedure -Help needed
    ... I've got listbox in my .aspx page where the users can make multiple ... selection. ... 3.How to concatenate and send to SQL Procedure. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: getting single selected value from listbox
    ... The combo is bound to a stored procedure but I only wish to obtain the value ... "Jeff Boyce" wrote: ... A listbox with, say, 4 fields displayed can have 17 fields, with a width ... I am not allowing multiple value selection so should ...
    (microsoft.public.access.forms)
  • databounded listbox with datagrid results complete description
    ... i have a databound listbox id "listboxcity" that has a multilple ... SqlDataReader citydr; ... till now it is working for single value selection and its succsseful ... Now how to make changes in it for multiple ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: looping through a listbox values in stored proc
    ... It's very straightforward and a requirement often come across by developers including myself (when I do ASP.NET coding). ... You have a listbox with multi-select and you need to get those optional vales into your query. ... Its an inflexible approach that definitively couples the application with the database stored procedure - if you need an extra value then you have to change the stored procedure which forces you through a change control and testing process; using any of the other methods Aaron posted you'd not suffer the same problem. ...
    (microsoft.public.sqlserver.programming)