Date Entry Renders
Jan 14, 2009
Is there a way that I can set up two cells so that when a date is entered into one, the other renders something like "Reporting from XXXXX to YYYYY" where XXXXX is the Monday of that week and YYYYY is the Friday of that week?
So, for instance, if the user entered 1/14/09 into cell A1, then cell B1 would show "Reporting from 1/12/09 to 1/16/09"...
View 9 Replies
ADVERTISEMENT
Mar 6, 2014
I am working on a spreadsheet to create a school 'tracking' system based on excel. What I need is that as soon as a box in column B is ticked, a date (TODAY() is entered in column A. That is not so difficult, and I have used the formula in cells in column A:
=IF(ISBLANK(Bx);"";TODAY()), where x is the specific row.
So, keep cell A clear untill something is written in cell B. This works fine.
But, for the purpose I need to keep the TODAY() date fixed after entry. And it need to be erased again if the tickbox in cell B is emptied again. It need then to re-enter a new date after cell B is re-used.
View 5 Replies
View Related
Jun 19, 2008
I'm having a problem with data validation. I set an entire column so that it could only be a date between the first date in the list and the current date. I tested a few cells to make sure that it was working the way I wanted and I noticed that it allows a random number like 3 or 5 to be input after row 50. This would create a date in the 1900s. Why is this happening and how can I stop it.
View 9 Replies
View Related
Jun 17, 2006
I am attempting to pick up a date with time entry on a worksheet and place it into a TextBox on a UserForm. Format on the sheet is mm/dd/yyyy h:mm AM/PM. The UserForm is placing the value as mm/dd/yyyy 12:00 AM. here is the
Private Sub UserForm_Initialize()
If Not Range("dDate").Value = "" Then
TextBox2.Value = Range("dDate").Value
TextBox2.Text = Format(DateValue(TextBox2.Text), "mm/dd/yy h:mm AM/PM")
Else
TextBox2.Value = ""
TextBox2.SetFocus
End If
End Sub
"dDate" is the named range where the date is sitting. The format is also set on the TextBox2 exit event. Can anyone see why only the date portion is being transfered with the default 12:00 AM for no time component of the value?
View 3 Replies
View Related
Mar 27, 2014
I have a ComboBox on a UserForm. One of the fields that I fill in is a date.
After the date is entered I want to check if it's a valid date.
VB:
Private Sub cboEnterDate_Exit(ByVal Cancel As MSForms.ReturnBoolean)
' Make sure a valid date was entered, it must be in the format 2013/10/21.
On Error Goto ERR
'If Not IsDate(cboEnterDate.Value) Then
[Code] .....
ERR:
MsgBox "The date entered is not a valid date", vbInformation
Cancel = True
cboEnterDate_Enter
End Sub
The code:
VB:
'If Not IsDate(cboEnterDate.Value) Then
execute the If routine if I enter the date 2014/03/33
When I enter the date 2014/03/0001 it do not see it as an invalid date and exit the routine.
The code:
VB:
If Not IsDate(FormatDateTime(cboEnterDate.Value, vbShortDate)) Then
send the execution to the ERR routine if I enter 2014/03/33
When I enter the date 2014/03/0001 it do not see it as an invalid date and exit the routine.
How can I get the validation to catch the 2014/03/0001 as an invalid date as well.
View 3 Replies
View Related
Dec 31, 2008
I am not sure how many questions I can ask in one day, but I have one more. I am using VBA code for easy date and time entry on a spreadsheet...I am a complete novice at this.
I need to add additional columns to the range for dates and times.
also, is it OK to use the code for date and time on the same worksheet?
Code for Date:
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
Dim DateStr As String
On Error GoTo EndMacro
If Application.Intersect(Target, Range("A2:A100")) Is Nothing Then
Exit Sub
End If
If Target.Cells.Count > 1 Then
Exit Sub
End If
If Target.Value = "" Then
Exit Sub
End If
View 9 Replies
View Related
Feb 28, 2006
I want to type "121505" in a cell and it display 12-15-05. What formatting do I use?
View 4 Replies
View Related
Jan 22, 2014
I am trying to remove the duplicate entry of the date the list goes like this
01/22/2014 6:10
01/22/2014 6:12
01/22/2014 6:13
01/22/2014 6:15
01/22/2014 6:17
01/23/2014 7:00
01/23/2014 7:01
01/23/2014 7:02
01/23/2014 7:03
But I want
01/22/2014 6:10
01/23/2014 7:00
I have attached a file where I need to clean up column A but still maintain the rows sheet one is what I have sheet 2 is what I am hoping to achieve.
View 10 Replies
View Related
Jul 16, 2008
I have a workbook with several sheets, each of which represents a client. At the bottom of this sheet, I have a call log to record the times that we attempted communication, left a message, etc. Since it's tedious enough as it is, I'd like to save my team 2 seconds and a slight bit of that tedium by having the date an attempt was made automatically recorded in the row where the attempt is entered.
Let's say this all takes place in A47:D47. For example, if I called the client on 7/15/08 and left a message, I would record who was called in B47, the name of the caller (me) in C47, and the result in D47. If possible, I would like to have the date of the attempt (today's date on the given day) entered in A47 upon the entry of information in B47:D47.
View 14 Replies
View Related
Dec 12, 2011
I am attempting to create a formula which will detect of a cell is empty, and if it is empty enter the date by using TODAY(). I also dont want this date to change when opened after it has been entered. This is what I have been working with so far.
Code:
=IF(A1="",TODAY(),"")
Code:
=IF(G9>=TODAY(),A1=1,"")
I am trying to use the second formula to change the value in the cell "A1", but instead it just returns a true/false statement in the cell with this formula.
View 6 Replies
View Related
Jan 12, 2012
How can I get an automatic time & date entry into cell B1 based on a alphanumeric entry in cell A1. The time and date must not re-calculate every time the workbook is opened.
View 4 Replies
View Related
Jun 9, 2006
I have a macro which is designed to collect information and then assign each piece of information to a defined cell. I have Dim statements for each piece of information i.e.
Dim Info1 = Surname
Dim Info2 = Initials And so on.
Dim Info11 = Date of entry
This is working perfectly but the date when entered is reversing to american format. 08/05/2006 becomes 05/08/2006. Type into the cell manually and it works perfectly let the macro put the date in and it changes format. Can anyone supply a line of code that would format the date to dd/mm/yyyy? Then I could insert it after the part of my code which basically says go to this cell and put in the date.
View 3 Replies
View Related
Aug 15, 2006
I am writing a roster spreadsheet and it has cells with drop down lists using validation lists to fill in the start and finish times, as we run a nearly 24 hour business it is possible to accidently start someone at 2.00am and finish them at 10.00pm. In the cell which calculates the time rostered I want it to display a messagebox if the hours exceed 10 hours or go into negative.
I need to "wife proof" this sheet as this stuffs up the total calculated hours and total costs.
Would I do this through validation on the cell with the formula calculating the times orr though a macro on the sheet module?
View 3 Replies
View Related
Jan 9, 2008
When a user inputs a month and then a day, I want to be able to check to make sure that the day entered is possible in that given month. Is there a way to do that which is not too complicated?
View 9 Replies
View Related
Jan 30, 2008
I have a old spreadsheet file which I opened up in Excel 2003. It has a few worksheet tabs. 2 worksheet tabs seem identical. I will reference it as Worksheet1 and Worksheet2. In Worksheet1, I enter a date i.e. 1/25/2008 in any cell. It enters as inputted. But in Worksheet2, I enter the same date i.e. 1/25/2008, it appears as 1/0/1900. No matter what date I enter in Worksheet2 in any cell, it always appears as 1/0/1900. Now when I look at cell in the formula toolbar, it sees as a Math Formula meaning, it looks like this: =1/25/2008. How do I correct this Worksheet to recognize any date inputted, not to see it as a Math Formula?
View 4 Replies
View Related
Aug 11, 2014
I am trying to get my User Form to work whereby I choose a pre-determined date entry. I have tried some coding but cannot get it to work. What code I need to add in VBA for this to work? I have tried to alter the time entry from my previous post that was solved but are doing something wrong.
View 11 Replies
View Related
Dec 12, 2011
I have cells on my spreadsheet which contain: =now() and they work as they should - displaying the date and time at the moment of entry. Unfortunately the cells update when other info is added at other locations on the sheet - is there a way to ensure they enter the current 'now' only at the point of initial entry - such that the data doesn't then alter?
View 3 Replies
View Related
Feb 17, 2012
I am looking for a formula or VBA that will be in each in cells D5:D300 and will look at the value entered into the cell in column C and change the 4 digits into the date and time in the same format as NOW() returns.
Example
2045 becomes 17/02/2012 20:45
But I would also want it to see if the 4 digits that represent the time are after 14:00 and before 00:00 then the date would be the date in cell A1-1
example
Cell A1 18/02/12
2045 becomes 17/02/2012 20:45
View 2 Replies
View Related
May 28, 2014
What I want to do is if I add data into B7 or F7 then the current date will appear in J7. I also don't want the date to change every time the project is opened.
Thus,
If I enter "withdraw or any word" into B7 or F7 - The current date (4-Dec) would appear in J7.
then if I close excel and I open it tomorrow, J7 would still read as 4-Dec, while if I enter "deposit or any word" into B8 or F8, the current date (5-Dec) would appear in J8.
- would need to be able to enter multiple entries on one day as well.
- also i am not familiar regarding macros.
View 2 Replies
View Related
Jul 26, 2008
Is it possible to have a cell, say B1 - which will return the Time and Date Value of when something is entered into Cell A1?
Example, I type "Hello" in Cell A1.
Now B1 will show me the Time and Date which i typed in Hello into A1.
View 9 Replies
View Related
Mar 24, 2009
I have a date in H34, 21/03/2009.
In I34 I have the same date again, except formatted as MMMM YYYY so its showing "March 2009".
In G10, I want the cell to read: Number at end of March 2009, with the month and year being taken from the date range. To be honest, I can get the year okay using the Year() function but cant get the month as cant convert it back from a numeric.
View 9 Replies
View Related
Jun 28, 2009
I need a function that records the time and date in a cell, say a2, when data in entered in to another cell, say a1 in the same spreadsheet.
This way I can tell when data in a cell in my spread sheet is updated.
View 9 Replies
View Related
Dec 8, 2009
If I enter into a textbox1 the following 09/31/2009 the result is that its not a date (because there is only 30 days in September - not 31). OR if I put in "13/25/2009"
Can I have a macro that checks whether or not its a valid date and if so a message box appears that says:
"Invalid date"
View 9 Replies
View Related
Dec 7, 2008
In my form I have the user enter in the current date in Textbox1. My program is designed only to work in 2009 so I want to check to make sure the 1) the date is in 2009 and 2) textbox1 is not empty. If it is empty then it displays a message box with "Not a Valid Date. Please Enter Date as MM/DD/YYYY. Date has to be in 2009" - this doesn't work. Second, if the date is outside of 2009 it is to display a meeage box saying "Date has to be in 2009".
Here is my current code which is not working.
Private Sub TextBox1_Exit(ByVal Cancel As MSForms.ReturnBoolean)
If TextBox1 = vbNullString Then Exit Sub
If IsDate(TextBox1) Then
Else
MsgBox "Not a Valid Date. Please Enter Date as MM/DD/YYYY. Date has to be in 2009" ...
View 8 Replies
View Related
Apr 3, 2007
i try to lock cells in the area the VBA code affects. My goal is to actually have affected cells by this VBA code lock immediately after anything is entered in the affected cells. Area needing Debugging is in the If - Else portion. My worksheet will be protected.
Private Sub Worksheet_Change(ByVal Target As Range)
Dim LLoop As Integer
Dim LTargetRange1 As String
Dim LDestRange1 As String
LLoop = 10
While LLoop <= 1000
'Link column B to A
LTargetRange1 = "B" & CStr(LLoop)
LDestRange1 = "A" & CStr(LLoop)
If Not Intersect(Range(LTargetRange1), Target) Is Nothing Then
If Len(Range(LTargetRange1).Value) > 0 Then
Range(LDestRange1).Value = Date
Else
Range(LDestRange1).Value = Null
End If
End If
LLoop = LLoop + 1
Wend
End Sub
View 7 Replies
View Related
Jul 6, 2007
I've looked through the threads and while I have used Data Validation to stop duplicate entries, I want to also make certain that those entries are only Dates. In other words, if Cells A1:A10 are to contain unique dates, I use Data Validation with the Custom condition below; = COUNTIF($A$1:$A$10,A1)=1
If the user enters the same date more than once, an error message pops up. However, the user is not prevented from entering a range of dates in a cell such as "July 5-7". How can I validate that the date is entered only once AND the entry is a valid Date. With Data Validation it seems I can specify to allow a DATE with specific criteria, or the Custom, but I can't see how I can do both.
View 3 Replies
View Related
Sep 5, 2007
A form loads and the first thing the user is to do is enter a specific date in a text box (preferably in, "mm/dd/yyyy" format.)
Is there any way to set up the text box so that when the form loads, the, "/"'s (slashes) are already in place? And can I set it up so that if the user enters in the date in any other manner aside from, "mm/dd/yyyy", that it will give them an error?
Finally, I want the user's date input to store on a worksheet (in row, "G".) So the first time the user uses the form, they type in a date and it stores the date in the FIRST AVAILABLE CELL IN ROW, "G." (example: "G1") The next time they use the form and type in a date, it is to store in, "G2", then in, "G3", ect. Each time they fill out the form, the new entry is to save in the next row beneath the previous entry.....
For other text boxes and combo boxes I have been using the following code to do this:
Sheets("Sheet1").Range("A" & intRow) = Text.Value (or Combobox.Value - depending on whether it was a text box or a combo box.)
Unfortunately I have NO idea how to apply this logic in regards to text boxes that are to store dates.
View 9 Replies
View Related
Feb 28, 2008
formula to auto input the date into a specific cell once one cell has been changed
View 6 Replies
View Related
May 13, 2014
On sheet 1, I have dates in column A, then numbers under LabA through C. On sheet 2, I would like the contents of columns B, C, D to autofill when entered. However, I would like to display only the last entry. For example, Lab A (column B) is currently showing "7" in cell B6, if I enter a number in B7, I would like for sheet 2 to autoupdate cell B3 and display that new entry instead of the "7".
View 1 Replies
View Related
Mar 20, 2014
I have a percentage in R3.
If I make an entry in D13 then I want the R3 to be duplicated into C27 otherwise C27 should be 0.
View 4 Replies
View Related