Is this doable at a newbie level?
Calvin Waterbury
cjw at eml.cc
Fri Jan 14 20:06:43 EST 2011
Hi Bob - See below...
> ------------------------------------------------------------------------
>
> Bob Sneidar <mailto:bobs at twft.com>
> Friday, January 14, 2011 6:51 PM
>
>
> If you look in the Dictionary, under date you will find several items,
> the date function, the dateFormat function, the datetime keyword, and
> the dateItems keyword. Also, if you look for clipboard you will find
> the clipBoardData property.
>
> Between all this and some experimentation you should be able to come
> up with a button that will take the current date and or time in
> whatever format you desire and set the clipBoardData to that.
I've already started the stack, complete with...
<> radio buttons for format selection
<> 3 buttons to enter "Date & Time," "Date" and "Time"
<> YYYY MM DD HH mm ss label fields, just to "see" the realtime values.
>
> Note that setting properties is not the same syntax as creating or
> altering variables. You set a property using the set command. You
> alter variables by using the put into form.
I may need some help with this, but let me struggle with it a little.
I'll ask if I get stuck.
>
> If you wanted to get really fancy, you could build an appleScript into
> a variable and then do as appleScript to query the system for the
> foreground application and then tell that application to paste after
> all that. But that's just for extra credit.
Actually, *this* is exactly what I want to do, but I'm on Windows 7.
>
> Your stack should have it's systemWindow property set to true, but
> this will only float it above other LiveCode stacks. I don't think
> there is a way to make it float above every application in the OS, but
> I might be wrong there.
Hmmm... it needs to have the "Always On Top" option available, or I
could try to program it into the Windows 7 Right-Click context menu, but
that sounds advanced, I think?
>
> I don't think this will take long for you to do if you try. Dropping
> the date/time into a selected field of another LiveCode stack would be
> easy. If you want to drop a date/time stack at the cursor of another
> application, that could prove more difficult.
>
> Bob
Again, the need to drop into the focused application is important, but
I'll get it working on the clipboard usefulness first then move on to
the next level.
Thanks for the reminder on the "Dictionary." I'm going to have to
create a new mantra for myself, "Look in the Dictionary, Look in the
Dictionary, Look in the Dictionary,...."
Fair winds,
Calvin
>
>
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
> ------------------------------------------------------------------------
>
> Calvin Waterbury <mailto:cjw at eml.cc>
> Friday, January 14, 2011 6:29 PM
>
>
> Hi,
>
> The below features list is for a small utility I *need* right now, but
> I can wait long enough to code it. ;)
>
> Please, resist the urge to whip out the code and post it. I want to
> try something myself. I *know* this can be done in LC. What I am
> asking is if you think the following can be done by a newbie to LC?
>
> Thanks, Calvin
>
> PS - Don't go away... I may *need* you to "whip out" some syntax
> later! Here's the list...
>
> Here is a list of requested features...
>
> * "Always On Top" option
> * Three Buttons.
> o Date
> o Time
> o Date and Time
> + The "Date and Time" button to include date, at least in
> this specific format, but others can be included...
> "Nov 15, 2010 02:43 PM" (color only for reference,
> not needed in app.)
> Please ask me for other formats, if you want to
> include them?
>
> * Optional Radio buttons to select Date/Time formats *if* you have the
> time and inclination. The Date & Time format above,"Nov 15, 2010
> 02:43 PM," is my only immediate need.
> o "Date & Time" Mmm DD, YYYY HH:MM AM (the same as the above
> exact example that is really the most important format.)
> o Another Date format MM/DD/YY (Example: 01/14/11)
> o Time format 1: HH:MM (24 Hr Clock)
> o Time format 2: HH:MM AM (12 Hr Clock)
> o YYYYMMDDHHSS - I use this to prefix file names as a simple
> date tagging system.
>
> * It would be nice to be typing in a text editor and just click the
> "Insert Date" button and populate it in the document I am working on,
> but I can settle for sending it to the clipboard if that is all that
> can be done easily.
>
> * Small footprint
> o Just big enough for the radio buttons (for the format
> selections) and the three "Date," Time" and "Date & Time" insertion
> buttons.
> o Menu in Right-Click menu, if easier.
More information about the use-livecode
mailing list