简体   繁体   中英

Update listbox in c# sql

Currently I created a wizard with a listbox. The listbox has a next and previous button. The listbox has thousands of items but the next and previous will show them 30 items at a time.

I am not using AJAX so the page reloads each time the button is being clicked. I don't want the page to reload everytime the user clicks next and previous. I thought of using AJAX.

Is there anyway I can prevent the page from reloading either by AJAX or a different way everytime the user presses next. Pressing next triggers a stored procedure which selects the next 30 items.

C#, SQL, ASP.NET, HTML, JavaScript

You can surely use jquery for this purpose. It will allow you to do an ajax request. In fact, ajax request can be done from a .Net page with even plain javascript and it has nothing to do with .Net version.

However, using jquery will make it easy and you will be able to easily populate the listbox using the results from server.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM