[tomboy-list] custom timestamp format: week number?

Stefan Schweizer steve.schweizer at gmail.com
Wed Jul 22 07:41:15 PDT 2009


OK, but you cannot use that snippet to format a timestamp for the
Insert Timestamp-addin. I think that is what Mathias wants to do.

On Wed, Jul 22, 2009 at 4:10 PM, Sandy
Armstrong<sanfordarmstrong at gmail.com> wrote:
> Google says:
>
> http://snippets.dzone.com/posts/show/856
>
> public static int weekNumber(DateTime dt) {
>        CultureInfo culture = CultureInfo.CurrentCulture;
>        int intWeek = culture.Calendar.GetWeekOfYear(dt,
> CalendarWeekRule.FirstFourDayWeek, DayOfWeek.Monday);
>        return intWeek;
> }
>
> Seems fairly reasonable.
>
> Sandy
>
> On Wed, Jul 22, 2009 at 5:48 AM, Stefan
> Schweizer<steve.schweizer at gmail.com> wrote:
>> We use Mono format strings to format timestamps. Quite surprisingly,
>> there is no format specifier for the year's week. Here is a link to
>> the relevant documentation:
>> http://www.go-mono.com/docs/index.aspx?link=T%3aSystem.Globalization.DateTimeFormatInfo
>>
>> I think it is not possible to display the week number with our current
>> implementation. Or have I overlooked something?
>>
>>        Stefan
>>
>> On Wed, Jul 22, 2009 at 12:20 PM, mathias chakib
>> bellout<chakibbb at gmail.com> wrote:
>>>
>>> Hi!
>>> love you software. Is there any possibility to add week number into the
>>> custom timestamp format?
>>> best regards
>>> Mathias
>>>
>>>
>>> _______________________________________________
>>> Tomboy-list mailing list
>>> Tomboy-list at lists.beatniksoftware.com
>>> http://lists.beatniksoftware.com/listinfo.cgi/tomboy-list-beatniksoftware.com
>>>
>>>
>> _______________________________________________
>> Tomboy-list mailing list
>> Tomboy-list at lists.beatniksoftware.com
>> http://lists.beatniksoftware.com/listinfo.cgi/tomboy-list-beatniksoftware.com
>>
>


More information about the Tomboy-list mailing list