×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Date function

Date function

Date function

(OP)
how to set a textbox for displaying today's date ?

RE: Date function

Hi mok,
You didn't tell what programing language that you use

tonni

RE: Date function

Here is a routine you can use


*/***************************************************************************
*/Program : function MSGNWAIT
*/System :
*/Purpose : Places a one line window message on screen and leaves it there
*/Syntax : = MsgNWait(Msg,Row,Clm,Color)
*/Returns : Logical .t. if successful
*/Parameter : String - Msg - Text to be displayed in the window
*/ : Integer - Row - (Optional) Top left screen row of message box
*/ : Integer - Clm - (Optional) Left Most Screen Column Of The Message Box
*/ : Integer - Color - (Optional) Color Of Message (In case You do Not Like My Choice)
*/Default : Row = C_TopRow
*/ : Clm = C_TopClm
*/ : Color = 5
*/Requires : Nothing
*/Changes : Nothing
*/Calls : Nothing
*/Calls :
*/Version : 1.0
*/Dated : 22/05/1989
*/Written By: David W. Grewe
*/***************************************************************************
*& Message
*/***************************************************************************
*/ Record Of Change
*/
*/***************************************************************************
parameters P_MSG, P_ROW, P_CLM, P_CLR
private P_MSG, P_ROW, P_CLM, L_PARA, L_LEN
L_PARA = parameters()
if L_PARA < 1 .or. type("P_Msg") # "C"
P_MSG = " "
release window MSGNWAIT
return
endif
if L_PARA < 2 .or. type("P_Row") # "N"
P_ROW = srows()/2+1
endif
if L_PARA < 3 .or. type("P_Clm") # "N"
P_CLM = (scols()-len(P_MSG))/2
endif
if L_PARA < 4 .or. type("P_CLR") # "N"
P_CLR = 5
endif
*
L_LEN = len(P_MSG)+2
if (P_CLM+L_LEN) > scols()
P_CLM = scols()-L_LEN
endif
*
if wexist("MSGNWAIT")
release window MSGNWAIT
endif
*
LcWINONTOP=woutput()
if !empty(LcWINONTOP)
define window MSGNWAIT at P_ROW,P_CLM size 3,L_LEN double color scheme P_CLR in window (LcWINONTOP)
else
define window MSGNWAIT at P_ROW,P_CLM size 3,L_LEN double color scheme P_CLR
endif
activate window MSGNWAIT top
@ 1,1 say P_MSG
*
if !empty(LcWINONTOP)
if LcWINONTOP != "MSGNWAIT"
on error **
activate window (LcWINONTOP) same
on error
endif
endif
*
release P_MSG, P_ROW, P_CLM, P_CLR, L_PARA, L_LEN
return " "

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login


Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close