<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>How do I Handle Business Logic Exceptions?</title><link>http://asp.net</link><pubDate>Thu, 24 Sep 2009 00:53:34 GMT</pubDate><generator>umbraco</generator><description>Comments for How do I Handle Business Logic Exceptions?</description><language>en</language><atom:link href="http://asp.net/rss/comments/33765" rel="self" type="application/rss+xml" /><item><title>Comment Posted by CODEWIRE.NET</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Sat, 31 May 2008 16:59:39 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003026</guid><description><![CDATA[ <p>How du I access Session in the partiel method like &#160;OnValidate? I want to set a field to a session-variable on every insert.</p> <p>if (action == System.Data.Linq.ChangeAction.Insert)</p> <p>{</p> <p> &#160; Id = Guid.NewGuid();</p> <p> &#160; AccountId = Session(&quot;AccontId&quot;); // Current account</p> <p>}</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/CODEWIRE.NET.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by shanselman</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Mon, 09 Jun 2008 14:25:15 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003027</guid><description><![CDATA[ <p>You would need to use HttpContext.Current.Session, but I think you&#39;d be tying your model objects to the Session which could limit your design&#39;s usefulness in other projects. </p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/shanselman.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by shanselman</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Mon, 09 Jun 2008 14:25:43 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003028</guid><description><![CDATA[ <p>You&#39;d need to use HttpContext.Current.Session.</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/shanselman.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by Dom Márcio</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Mon, 07 Jul 2008 22:39:57 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003029</guid><description><![CDATA[ <p>Hi Scott. How can I implement business logic in the Delete-Insert-Update/Object partial method in the DataContext partial class? Thanks in advance.</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/Dom%20M%c3%a1rcio.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by EdSF</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Mon, 25 Aug 2008 19:52:19 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003030</guid><description><![CDATA[ <p>Thanks for all your work on these videos!</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/EdSF.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by jtwebman</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Mon, 29 Sep 2008 18:40:29 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003031</guid><description><![CDATA[ <p>Scott first off thank you very much for the videos! I am starting to understand the power of Dynamic data. </p> <p>One question that throws red alerts in my mind is using exceptions for validation. Is there way to tie in a more simple validation like in Rocky Lhotka CSLA framework of having a collection of validation errors instead of throwing a expensive (time and cpu) exception?</p> <p>Thanks!</p>]]></description><enclosure length="0" type="image/png" url="http://i1.asp.net/avatar/jtwebman.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by dev01</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Wed, 15 Oct 2008 16:45:19 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003032</guid><description><![CDATA[ <p>I created a partial class Product and implemented OnProductNameChanging just like Scott in the video. It fires 3 times with new value, old value and then again new value of the product? Therefore throwing ValidationException the second &#160;time it fires with the value Chai instaed of ACME. </p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/dev01.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by mgrassman</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Fri, 17 Oct 2008 03:01:03 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003033</guid><description><![CDATA[ <p>I got the same as above any solution/how to check which value we are using.</p> <p>Thanks for the great tutorials.</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/mgrassman.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by djibril_chimere_DIAW</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Fri, 31 Oct 2008 11:58:55 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003034</guid><description><![CDATA[ <p>Thanks! J&#235;r&#235;j&#235;f!</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/djibril_chimere_DIAW.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by pg.net</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Tue, 09 Dec 2008 02:10:12 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003035</guid><description><![CDATA[ <p>When I try to validate some value and throw exception let&#39;s say in OnContentIDChanging(int? value) method I will recieve JavaScript error (exception) instead of &quot;validation summary&quot; error. I&#39;m experiencing this problem only with nullable types. Any idea where is the problem or how to solve this?</p> <p>Thanks in advance!</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/pg.net.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by rami_nassar</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Tue, 10 Feb 2009 05:53:06 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003036</guid><description><![CDATA[ <p>well done</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/rami_nassar.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by kannank7</title><link>http://asp.net/web-forms/videos/aspnet-dynamic-data/how-do-i-handle-business-logic-exceptions</link><pubDate>Thu, 24 Sep 2009 00:53:34 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000003037</guid><description><![CDATA[ <p>thanks for the validation presentation, but if I want to apply my validation in just one page for e.g. let us say Insert and not in Update. where do i have to write it ?</p>]]></description><enclosure length="0" type="image/png" url="http://i1.asp.net/avatar/kannank7.jpg?forceidenticon=false&amp;dt=635046368400000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item></channel></rss>