Part 18- How to call a partial View using JQuery in ASP.NET MVC

  Рет қаралды 58,147

Technotips Ashish

Technotips Ashish

Күн бұрын

Пікірлер: 31
@aapkanigam
@aapkanigam 6 жыл бұрын
Can we reach 1000 likes on this video. Share this video among your friends and Give your suggestions on which topic I should make videos. Thanks
@saktiprasadswain6546
@saktiprasadswain6546 5 жыл бұрын
Thanks bro....
@saktiprasadswain6546
@saktiprasadswain6546 5 жыл бұрын
Ur code is so simple..Avg coder can understand
@gregnordeng9196
@gregnordeng9196 6 жыл бұрын
You are a great teacher. Very simple approach and easy to understand. Thank you for your videos!
@jericmangao5110
@jericmangao5110 4 жыл бұрын
Nice video . It was very helpful to me. Thank you so much for this.
@mastuero
@mastuero 3 жыл бұрын
Great!!!
@face1517
@face1517 4 жыл бұрын
I've been search edit using modal with id for 2 days but some other tutorials is hassle because them using 2 edit actionresult 1 for find id and 1 for edit record which is alot. accidentally i found this. this is what i want simple code but he get what i want. Thank you sir for this. anyway sir how to pass data from grind to textbox in modal? Thank you
@nelsonmohamie6438
@nelsonmohamie6438 4 жыл бұрын
Thank you sir....it helped alot
@shafeekcherpu1476
@shafeekcherpu1476 5 жыл бұрын
Awesome tutorial... thanks for the video
@aapkanigam
@aapkanigam 5 жыл бұрын
Thanks keep learning and sharing
@bilalyousuf6814
@bilalyousuf6814 7 жыл бұрын
Thanku sir for great explanation ,let me know one thing if only one record than why you used foreach and List Employee (in controller)
@aapkanigam
@aapkanigam 7 жыл бұрын
+Bilal Yousuf u can use them for list or single record ..
@jaxparrow1794
@jaxparrow1794 5 жыл бұрын
Thank you so much, Ashish! :-D Really helped!
@ceciliazhou1182
@ceciliazhou1182 6 жыл бұрын
Thank you for your video Ashish. I am actually have a problem when using ViewBag. The data is in the ViewBag in controller, while when i want to access that from the partial view, it failed all the time. in controller: ViewBag.field = formfield.field; In partial view: @ViewBag.field What is the problem? Would you mind helping me a bit about that?
@duncanmcdonald5250
@duncanmcdonald5250 6 жыл бұрын
Was there a reason you based you based the "ShowEmployee(int EmployeeId)" action in the controller on the "Index()" action and not, say, the "EmployeeDetail(int EmployeeID)" action created in Tut 8 and 9? You know that you should only get back ONE employee, so why assign it to a list? "EmployeeDetail(...)" also means you just create and pass a simple "EmployeeViewModel" to the new partial view, rather than using the ViewBag. The code I ended up with is... In "TestCotroller.cs": public ActionResult ShowEmployee(int EmployeeID) { MVCTutorialEntities db = new MVCTutorialEntities(); Employee employee = db.Employees.SingleOrDefault(x => x.IsDeleted == false && x.EmployeeId == EmployeeID); //Create a ViewModel for this employee EmployeeViewModel employeeVM = new EmployeeViewModel { Name = employee.Name, Address = employee.Address, DepartmentName = employee.Department.DepartmentName }; return PartialView("EmployeePartial", employeeVM); } Notice I pass the EmployeeViewModel object as an argument in the PartialView call. The code for "EmployeePartial" is shown below. In "EmployeePartial.cshtml": @model MVCTutorial.Models.EmployeeViewModel @if (Model != null) { Employee Name @Model.Name Address @Model.Address Department @Model.DepartmentName } The only adaption I would still like to make would be in the "ShowEmployee(...)" action if(employeeVM != null) { return PartialView("EmployeePartial", employeeVM); } else { return some meaningful view/raw html to put into the Modal section }
@navzme
@navzme 6 жыл бұрын
Thanks for awesome video
@rajeshroshan04
@rajeshroshan04 6 жыл бұрын
Nice video.
@narendarsingh4672
@narendarsingh4672 5 жыл бұрын
Sir,I request to u upload tutorial of how to use store-procedure instead of linq query
@anandkrishna7190
@anandkrishna7190 6 жыл бұрын
I have a small question as I want to send data from partial view to main view in mvc 5 could you please help on this
@kaushikbhadani4227
@kaushikbhadani4227 7 жыл бұрын
Fantastic,. Can you upload ur tutorial with Dependency Injection
@narendarsingh4672
@narendarsingh4672 6 жыл бұрын
Great
@aliraza66-h1b
@aliraza66-h1b 8 жыл бұрын
great..please make on email sending and opencart
@inancakcan6898
@inancakcan6898 7 жыл бұрын
Great! Thank you very much
@aapkanigam
@aapkanigam 7 жыл бұрын
+Inanc Akcan keep learning and sharing
@daviddonadze221
@daviddonadze221 6 жыл бұрын
Thank you so much
@anbuanbu6591
@anbuanbu6591 6 жыл бұрын
Hi bro, How to restrict access the jquery ajax method from browser console window... The problem is: everyone can just go to the console and make a loop around it and make that request a thousand time. how can i deal with this security problem.
@PUBG-pw8eo
@PUBG-pw8eo 5 жыл бұрын
you are greate
@ashishpatil9559
@ashishpatil9559 4 жыл бұрын
You should use font awesome
@narendarsingh4672
@narendarsingh4672 6 жыл бұрын
great
amazing#devil #lilith #funny #shorts
00:15
Devil Lilith
Рет қаралды 18 МЛН
Trick-or-Treating in a Rush. Part 2
00:37
Daniel LaBelle
Рет қаралды 43 МЛН
How Much Tape To Stop A Lamborghini?
00:15
MrBeast
Рет қаралды 89 МЛН
Ajax calls to .Net5 MVC Controllers (using JQuery)
12:07
Data Vids (Data Vids)
Рет қаралды 13 М.
THIS is how you use Partial Views in ASP.NET Core 6
10:06
tutorialsEU - C#
Рет қаралды 33 М.
How to use Tabs in ASP.NET CORE
8:10
ASP.NET MVC
Рет қаралды 33 М.
Part 17- What is Partial View in ASP.NET MVC | Interview Question
19:25
Technotips Ashish
Рет қаралды 37 М.
Partial View and Data Refresh #5
32:58
Startup & Code
Рет қаралды 4 М.
amazing#devil #lilith #funny #shorts
00:15
Devil Lilith
Рет қаралды 18 МЛН