Skip to content

This article shows how you can populate MVC Listbox using jQuery and JSONResult. It uses static values and also shows with model values that can use database values.

Notifications You must be signed in to change notification settings

geeksarray/populate-mvc-listbox-using-jquery-getjson-and-jsonresult

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Populate MVC listbox using jquery getjson and jsonresult

This article shows how you can populate MVC Listbox using jQuery and JSONResult. It uses static values and also shows with model values which can use database values.

By using this repository code you will save Categories as JSON file and read it using jQuery getJSON method. This also helps you to read from Controller Action method that returns JSONResult.

Files

  1. Categories JSON file - has list of Categories in JSON format.
  2. Index HTML View - shows a ListBox filled from the values returned by JSONResult.
  3. Controller - Returns JSONResult to View.

ASP.NET MVC List box will be shown as

ASP.NET MVC List Box

For more info see - Populate ASP.NET MVC List box using jQuery getJSON or JSONResult

About

This article shows how you can populate MVC Listbox using jQuery and JSONResult. It uses static values and also shows with model values that can use database values.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published