Solved

Mask Edit Control & Date

Posted on 1998-11-06
12
296 Views
Last Modified: 2010-04-30
I have a field in an Access database set as a date and with a mask as date mm/dd/yy. On my app I have a masked edit control set to retrieve this field the mask property is set to 99/99/00;0; and the format to mm/dd/yy.  When I run my app it will display 11/24/_8 if the year is set to 98 in the database. If I turn the 98 to 68 it displays fine in the control.  When debugging booth the mask and the database field say 11/24/98. What could be the problem? Thanks.
Tried to remove mask from database but still get the same result.
0
Comment
Question by:robhas
12 Comments
 
LVL 7

Expert Comment

by:Inteqam
ID: 1443658
try to remove the mask from the database.

0
 

Author Comment

by:robhas
ID: 1443659
Removed the mask from the field in the database but it still happens.
0
 

Author Comment

by:robhas
ID: 1443660
Edited text of question
0
 
LVL 7

Expert Comment

by:Inteqam
ID: 1443661
can you provide me with the code ,
to Hanzala@rocketmail.com

0
 

Expert Comment

by:BC111398
ID: 1443662
Try Setting The Input Mask To 99/99/99;0;_
0
 

Author Comment

by:robhas
ID: 1443663
Not the solution, still working at it.
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 

Expert Comment

by:neelam_s
ID: 1443664

 for date
set the format ddddd
and mask is ##/##/##
Now try it.

0
 

Author Comment

by:robhas
ID: 1443665
Does not work.
0
 
LVL 13

Expert Comment

by:Mirkwood
ID: 1443666
Try  ##/##/## ##:##
0
 

Author Comment

by:robhas
ID: 1443667
This answer does not work either.
0
 
LVL 1

Accepted Solution

by:
bear454 earned 70 total points
ID: 1443668
forget the masked edit, use format(value,"Short Date") to represent the data in a standard textbox or label.
If you need to do fomatted input as well, break it into separate text boxes for month, day & year - Use month(value) day(value) and year(value) to return the separate parts of the date.
0
 

Author Comment

by:robhas
ID: 1443669
It gave me very close to what I needed.
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now