<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">I finaly found the problem witch was not in the code suggest but behind the keyboard.<div class=""><br class=""></div><div class="">In fact when the time is generated everything is good , when i entered it by hand = this is a String.</div><div class="">So I had in the sorting code: &nbsp;</div><div class=""><blockquote type="cite" class=""><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex;">^notes sort:[:a :b | (a date = b date) and:[a temps asTime &gt; b temps asTime ]] .</blockquote></div></div></blockquote><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><br class=""><div><blockquote type="cite" class=""><div class="">Le 2015-02-04 à 14:40, Chris Cunningham &lt;<a href="mailto:cunningham.cb@gmail.com" class="">cunningham.cb@gmail.com</a>&gt; a écrit :</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">You have a logic issue with the first one:<div class=""><span style="font-size:12.8000001907349px" class="">sortedNotes</span><br style="font-size:12.8000001907349px" class=""><span style="font-size:12.8000001907349px" class="">^notes sort:[:a :b | (a date = b date) and:[a temps &gt; b temps]] .</span><br class=""></div><div class=""><span style="font-size:12.8000001907349px" class="">This is saying that the the two dates are different, then false.&nbsp; For this you probably want to be something like:</span></div><div class=""><span style="font-size:12.8000001907349px" class="">sortedNotes</span><br style="font-size:12.8000001907349px" class=""><span style="font-size:12.8000001907349px" class="">^notes sort:[:a :b | a date &gt; b date or: [(a date = b date) and:[a temps &gt; b temps]]] .</span><span style="font-size:12.8000001907349px" class=""><br class=""></span></div><div class=""><span style="font-size:12.8000001907349px" class=""><br class=""></span></div><div class=""><span style="font-size:12.8000001907349px" class="">-cbc</span></div></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Wed, Feb 4, 2015 at 10:22 AM, Raymond Asselin <span dir="ltr" class="">&lt;<a href="mailto:jgr.asselin@me.com" target="_blank" class="">jgr.asselin@me.com</a>&gt;</span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">For now I implemented:<br class="">
<br class="">
sortedNotes<br class="">
^notes sort:[:a :b | (a date = b date) and:[a temps &gt; b temps]] .<br class="">
<br class="">
AND<br class="">
<br class="">
notesSorted<br class="">
^notes sort:[:a :b | a date = b date<br class="">
<span class="">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ifTrue:[a temps &gt; b temps]<br class="">
</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ifFalse:[a date &gt; b date]] .<br class="">
<br class="">
does exactly the same result.<br class="">
<br class="">
But there is still notes in a same date that do not sort correctly, the begining is good and after 5 or so objects<br class="">
I get some witch do not seem to be sorted.<br class="">
<br class="">
BTW don't know the difference between sort:&nbsp; and sorted:<br class="">
it seems as if the last one produce a new collection and the first one produce same collection but sorted.<br class="">
<br class="">
Note: I use 24 hours instead of a.m. / p.m. is this may cause problems?<br class="">
<br class="">
&gt; Le 2015-02-04 à 12:00, Paul DeBruicker &lt;<a href="mailto:pdebruic@gmail.com" class="">pdebruic@gmail.com</a>&gt; a écrit :<br class="">
<span class="im HOEnZb">&gt;<br class="">
&gt; a date = b date<br class="">
&gt;&nbsp; &nbsp;ifTrue:[a temps &gt; b temps]<br class="">
&gt;&nbsp; &nbsp;ifFalse:[a date &gt; b date]<br class="">
<br class="">
</span><div class="HOEnZb"><div class="h5">_______________________________________________<br class="">
Beginners mailing list<br class="">
<a href="mailto:Beginners@lists.squeakfoundation.org" class="">Beginners@lists.squeakfoundation.org</a><br class="">
<a href="http://lists.squeakfoundation.org/mailman/listinfo/beginners" target="_blank" class="">http://lists.squeakfoundation.org/mailman/listinfo/beginners</a><br class="">
</div></div></blockquote></div><br class=""></div>
_______________________________________________<br class="">Beginners mailing list<br class=""><a href="mailto:Beginners@lists.squeakfoundation.org" class="">Beginners@lists.squeakfoundation.org</a><br class="">http://lists.squeakfoundation.org/mailman/listinfo/beginners<br class=""></div></blockquote></div><br class=""></div></body></html>