Part 11 Using business objects as model in mvc

  Рет қаралды 468,980

kudvenkat

kudvenkat

Күн бұрын

Пікірлер: 114
@aiyka_music
@aiyka_music 10 жыл бұрын
Previously in your models folder you had a Context Class which had properties of type DBSet. Is that not required over here anymore? Why not ?
@wolv12458
@wolv12458 9 жыл бұрын
Because he implemented his own data access logic here using ADO.Net instead of using the Entity Framework used perviously, which is where the DBSet derives from.
@egl2004
@egl2004 8 жыл бұрын
I thought that every video built on the same ongoing example as the one before it. Is that not the case? He's using the same name, "MVCdemo". I'm struggling with the connection string issue as well. ??
@jerds_6885
@jerds_6885 8 жыл бұрын
If It can help you, I'm using this connection string in web.config file at the root of the project and it's working well for me:
@8starsAND
@8starsAND 7 жыл бұрын
Really appreciate your work. People like you can change the world, it's really important for me to share your experience to the others, not necessarily for money. Thank you!
@Csharp-video-tutorialsBlogspot
@Csharp-video-tutorialsBlogspot 11 жыл бұрын
Thank you very much for taking time to give feedback. In the description of this video, I have included the link for ASP .NET, C#, and SQL Server playlists. All the videos are arranged in logical sequence in these playlists, which could be useful to you. Please share the link with your friends who you think would also benefit from them. If you like these videos, please click on the THUMBS UP button below the video. For email alerts, when new videos are uploaded, you may subscribe to my channel.
@naodagere8210
@naodagere8210 4 жыл бұрын
One of the many unique features of Ven ppts are how they are connected (flow). He show us the problem in the preceding part and present us the solution in the upcoming.Great Work!
@MegaEengineer
@MegaEengineer 4 жыл бұрын
THIS GUY IS A LEGEND - I recommended his videos to everyone. Fantastic 10 out of 10
@premasuthar8023
@premasuthar8023 6 жыл бұрын
Everyday I watch one tutorial and it teaches me alot... thanks for such an amazing tutorials. God bless you Venkut.
@alejandrojimenezvalverde269
@alejandrojimenezvalverde269 9 жыл бұрын
I've learned so much with all your tutorials. Thanks for share your knowledge
@vipintp4118
@vipintp4118 9 жыл бұрын
All ur videos are superb... very useful, easy to understand. thank you very much.. God Bless
@lavishrich
@lavishrich 9 жыл бұрын
i am moving to mvc been looking into how logic is written in mvc and the 3 tier architecture.....this video helped!
@niclasj2373
@niclasj2373 11 жыл бұрын
I just signed in and created a account to say Thank you!
@mihrabhena3550
@mihrabhena3550 6 жыл бұрын
your videos are really helpful. Its better to watch your videos here than to pay money on online tutorials.. Thanks
@MKhizarBajwa
@MKhizarBajwa 7 жыл бұрын
Hello I have an ambiguity that as EF bulid on ADO.net then why we are using ADO.net instead of EF .....? this making me really confuse ........ Kindly replay ASAP Thank you
@remiduplan8449
@remiduplan8449 6 жыл бұрын
no worry, he shows different way to do it the EF way, and the Ado.net way.
@techtalksabhishek
@techtalksabhishek 6 жыл бұрын
The only reason to use EF is to make use of abstraction and to make use of strongly typed models. If we use ADO.NET we need to be cautious as no compile time errors can be caught. Lets say you have made an error in SQL query while performing an ADO.NET action this error can only be caught at runtime as this error will be thrown once the call goes to SQL server. Such kind of issues can be avoided if we use EF. EF has its own limitations as its not good for handling operations on huge datasets. If you have huge datasets its always advisable to use ADO.NET. You can also try using Dapper from Stackoverflow as I heard its really good ORM alternative to EF.
@jasonpacia7603
@jasonpacia7603 7 жыл бұрын
Tnx sir Kunvenkat, First I run into problem regarding the connection string, but when I visit here, I realize that I forgot to go into step 7..... You're are really great. Thanks a lot....
@sandeepmittapally2289
@sandeepmittapally2289 10 жыл бұрын
hi sir am getting issue (10:44 )when am adding business layer reference to Project,it will not adding
@shariaretanvirakash8716
@shariaretanvirakash8716 9 жыл бұрын
sandeep mittapally i am also facing the same problem. u solved this problem? please help
@ashwinsudhini
@ashwinsudhini 9 жыл бұрын
u made things simple n easy...good job..very helpful
@babitapoola8041
@babitapoola8041 11 жыл бұрын
i have tried this tutorials m getting an error on the line SqlDataReader rdr = cmd.ExecuteReader(); called An unhandled exception of type 'System.StackOverflowException' occurred in System.Data.dll. plz help me out!!!!
@vladimirx84
@vladimirx84 10 жыл бұрын
I have the same /&/((&#$ problem, Can you resolve it?
@ShavetaChatak
@ShavetaChatak 9 жыл бұрын
babita poola Check your EmployeeBusinessLayer class, and check what you are returning. it should be List object, you are probably returning property itself (may be type mistake)
@egl2004
@egl2004 8 жыл бұрын
Hello Venkat. Thank you very much for these videos. I greatly appreciate it. Is there a quick way to determine in the beginning of the video if it's a continuation of the same app from a previous video or if we're starting a new app? In Part 11 of MVC the app still has the same name and the prerequisites are listed as videos 8,9 and 10....however, the connection string is different, tblEmployee is different and most of the work done in the prerequisite videos isn't there any longer. That makes sense if it's an entirely new app......however, it's not really possible to tell that until you're already through a lot of the video. Am I missing something?
@haydarm.al-samawe9819
@haydarm.al-samawe9819 7 жыл бұрын
Maybe i come for this coerce too late but i really like the way how you give the information from A-Z , i just have one question now after almost 4 year from this coerce did we really need to use business objects ? or just using MVC even now i read about not using Stored procedure it can be ? if i use MSSQL
@stevenchi1202
@stevenchi1202 9 жыл бұрын
Best tutorial for MVC in the Internet
@TopGamerTom
@TopGamerTom 5 жыл бұрын
Venkat Sir, is there a specific reason to use business layer class, couldn't we do the same job using List like in your previous video by creating a new video to display the data in a table?
@bunthaideng2492
@bunthaideng2492 7 жыл бұрын
Hello Sir!! I wonder one thing, In BusinuessLayer why didn't you use DbContext to store data retrieve from sql server? I think this way should be more easier than write much code.
@luisespinoza9093
@luisespinoza9093 8 жыл бұрын
Very usefull. There are many tutorials that usign entityframework but is powerfull know how to build applications from scratch. Thanks
@Snapken
@Snapken 9 жыл бұрын
13 dislikes? idiots.. idiots everywhere.. anyway,. awesome job, You are my personal hero :)
@mad_t
@mad_t 8 жыл бұрын
Maybe those are people who try to give same material for a fee, and venkat is ruining their «business» =)
@impossiblehousemarylandsta6266
@impossiblehousemarylandsta6266 5 жыл бұрын
@Snapken and @Tim , Let me explain that for two morons, I m giving thumbs down 2 years later after your comments, so listen carefully. This should be beginning tutorial, but even me (I know Mvc for 5 years but used it long time ago so I need to refresh my knowledge that`s why I m here) not getting what Kudvenkat is doing, he is not explaining well and copying and pasting some code. His last two tutorial also got thumbs down from me because he does not explain about connection string but he jumps in subject to subject , I spent 2 days to connect Mysql database after watching last 2 videos. I got several errors with same code. I like Kudvenkat videos sometimes it is good (given thumbs up), sometimes they are not good (given thumbs down). I do not care those two morons what they think but I want people to show how people who give thumbs down , can think. So before being ass hole, just focus on your job, not criticize people with your small brains
@nayeemhasan7444
@nayeemhasan7444 8 жыл бұрын
when i am trying to add the business layer refernce to the mvc demo..it says it cannot do it due to a circular dependancy .. what might be the solution to that ?
@hossamyasser2866
@hossamyasser2866 8 жыл бұрын
in 2016 you are the best thanks a lot
@dipikabhagat5252
@dipikabhagat5252 7 жыл бұрын
While creating strongly typed view for EmployeeController.cs ,The model class intelligence is not giving BusinessLayer option . Only 2 options :- FilterConfig, RouteConfig .I have already added BusinessLayer reference to my MVC proj but still not working . Anyone please help me with this .
@iHamzaKhanzada
@iHamzaKhanzada 7 жыл бұрын
Build the solution
@syedshah6166
@syedshah6166 5 жыл бұрын
Having same problem...even i rebuild the whole solution
@automation_jeff
@automation_jeff 6 жыл бұрын
Your video's have been very helpful, although they are five years old. Was wondering if you were planning any updates, things have changed in recent Visual Studio's versions 15 and 17?
@laxmibajjara2461
@laxmibajjara2461 11 жыл бұрын
Thank You so much for these videos. It is very helpful to naive users.
@shemeemsha
@shemeemsha 11 жыл бұрын
Hi Venkat.. I have a doubt.. How to call a http Post controller from another controller.. :)
@dsingh3205
@dsingh3205 11 жыл бұрын
Thank you sir for uploading the 11th part of MVC. HAVE A GREAT DAY.
@imranbhatti7906
@imranbhatti7906 5 жыл бұрын
good work done kudvenkat , awesome
@streetzstudio100
@streetzstudio100 8 жыл бұрын
Please i ran this code and i get the error Object reference not set to an instance of an object. on line 16. List employees = empBusinessLayer.Employees.ToList(); what could be the cause i am using visual studio 2015
@streetzstudio100
@streetzstudio100 8 жыл бұрын
i got the solution. the problem is that i put my connectionString in the web.config file inside the view directory. then copying the connection string and pasting it to the web.config file under the project directory fixed it. thanks
@bankniftydailylevel2119
@bankniftydailylevel2119 9 жыл бұрын
all videos r great thanks to guides us................................. thanks a lot
@Csharp-video-tutorialsBlogspot
@Csharp-video-tutorialsBlogspot 9 жыл бұрын
+Sandeep Mishra Thank you so much for accepting my request Dot Net & SQL Server training videos for web developers kzbin.infoplaylists?view=1&sort=dd You can order DVDs for offline viewing using the link below www.pragimtech.com/Order.aspx Code Samples & Slides are on my blog csharp-video-tutorials.blogspot.com Tips to effectively use our channel kzbin.info/www/bejne/r2ibYYCtnb5qZtU To receive email alerts, when new videos are uploaded, please subscribe to our channel kzbin.info Please click that THUMBS UP button below the video, if you like the videos Thanks a million for sharing these resources with your friends Best Venkat
@MagnificentKnight1
@MagnificentKnight1 9 жыл бұрын
+kudvenkat Sir, on the view @foreach (var item in Model) the model is null and throws a null reference exception, how do I solve it. Thanks.
@MagnificentKnight1
@MagnificentKnight1 9 жыл бұрын
+kudvenkat Sir, I've solved it, it was my fault.
@MagnificentKnight1
@MagnificentKnight1 9 жыл бұрын
+kudvenkat, I didn't pass the Employee list's object to the View method.
@nisargdesai1044
@nisargdesai1044 10 жыл бұрын
Hi sir your lectures are very useful. Every single details is explained in all the videos. I just have a single query. It shows an error like "Object reference not found" at line "string connectionString = ConfigurationManager.ConnectionStrings["MVCDB"].ConnectionString;".I have tried every possible way to sort this problem, Please help me.
@OnBurak1
@OnBurak1 8 жыл бұрын
I am getting the same error
@OnBurak1
@OnBurak1 8 жыл бұрын
I realized I made a mistake with the connection string name and corrected it.
@adamkazimierak715
@adamkazimierak715 8 жыл бұрын
You need to add reference to System.Configuration in your BusinessLayer class library
@mappalaraju1
@mappalaraju1 7 жыл бұрын
At the end of webconfigfile before Retrieve server name and Dbname form your Db properties permission settings Check this MYSQL-security-login-NTAuthority\system\properties\serverroles\sysadmin (if it not working)
@PraskYoutube
@PraskYoutube 11 жыл бұрын
Hi Venkat thanks so much for this.So just 2 queries. 1.We cant use DataTable for this? 2.Can we call the stored proc from the Model pass it to controller and then from Controller to View?
@bradleyr4451
@bradleyr4451 9 жыл бұрын
Hi Venkat, could you please do this again using visual studio 2015 ? we cannot follow directly, right click on Index and its not the same, you dont add controllers the same as before
@carlossiverio3570
@carlossiverio3570 7 жыл бұрын
I cannot find anything in the referencing when creating the library class is this a VS 2017 thing?
@csabasomogyi6780
@csabasomogyi6780 7 жыл бұрын
this is my also problem
@maximss
@maximss 8 жыл бұрын
Hi, I'm getting an error here: EmployeeBusinessLayer wtv = new EmployeeBusinessLayer(); List employees = wtv.Employees.ToList(); my "wtv" variable is not recognized as being of EmployeeBusinessLayer class, any clues? thanks
@maximss
@maximss 8 жыл бұрын
someone? :(
@lovegeorgian
@lovegeorgian 8 жыл бұрын
I got the same. To close and open Visual studio resolved it. I googled and found some other solutions also...
@BasiliskSupreme
@BasiliskSupreme 9 жыл бұрын
Hi All, Need your assistance on an issue I'm facing. I am able to to load the data from the DB using the class - EmployeeBusinessLayer, but this does not render on the the Web-UI. I have the exact copy of Venkat's code, from the creation of the view from the Employee controller. but this is still not working. Have you done something extra to make it work. Best Regards, Sitaram.S
@Namishmedia
@Namishmedia Жыл бұрын
Hi Sir, I am using VisualStudio2019, as there is no web.config file, i couldn't save the connection string. pls find a solution for this.
@surabhisinha6882
@surabhisinha6882 9 жыл бұрын
Awesome video .Really helpful
@Indianmemetemplate
@Indianmemetemplate 3 жыл бұрын
How to use class library as a model to submit data with notation validation
@NAWAABJADA
@NAWAABJADA 8 жыл бұрын
Getting an error: Line 28: Line 29: @foreach (var item in Model) Line 30: { Line 31: System.NullReferenceException: Object reference not set to an instance of an object. on Index.chtml Can you please help?
@lovegeorgian
@lovegeorgian 8 жыл бұрын
Did your action return View(Employees) or just View()?
@oraksoft7471
@oraksoft7471 7 жыл бұрын
Great answer
@angrishdeepty
@angrishdeepty 11 жыл бұрын
Mind blowing sir... really gr8 videos...
@gauravsingh-hr6fn
@gauravsingh-hr6fn 5 жыл бұрын
venkat sir i need one help i create all the thinks as expected but when i am creating Employee Controller i am unable to create object of EMployeeBusnessLayer Pls Help
@edsalazar4590
@edsalazar4590 11 жыл бұрын
Thank you for these videos. Much appreciated.
@komaldhere5990
@komaldhere5990 5 жыл бұрын
Hello sir, why class library is not added in controller. I am getting this error while importing class library in controller.
@nani143144
@nani143144 11 жыл бұрын
Hai sir.. Your lecture is mind blowing, really great great great sir. i have no words for how u way of explaination. simply awesom sir.. Iam waiting for WCF Sessions sir. is there any chance to put sir...????
@linxploit
@linxploit 7 жыл бұрын
i faced this error i googled but... An unhandled exception of type 'System.StackOverflowException' occurred in System.dll
@Itachi2706
@Itachi2706 10 жыл бұрын
Just had convulsion when you deleted Model folder...
@pahadi_bhula_
@pahadi_bhula_ 7 жыл бұрын
hello sir i am getting this error i have tried everything but not able to correct it. Please help.......... An exception of type 'System.Data.SqlClient.SqlException' occurred in System.Data.dll but was not handled in user code Additional information: Could not find stored procedure 'spGetAllEmployees2'.
@sca11ywagg
@sca11ywagg 5 жыл бұрын
Just an aside, any adherence to naming standards, interface inheritance etc. is purely a Microsoft convention. There's no such requirement in the original MVC pattern, which pre-dates Microsoft by several decades.
@davidespada01
@davidespada01 11 жыл бұрын
Hi MR. Venkat Same Question of @Prashanth Krishnan Thank you
@explorewithdawa
@explorewithdawa 4 жыл бұрын
First of all, thank you so much for such a wonderful tutorial. I have followed your process and everything went smoothly but in the end, something seems went wrong. I'm able to bind the data in the view list with no exceptions. I check my code by setting a breakpoint and there are 15 different data in the IEnumerable list but the data at row 15 is repeating itself 15 times (the last one). Can someone help me regarding this?
@honghaivib1977
@honghaivib1977 11 жыл бұрын
Thank you very much, Your video help me alot
@linxploit
@linxploit 7 жыл бұрын
hello Sir Thanks for Sharing Your Knowledge
@kamdemkakengne
@kamdemkakengne 7 жыл бұрын
Nice ! Thank you so much sir!
@amarpreetsingh6016
@amarpreetsingh6016 7 жыл бұрын
the ado.net code is working. the connection keep going in circles in get accessor and throwing stackoverflow exception
@mayashobana7880
@mayashobana7880 7 жыл бұрын
I have doubt for every Controller we have to create MapRoute in RouteConfig?can anyone help me in clearing it?
@kenmtb
@kenmtb 6 жыл бұрын
The MapRoute in RouteConfig allows you to determine the default controller/Action Method and parameters that are read from the browser's url. Without the MapRoute you would have to specify all of the information explicitly each time you ran your web app.
@tiensinhphan5173
@tiensinhphan5173 6 жыл бұрын
System.Data.SqlClient.SqlException: 'Could not find stored procedure 'spGetAllEmployees'. Please help!!!
@opsekai3599
@opsekai3599 5 жыл бұрын
where model and modelItem came from !!
@dhanashripatil5665
@dhanashripatil5665 9 жыл бұрын
Very useful video for all beginers
@hoaleang8437
@hoaleang8437 11 жыл бұрын
thanks so much! Can you make some tutorials for applying existing layout for the view?
@masood0092
@masood0092 4 жыл бұрын
error at Line 26: con.Open(); can any one reply...
@firdousabrar1498
@firdousabrar1498 11 жыл бұрын
Great Tutorial sir...
@romesupaila1864
@romesupaila1864 5 жыл бұрын
I got error.. uncaught exception thrown by method called trough from Hresult 0x80131604
@dhoniomkar
@dhoniomkar 11 жыл бұрын
Hello sir this is omkar. I am very much new to MVC .i want to build a project in three tier in MVC 4 .So please help me
@amarpreetsingh6016
@amarpreetsingh6016 7 жыл бұрын
its resolved. i was calling property. thanks.
@jhonhernandez9210
@jhonhernandez9210 6 жыл бұрын
I have used this connection string and works
@MrVibhore1989
@MrVibhore1989 5 жыл бұрын
I got output of this in my system "Successfully Implemented" , Now i can die in peace. BTW I have never seen the face of the speaker even searched on google it was not there, Is it a real human , or I am following the Voice of God :)
@a.b_shots
@a.b_shots 7 жыл бұрын
Someone might get error while adding string connectionString = ConfigurationManager.ConnectionStrings["DBCS"].ConnectionString; Even when you type the reference using.System.Configuration; If you guys face this error, go to menubar and click project. There you will find "Add Reference" click on it. It will starts with the active tab of framework. Don't change it just scroll down and look for using System.Configuration. Check it and then it will work. If it doesn't try it again next time it will work for sure.
@sridharyadav3054
@sridharyadav3054 4 жыл бұрын
In the view how he is managing to hide Employee ID text box object
@bharatgambhir
@bharatgambhir 6 жыл бұрын
I don't agree to have model delayed from MVC. Instead we must have separate business entities and model should be typecast and passed to BAL
@kenmtb
@kenmtb 6 жыл бұрын
Interesting idea. Where should each model exist?
@mxgundy1916
@mxgundy1916 5 жыл бұрын
Don't you love how he doesnt tell you to start a new project, or to delete certain folders or even how to make your db? He assumes you already know how to do all that? Incredibly frustrating.
@lightyagami5776
@lightyagami5776 5 жыл бұрын
sql codes are in his blog, link in desc
@parko1965
@parko1965 5 жыл бұрын
...confused now, cut, paste, errors, cut, paste, errors etc.
@battulasandeep98
@battulasandeep98 11 жыл бұрын
thank u sir
@mahendrabhoi9011
@mahendrabhoi9011 6 жыл бұрын
Thank you sir....
@agotrader960
@agotrader960 11 жыл бұрын
Very thank.
@Exploreepic786
@Exploreepic786 9 жыл бұрын
Its Coming Out of While Loop !! while we reading using While loop
@jangear
@jangear 11 жыл бұрын
thanks
@ashishsuthar3827
@ashishsuthar3827 9 жыл бұрын
nice
@poppyleo9866
@poppyleo9866 3 жыл бұрын
System.core 4.0.0 error: anyone?
Part 12  Creating a view to insert data using mvc
10:40
kudvenkat
Рет қаралды 458 М.
Part 10  Working with multiple tables in mvc
19:46
kudvenkat
Рет қаралды 585 М.
Леон киллер и Оля Полякова 😹
00:42
Канал Смеха
Рет қаралды 4,7 МЛН
Tuna 🍣 ​⁠@patrickzeinali ​⁠@ChefRush
00:48
albert_cancook
Рет қаралды 148 МЛН
Quando A Diferença De Altura É Muito Grande 😲😂
00:12
Mari Maria
Рет қаралды 45 МЛН
Part 13  FormCollection in mvc
10:45
kudvenkat
Рет қаралды 358 М.
Part 9  Generate hyperlinks using actionlink html helper
13:07
kudvenkat
Рет қаралды 544 М.
Part 8  Data access in mvc using entity framework
13:29
kudvenkat
Рет қаралды 948 М.
Part 16  Difference between updatemodel and tryupdatemodel
14:51
kudvenkat
Рет қаралды 236 М.
Part 15  Updatemodel function in mvc
8:24
kudvenkat
Рет қаралды 270 М.
Part 5  Views in an mvc application
13:31
kudvenkat
Рет қаралды 712 М.
Part 32   How does a controller find a view in mvc
12:21
kudvenkat
Рет қаралды 144 М.
Creating your first aspnet mvc application - Part 3
12:30
kudvenkat
Рет қаралды 1,1 МЛН
Леон киллер и Оля Полякова 😹
00:42
Канал Смеха
Рет қаралды 4,7 МЛН