<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.aras.com/community/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Catch &amp;#039;ItemCannotBeLockedException&amp;#039; when state=Released</title><link>https://www.aras.com/community/f/development/3630/catch-itemcannotbelockedexception-when-state-released</link><description>Hi,

I&amp;#39;m trying to figure out how and where to catch the Aras.Server.Core.ItemCannotBeLockedException exception so I can display a custom error message to the users.&amp;#160;&amp;#160;The executed AML is: &amp;lt;Item type=&amp;quot;MyCustomDocument&amp;quot; id=&amp;quot;123134234234&amp;quot; action=&amp;quot;lock&amp;quot; </description><dc:language>ja-JP</dc:language><generator>Telligent Community 12</generator><item><title>RE: Catch 'ItemCannotBeLockedException' when state=Released</title><link>https://www.aras.com/community/thread/6169?ContentTypeID=1</link><pubDate>Wed, 30 Dec 2020 08:15:56 GMT</pubDate><guid isPermaLink="false">916d3f7e-8ddc-42f8-8d45-380822f51406:a0caf35f-a6bd-46ab-a238-b6b4f7abe516</guid><dc:creator>SunilReddy</dc:creator><description>&lt;p&gt;Hello Aditya, Usually when the Item is in Released state , in the lifecyle you will have state permissions, the warning which you get from System saying that you have insufficient permission etc, If you want to display your error message, Remove state permission for your Lifecycle&amp;nbsp; Create Custom method for OnBefore UnLock,, get state, if state=Released, display your message&lt;/p&gt;
&lt;p&gt;Thank you&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Catch 'ItemCannotBeLockedException' when state=Released</title><link>https://www.aras.com/community/thread/6168?ContentTypeID=1</link><pubDate>Wed, 30 Dec 2020 07:46:26 GMT</pubDate><guid isPermaLink="false">916d3f7e-8ddc-42f8-8d45-380822f51406:2bf67cea-e10c-4aa8-a45d-9589b81083c5</guid><dc:creator>Aditya.Y</dc:creator><description>&lt;p&gt;Any solution on this?? I want to do same thing -&amp;gt; I want to show custom error message when user tries to lock released/not lockable item..&lt;/p&gt;
&lt;p&gt;Thank you!!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>