Kinook Software Forum

Kinook Software Forum (https://www.kinook.com/Forum/index.php)
-   [VBP] General Discussion (https://www.kinook.com/Forum/forumdisplay.php?f=2)
-   -   Using vbld_FormatDateEx (https://www.kinook.com/Forum/showthread.php?t=2838)

Too_Tall_Crown_Victoria 07-25-2007 05:19 PM

Using vbld_FormatDateEx
 
Can you provide a sample script that uses this function and returns the value in the following format?

vbld_FormatDateEx(%DATE%, "yyyy-mm-dd")


Also how can I get the format for yesterday and for 7 days ago?

Thanks

Tom

kinook 07-25-2007 05:51 PM

1 Attachment(s)
Attached.

Too_Tall_Crown_Victoria 07-25-2007 05:56 PM

Can I use [vbld_FormatDateEx(Now, "yyyy-mm-dd")] in a set macro directly or does it have to be set via some script?

Also I am getting " 'Now' is undefined" when using your script.

Tom

kinook 07-25-2007 05:58 PM

Quote:

Originally posted by Too_Tall_Crown_Victoria
Can I use [vbld_FormatDateEx(Now, "yyyy-mm-dd")] in a set macro directly
Yes.

Quote:

Also I am getting " 'Now' is undefined" when using your script.
Is VBScript your default script language (Tools | Application Options | General)? Please ZIP and send or post:
1) The info from Help | About | Install Info
2) The .bld file
3) A build log file

Thanks.

Too_Tall_Crown_Victoria 07-25-2007 08:17 PM

My App is set to use JScript since I have a bunch of global JScripts that I use.

I have also figured out how to solve my problem.

What I still don't understand is how to use your vbld_FormatDateEx in a JScript Script action or a Set Macro step.

Thanks

Tom

kinook 07-25-2007 09:57 PM

Neither Now nor the vbld_FormatDateEx system script function are available to JScript.

One option would be to add a Run Script (VBScript) step. To create/update a macro from such a step, you could use something like:

Application.Macros(vbldMacroTemporary).Add "NAME", vbld_FormatDateEx(Now, "yyyy-mm-dd")


All times are GMT -5. The time now is 10:30 AM.


Copyright © 1999-2023 Kinook Software, Inc.