Page 1 of 1

"Timestamp" can't work with variable?

Posted: 26 Feb 2021 10:46
by eil
I'm trying to make a script that first picks an item and then copies its datem+datec to other selected items. Help file gives example "timestamp 'mc', <focitem>, , 'a';" where <focusitem> is quite like a variable for me, but when i try to use simple variable $clondate "magic doesn't happen".. Timestamp seem to not recognize dates of item in variable but takes it's path as a "direct time format, though Syntax says:
timestamp [type = "cma"], [date / source_item], [itemlist], [source_type = "*"], [shift]
What am i doing wrong?

Code: Select all

  perm $clondate;
  if ($clondate == "") {$clondate = <curitem>; trayballoon $clondate;}
  else {timestamp 'mc', $clondate, , 'mc', "1 s"; unset $clondate;}

Re: "Timestamp" can't work with variable?

Posted: 26 Feb 2021 14:24
by RalphM
Without testing it myself, I don't see why you need this to be a perm var and the single quotes might make it trip?!

Re: "Timestamp" can't work with variable?

Posted: 26 Feb 2021 15:00
by eil
RalphM wrote: ↑26 Feb 2021 14:24 Without testing it myself, I don't see why you need this to be a perm var and the single quotes might make it trip?!
cause it's ought to work in 2 stages: select source-date-item, use script(or push a button), select items to be date-coppied , use script again. it's useful cause one can specifically pick 1 source, and in situations when source and target is in different locations.

Re: "Timestamp" can't work with variable?

Posted: 26 Feb 2021 18:57
by jupe
source_type can only be 1 char at a time, or an asterisk.

Re: "Timestamp" can't work with variable?

Posted: 26 Feb 2021 19:20
by eil
jupe wrote: ↑26 Feb 2021 18:57 source_type can only be 1 char at a time, or an asterisk.
my bad, didn't notice that detail. so there is no way to simple clone all dates in once, only one at a time if exact copy is desired..

Re: "Timestamp" can't work with variable?

Posted: 26 Feb 2021 19:21
by jupe
eil wrote: ↑26 Feb 2021 19:20 no way to simple clone all dates in once
jupe wrote: ↑26 Feb 2021 18:57 or an asterisk.

Re: "Timestamp" can't work with variable?

Posted: 26 Feb 2021 19:25
by eil
jupe wrote: ↑26 Feb 2021 19:21
eil wrote: ↑26 Feb 2021 19:20 no way to simple clone all dates in once
jupe wrote: ↑26 Feb 2021 18:57 or an asterisk.
i wrote it wrong, meant only 2 of 3 dates. well tried with 1 - now it works, which is already good.!
but one strange thing happens = i have "1 s" stated in shift parameters, but time is shifted +2sec for some dates.