G
Glenn J. Rowe
I need to read in a variable and make sure it is in the exact format of
YYYY_MMM_DD_hh:mm:ss
Example... 2003_DEC_05_14:05:26
I tried the following code but it doesn't work...
if($variable=~m/(\d{4})(_)(\D{3})(_)(\d{2})(_)(\d{2})
)(\d{2})
)(\d{2})/)
{
#Continue with code
}
else
{
#Display an error
}
I am a self taught programmer so any help you can give me would be
appreciated.
Thanks,
Glenn
YYYY_MMM_DD_hh:mm:ss
Example... 2003_DEC_05_14:05:26
I tried the following code but it doesn't work...
if($variable=~m/(\d{4})(_)(\D{3})(_)(\d{2})(_)(\d{2})
{
#Continue with code
}
else
{
#Display an error
}
I am a self taught programmer so any help you can give me would be
appreciated.
Thanks,
Glenn