emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: org table: generate a weekly calendar with column that represents th


From: Uwe Brauer
Subject: Re: org table: generate a weekly calendar with column that represents the hours
Date: Fri, 22 Apr 2022 14:47:43 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

>>> "ESF" == Eric S Fraga <e.fraga@ucl.ac.uk> writes:

> Something to play with:
> | start | duration |   end | notes |
> |-------+----------+-------+-------|
> | 08:00 |     1:00 | 09:00 |       |
> | 09:00 |    01:00 | 10:00 |       |
> | 10:00 |    01:00 | 11:00 |       |
> | 11:00 |    01:00 | 12:00 |       |
> | 12:00 |    01:00 | 13:00 |       |
> | 13:00 |    01:00 | 14:00 |       |
> | 14:00 |    01:00 | 15:00 |       |
> | 15:00 |    01:00 | 16:00 |       |
> | 16:00 |    01:00 | 17:00 |       |
> | 17:00 |    01:00 | 18:00 |       |
> | 18:00 |    01:00 | 19:00 |       |
> | 19:00 |    01:00 | 20:00 |       |
> | 20:00 |    01:00 | 21:00 |       |

> #+TBLFM: @<<<$2..@>$2=@-1;U::@<<<$1..@>$1=@-1+@-1$+1;U::$3=$1+$2;U
Thanks very much let me see whether I understand its logic

I tried

| start | duration |   end | notes |
|-------+----------+-------+-------|
| 08:00 |     1:00 | 09:00 |       |
#+TBLFM: @<<<$2..@>$2=@-1;U::@<<<$1..@>$1=@-1+@-1$+1;U::$3=$1+$2;U

I put the cursor say on the word «start»
And then fire up  C-c C-c, nothing happens. I fire up C-u C-u C-c C-c and it 
complains because the expression 
points outside the table

| start | duration |   end | notes |
|-------+----------+-------+-------|
| 08:00 |     1:00 | 09:00 |       |
|       |          |       |       |
#+TBLFM: @<<<$2..@>$2=@-1;U::@<<<$1..@>$1=@-1+@-1$+1;U::$3=$1+$2;U

Now C-u C-u C-c C-c gives

| start | duration |   end | notes |
|-------+----------+-------+-------|
| 08:00 |     1:00 | 09:00 |       |
| 09:00 |    01:00 | 10:00 |       |
#+TBLFM: @<<<$2..@>$2=@-1;U::@<<<$1..@>$1=@-1+@-1$+1;U::$3=$1+$2;U

Very very nice, so I can proceed like this.


Thanks a lot!

Uwe 
-- 
I strongly condemn Putin's war of aggression against the Ukraine.
I support to deliver weapons to Ukraine's military. 
I support the ban of Russia from SWIFT.
I support the EU membership of the Ukraine. 

Attachment: smime.p7s
Description: S/MIME cryptographic signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]