Great video of how to do a somewhat complicated thing! Thank you for putting this on youtube for anyone to watch and learn from!! I struggled at first, but this works!!
I have implement use of Select2 instead of chosen and was badly stuck with multiple select list implementation in my application. Thanks you really saved my time and helped me a lot. Thanks and excellent tutorial. I have subscribed to your channel.
when clicked on the save button while using Multiple drop down feature, it is not storing the selected values in an array and posting back to controller, i can see only null values being passed instead to the array, Please help! also can I have checkbox for multi-select, and I also want to display values when selected as comma separated values instead of multiple buttons displayed inside the drop down field
how can i do this with database table. I have sql query and dont know how to use in Linq. in this query if i select department then related workstation populate in the second drop down with check boxes. SELECT DISTINCT Department.Name, Workstations.Name from Department inner join Workstations on Department.ID = Workstations.DepartmentID AND Department.id = ( CASE WHEN Department.id IN (5) THEN Workstations.DepartmentID End)
Hi sir After adding MultiSelectList, I am getting error "The parameter 'expression' must evaluate to an IEnumerable when multiple selection is allowed".
@Html.ListBoxFor(model => model.USER_ID, new MultiSelectList(Model.UserCollection, "USER_ID", "DISPLAY_NAME"), new { id = "multiSelectDropDown", multiple="multiple" }) My code
Thank you this is very helpful and informative, however how to implement the plugin in chat c# code using SignalR we want to get AspNetUser and Groups please help.
at 10:55 I'm getting the following errors : "CS1031: "The name "Html" does not exist in the current context". The same applies for "Model". I've been stuck for some time and been looking for solution with no result.
@@CodAffection Thanks for your reply. how can I write this query in Linq (SELECT concat ( Employee.Name , ' - ' , Department.Name) As SUBDEP FROM Workstations JOIN Employee ON Employee.ID = Department.ID ) both table do not have connection
Hello, I did everything what you've shown in your video, but I've got a error like Object reference not set to an instance of an object. Object reference not set to an instance of an object. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.NullReferenceException: Object reference not set to an instance of an object. Source Error: Line 14: Select Employee Line 15: @*Normal DropDown*@ Line 16: @Html.DropDownListFor(model => model.SelectedEmployeeIDs, new SelectList(Model.EmployeeCollection, "EmployeeID", "Name"), new { id = "normalDropDown"}) Line 17: Line 18: Source File: E:\VS_ASP_APPS\ChoseninMvc\ChoseninMvc\Views\Employee\AddOrEdit.cshtml Line: 16 Can you please help me fixed this errors?
goo.gl/bPcyXW : Buy me a Coffee
bit.ly/36IA1cH : AspNet Core MVC CRUD Operations
bit.ly/3Pn2S7y : Expense Tracker App in AspNet Core MVC
bit.ly/2yEPlpB : Convert MVC App to Single Page(jQuery Ajax)
bit.ly/403lUVC : MVC Login & User Registration
bit.ly/39B6xdh : Image Upload in AspNet Core MVC
bit.ly/30fPDMg : More MVC Tutorials
Great video of how to do a somewhat complicated thing! Thank you for putting this on youtube for anyone to watch and learn from!! I struggled at first, but this works!!
Thanks for your kind words.
I have implement use of Select2 instead of chosen and was badly stuck with multiple select list implementation in my application. Thanks you really saved my time and helped me a lot. Thanks and excellent tutorial. I have subscribed to your channel.
Thanks for your kind words. I appreciate that.
You are legend dude. Hats off to your Knowledge. May God bless u
Excellent Tutorial
Thank you so much. Very well explained. It was very helpful. Hats off.
Hi, how to allow user to type non-existing value so that we can add thw value on the fly?
Works like wonders for me !
Amazing. Very succinct and exactly what I've been looking for, for weeks!
what if i dont want to show id on the sql what if i want to show string values what should i do
Thank you so much !
This video was really helpful , thank you for uploading the same.
Why can I use [HttpPOST] but not [NotMapped] as Node Mapper ? NotMapped could not be found
How to get the Selected Value text as separated by comma. Plz help
THANKS
we can this in two lines with choosen
when clicked on the save button while using Multiple drop down feature, it is not storing the selected values in an array and posting back to controller, i can see only null values being passed instead to the array, Please help!
also can I have checkbox for multi-select, and I also want to display values when selected as comma separated values instead of multiple buttons displayed inside the drop down field
Thank you so much! This helped me a lot!
Glad it helped!
This is really useful
How to get values back in edit page?
How do I implement in .net core...thank you
how can i do this with database table. I have sql query and dont know how to use in Linq. in this query if i select department then related workstation populate in the second drop down with check boxes.
SELECT DISTINCT Department.Name, Workstations.Name from Department
inner join Workstations on Department.ID = Workstations.DepartmentID
AND Department.id = ( CASE WHEN Department.id IN (5) THEN Workstations.DepartmentID End)
Thank you very much, It's very useful ..
You are welcome :)
Hi sir
After adding MultiSelectList, I am getting error "The parameter 'expression' must evaluate to an IEnumerable when multiple selection is allowed".
@Html.ListBoxFor(model => model.USER_ID, new MultiSelectList(Model.UserCollection, "USER_ID", "DISPLAY_NAME"), new { id = "multiSelectDropDown", multiple="multiple" })
My code
Thank you this is very helpful and informative, however how to implement the plugin in chat c# code using SignalR we want to get AspNetUser and Groups please help.
Please can You Explain How to Show SelectedEmployeesIDs as a Names not a Values in the View Page ???? thanks a lot
Hi, what if the project is in .Net5 and it doesn't have ADO.NET Entity Data Model, is there an alternative?
.NET 5 CRUD is discussed here : th-cam.com/video/S5dzfuh3t8U/w-d-xo.html
Please check that.
didn't work for me I don't even get any error but nothing changed too...
You solved the problem?
may i know how to change chosen dropdown height?? thank you
at 10:55 I'm getting the following errors : "CS1031: "The name "Html" does not exist in the current context". The same applies for "Model".
I've been stuck for some time and been looking for solution with no result.
I also got the same problem as you, but i managed to fix it by turn off the visual studio and turn it on again, and don't open the page.
There no such a thing as DBModel for me, any help ?
Thank you very much! it's works
Glad you found the video helpful.
Thanks bro... But I have a problem when I use it on the modal view
after refreshing the database the new property that you add are gone every time when i refresh the database
thank you, it is a very very good,
you are welcome.
Can I combined two tables in one multi selected drop down? I need to use this for one of my project.
yes, just join them into one collection first.
@@CodAffection Thanks for your reply. how can I write this query in Linq
(SELECT concat ( Employee.Name , ' - ' , Department.Name) As SUBDEP
FROM Workstations
JOIN Employee ON Employee.ID = Department.ID
)
both table do not have connection
How do we search using datepicker in mvc?? Anyone with a link or can codeAffection do another video.
Hello,
I did everything what you've shown in your video, but I've got a error like Object reference not set to an instance of an object.
Object reference not set to an instance of an object. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
Source Error:
Line 14: Select Employee
Line 15: @*Normal DropDown*@
Line 16: @Html.DropDownListFor(model => model.SelectedEmployeeIDs, new SelectList(Model.EmployeeCollection, "EmployeeID", "Name"), new { id = "normalDropDown"})
Line 17:
Line 18:
Source File: E:\VS_ASP_APPS\ChoseninMvc\ChoseninMvc\Views\Employee\AddOrEdit.cshtml Line: 16
Can you please help me fixed this errors?
try with break point, find exact source of error .
Check your connection to database
Same error... can anyone help?
Does anyone get the same problem as me ?
System.ArgumentNullException: 'Value cannot be null.
Parameter name: items'
Check on the values from list and then check the Nullable Condition
hey is it solved?? and if yes then can you share the solution?
wow