Topic: Date Separator (1 of 9), Read 23 times
Conf: VEDIT Macro Language Support
From: David Cohen
Date: Tuesday, September 23, 2008 03:08 PM

I can't seem to change the separator value. From the config menu, the change shows but date is always of form mm/dd/yy.

Same thing if I use config(u_date_sep,'-'). Typing date(value,'-') displays mm/dd/yy. What am I doing wrong?
Dave Cohen

 


Topic: Re: Date Separator (2 of 9), Read 18 times
Conf: VEDIT Macro Language Support
From: Christian Ziemski
Date: Tuesday, September 23, 2008 04:38 PM

on 23.09.2008 21:20 David Cohen wrote:
>
> I can't seem to change the separator value. From the config menu, the
> change shows but date is always of form mm/dd/yy.
>
> Same thing if I use config(u_date_sep,'-'). Typing date(value,'-')
> displays mm/dd/yy. What am I doing wrong? Dave Cohen

Try date(NORMAL+VALUE,'-') or date(BEGIN+VALUE,'-')

Date() doesn't allow the option "VALUE" used alone.

(And BTW it doesn't allow double quotes as delimiter for the value.
One have to use single quotes.)


Christian

 


Topic: Date Separator (3 of 9), Read 18 times
Conf: VEDIT Macro Language Support
From: Pauli Lindgren
Date: Wednesday, September 24, 2008 12:23 PM

On 9/23/2008 3:08:20 PM, David Cohen wrote:
>I can't seem to change the separator value. From the
>config menu, the change shows but date is always of form
>mm/dd/yy.

If you want to specify date separator, you must choose date format 1, 2 or 3. If date format setting is 0 (locale), date separator setting is ignored.


By the way, I wonder which "locale" does Vedit use. At least switching the language code on Windows XP task bar does not have effect.
In Control Panel Regional options, I have "Finnish" both in "Standards and formats" and "Location" setting. Still, Vedit displays the date in US format (mm/dd/yyyy) if date format 0 is selected.

--
Pauli

 


Topic: Date Separator (4 of 9), Read 17 times
Conf: VEDIT Macro Language Support
From: David Cohen
Date: Wednesday, September 24, 2008 03:55 PM

Thanks, I'll try your suggestions (I'm sure they will work). The double quote was a typo as was the date format which is yyyy, not yy.
Actually, the whole thing is mute. I'm using the date to build a unique filename and need to use a scratch buffer, so I just use a replace to delete the separator.
Dave Cohen

 


Topic: Date Separator (5 of 9), Read 16 times
Conf: VEDIT Macro Language Support
From: David Cohen
Date: Wednesday, September 24, 2008 04:12 PM

The date(normal+value,'-') seems to work with various separators even when set to normal (0). However, it doesn't seem to permit a null.
Dave Cohen

 


Topic: Date Separator (9 of 9), Read 12 times
Conf: VEDIT Macro Language Support
From: Pauli Lindgren
Date: Friday, September 26, 2008 04:53 AM

On 9/24/2008 4:12:23 PM, David Cohen wrote:
>The date(normal+value,'-') seems to work with various
>separators even when set to normal (0). However, it
>doesn't seem to permit a null.

Yes, the format option given in date command overrides the settings in config menu. Date separator value 0 causes date to be given without any separator, which may be quite useful.

By the way, the date format setting "0" in config menu is same as giving parameter LOCAL in the date command. Parameter NORMAL is same as config setting "1".

--
Pauli

 


Topic: Date Separator (6 of 9), Read 14 times
Conf: VEDIT Macro Language Support
From: Ian Binnie
Date: Wednesday, September 24, 2008 09:56 PM

On 9/24/2008 3:55:51 PM, David Cohen wrote:
>Actually, the whole thing is
>mute. I'm using the date to
>build a unique filename and
>need to use a scratch buffer,

If you are trying to make unique names, you would be better using

Date(REVERSE)

which has the advantage of being sortable.

 


Topic: Date Separator (8 of 9), Read 14 times
Conf: VEDIT Macro Language Support
From: Pauli Lindgren
Date: Friday, September 26, 2008 04:43 AM

On 9/24/2008 3:55:51 PM, David Cohen wrote:
>Actually, the whole thing is mute. I'm using the date to
>build a unique filename and need to use a scratch buffer,
>so I just use a replace to delete the separator.

You do not need to use a scratch buffer to create a filename with date.
To create filename such as "file20080926.log" into text register (here 9), do the following:

Out_Reg(9)
Date(REVERSE+NOCR+NOMSG+VALUE,0)
Out_Reg(CLEAR)
Reg_Set(9,"file",INSERT)
Reg_Set(9,".log",APPEND)

--
Pauli

 


Topic: Re: Date Separator (7 of 9), Read 14 times
Conf: VEDIT Macro Language Support
From: Ted Green
Date: Thursday, September 25, 2008 10:39 AM

At 12:54 PM 9/24/2008, you wrote:
>From: "Pauli Lindgren"
>
>On 9/23/2008 3:08:20 PM, David Cohen wrote:
>>I can't seem to change the separator value. From the
>>config menu, the change shows but date is always of form
>>mm/dd/yy.
>
>If you want to specify date separator, you must choose date format 1, 2 or 3. If date format setting is 0 (locale), date separator setting is ignored.
>
>
>By the way, I wonder which "locale" does Vedit use. At least switching the language code on Windows XP task bar does not have effect.
>In Control Panel Regional options, I have "Finnish" both in "Standards and formats" and "Location" setting. Still, Vedit displays the date in US format (mm/dd/yyyy) if date format 0 is selected.

VEDIT is supposed to use the Windows setting "locale". Since you say it is not working, I will add it to the bug list.

Ted.