﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » StrataFrame Application Framework - V1 » WinForms (How do I?)  » Collision Form</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Fri, 08 May 2026 00:26:22 GMT</lastBuildDate><ttl>20</ttl><item><title>Collision Form</title><link>http://forum.strataframe.net/FindPost10693.aspx</link><description>Still learning StrataFrame...&lt;P&gt;I can't figure out how to localize the StrataFrame collision form and how I could put it on top&lt;P&gt;Myform.TopMost = True and Myform.MyBrowseDialog.ForceWindowTopMost = True, so collision form is always on bottom</description><pubDate>Thu, 09 Aug 2007 09:08:00 GMT</pubDate><dc:creator>Michel Levy</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10785.aspx</link><description>:ermm:ahem.. &lt;P&gt;[quote]&lt;SPAN id=ctl02_ctlTopic_ctlPanelBar_ctlTopicsRepeater_ctl06_lblFullMessage&gt;If you have the SF source code built in debug, then put a break point in ...&lt;/SPAN&gt;[/quote]&lt;/P&gt;&lt;P&gt;Ben, don't forget I'm an absolute beginner in .NET, so I don't know how to put this breakpoint in SF sourcecode in my project :unsure:&lt;/P&gt;&lt;P&gt;Could you&amp;nbsp;advise please, I'm lost now and here&lt;BR&gt;Thanks&lt;/P&gt;&lt;P&gt;Michel</description><pubDate>Thu, 09 Aug 2007 09:08:00 GMT</pubDate><dc:creator>Michel Levy</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10770.aspx</link><description>If you have the SF source code built in debug, then put a break point in the DataLayer.vb file (in the MicroFour StrataFrame Business project in the Data folder) somewhere around line 1120 on the HandleConcurrencyException method.&amp;nbsp; This method will be called when the server returns 0 for the number of records affected by the delete.&amp;nbsp; You can see what it's doing by stepping through it.</description><pubDate>Wed, 08 Aug 2007 15:08:35 GMT</pubDate><dc:creator>StrataFrame Team</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10762.aspx</link><description>Ben,&lt;/P&gt;&lt;P&gt;I'm handling it in the ConcurrencyException event&amp;nbsp;of the BO. Never raised...&lt;/P&gt;&lt;P&gt;Local line is deleted in BO, not on server (I can see it by loading another instance of the same MaintenanceForm).&lt;/P&gt;&lt;P&gt;How could I debug that? where should I put a breakpoint?</description><pubDate>Wed, 08 Aug 2007 09:53:45 GMT</pubDate><dc:creator>Michel Levy</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10757.aspx</link><description>[quote]@volumax_ORG was 10 on A client side when BO was filled, and User B upadated its related field to 100 before A asked for deletion. &lt;BR&gt;&lt;STRONG&gt;So my SQL command would never raise an exception, since there was no line matching on the server!&lt;/STRONG&gt;[/quote]&lt;/P&gt;&lt;P&gt;Hrm.&amp;nbsp; That is very odd.&amp;nbsp; The addition of the extra parts to the WHERE clause will prevent the line from being deleted (just like it should), however, it should be raising an concurrency exception.&amp;nbsp; Looking at the source code, if the local line is deleted, it will raise the ConcurrencyException just like normal.&amp;nbsp; &lt;/P&gt;&lt;P&gt;Just out of curiosity, are you expecting to wrap the Save() in a Try/Catch or are you handling the ConcurrencyException event of the business object?</description><pubDate>Wed, 08 Aug 2007 08:48:59 GMT</pubDate><dc:creator>StrataFrame Team</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10749.aspx</link><description>Thanks Ben,&lt;P&gt;I begin to understand... here is the SQL command really sent by the BO (concurrency mode set on allfields, so all the additional WHERE clauses are correct):&lt;BR&gt;[quote]DELETE FROM [dbo].[cuves] WHERE [cuve_pk] = @cuve_pk AND (([numcuve] = @numcuve_ORG) OR ((@numcuve_ORG IS NULL) AND ([numcuve] IS NULL))) AND (([qtestock] = @qtestock_ORG) OR ((@qtestock_ORG IS NULL) AND ([qtestock] IS NULL))) AND (([volumax] = @volumax_ORG) OR ((@volumax_ORG IS NULL) AND ([volumax] IS NULL))) AND (([dispo] = @dispo_ORG) OR ((@dispo_ORG IS NULL) AND ([dispo] IS NULL))) AND (([directe] = @directe_ORG) OR ((@directe_ORG IS NULL) AND ([directe] IS NULL))); [/quote]&lt;P&gt;@volumax_ORG was 10 on A client side when BO was filled, and User B upadated its related field to 100 before A asked for deletion. &lt;BR&gt;&lt;STRONG&gt;So my SQL command would never raise an exception, since there was no line matching on the server!&lt;/STRONG&gt;&lt;P&gt;I totally misunderstood the purpose of DeleteConcurrencyType, wich is only to add the additional where clauses, right?&lt;/P&gt;&lt;P&gt;&lt;BR&gt;How could I retrieve the result of the delete command (boolean or #line deleted) without writing a specific procedure?&lt;BR&gt;Or is it a better practice to create a property "is_deletabled" on my BO class, and to check in beforedelete method to switch that property to True or False, so it could be retrieved by beforedelete methode on UI layer?&lt;/P&gt;&lt;P&gt;and the SetDebugOn is really a very nice tool :)</description><pubDate>Tue, 07 Aug 2007 10:10:26 GMT</pubDate><dc:creator>Michel Levy</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10742.aspx</link><description>Is the event being raised and there is nothing in the event args, or is the collision not being detected?&amp;nbsp; If the collision is not being detected, you can always turn on&amp;nbsp;Debugging for the data source (MicroFour.StrataFrame.Data.DataBasics.DataSources("").SetDebugOn()) and check the command that is being executed to make sure that it would be albe to find the collision.</description><pubDate>Tue, 07 Aug 2007 09:02:38 GMT</pubDate><dc:creator>StrataFrame Team</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10728.aspx</link><description>Hi,&lt;P&gt;I'm now creating my own collision form, so I'm working with ConcurrencyException; seems quite easy to manage for collision on update, but I've not found how to do for delete.&lt;/P&gt;&lt;P&gt;say Table1 "cuves" with a cuve_pk autointeger, a field numcuve C(15) unique, and a field qtstock integer&lt;/P&gt;&lt;BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px"&gt;&lt;P&gt;user A is loading dataset&amp;nbsp;from cuves using a BO&amp;nbsp;in a "StrataFrame built" application, and navigates to line n&lt;BR&gt;user&amp;nbsp;B is updating numcuve or qtstock on&amp;nbsp;the same line n&amp;nbsp;from within an other application&lt;BR&gt;user A calls delete on that line n&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Delete is not committed on server, but there is no collision in concurrencyexception (DeleteConcurrencyType is set to OptimisticAllFields)&lt;/P&gt;&lt;P&gt;Why? how to do? where?</description><pubDate>Mon, 06 Aug 2007 10:01:05 GMT</pubDate><dc:creator>Michel Levy</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10720.aspx</link><description>Sounds good.&amp;nbsp; We look forward to working with you :)</description><pubDate>Sat, 04 Aug 2007 09:25:40 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10718.aspx</link><description>Don't worry, Trent!&lt;/P&gt;&lt;P&gt;I've bought StrataFrame as a framework, not as a wizard ; I'll create my own collision form, and come back soon with other questions.</description><pubDate>Sat, 04 Aug 2007 03:24:15 GMT</pubDate><dc:creator>Michel Levy</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10713.aspx</link><description>At the moment, no.&amp;nbsp; But you are correct in that it should probably be localized.&amp;nbsp; We will take a look at this.&amp;nbsp; But for now, you&amp;nbsp;can create your own to get around the issue.&amp;nbsp; Sorry. :ermm:</description><pubDate>Fri, 03 Aug 2007 17:10:56 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10711.aspx</link><description>Trent,&lt;/P&gt;&lt;P&gt;Yes, I've seen I could create my own collision form, and it's probably what I'll do for my own applications.&lt;/P&gt;&lt;P&gt;But is it possible to basically "manage" the collision form provided by StrataFrame (top/bottom or showdialog option, and localization)? &lt;/P&gt;&lt;P&gt;It would be a nice functionality for&amp;nbsp;a few customers and french VFP users looking for rapid&amp;nbsp;migration solutions.</description><pubDate>Fri, 03 Aug 2007 15:52:23 GMT</pubDate><dc:creator>Michel Levy</dc:creator></item><item><title>RE: Collision Form</title><link>http://forum.strataframe.net/FindPost10708.aspx</link><description>Well, you should probably create your own collision form to have complete control.&amp;nbsp; The ConcurrencyException event arguments give you everything that you need, so you would just need to display it to your end-user.&amp;nbsp; At this point youa re 100% in control and can implement localization just like you would on any other form.&amp;nbsp; Let me know if I am missing something.&amp;nbsp; :)</description><pubDate>Fri, 03 Aug 2007 13:02:56 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item></channel></rss>