The code that I'm using is supposedly not allow spreadsheet to be opened after a certain date, or does not allow a user to press any of the command buttons and comes up with a message saying the spreadsheet is closed for new entries.But is not working for me.
When I remove "Release date:" from "Release date:24 December 2008," excel will automatically change the text to "24-Dec-08." Yes, I did try to format the column to "text" before using find and replace.
This wouldn't be a problem, except that half the dates are in Dutch, so only half the dates are changed, which means that I can't make all date formats in a column uniform.
I have a small project at work where I am being asked to put a simple spread sheet that will calculate a start/stop time - and also include the date. For example:
Start time 5pm, date: 3/13. The spread sheet to auto calculate what the stop time and date will be if a specific amount of hours is to be calculated. For example in this case, 12 hours. From calculating in my head that would be 5am the following day. However, how can I get this in excel to work and therefore all i would have to do is enter the start time and date, + 12 hrs, and excel would calculate the time/date after the additional 12 hrs.
I placed the code below in the ThisWorkbook section of a Service Request macro. The intention was to block users of saving the input they had just entered into the blank template. However, some continue to do it, despite the code. Obviously it is not as tight as I expected.
Does anyone know a better, tighter method, short of killing the offending user (which I am tempted to do, believe me!)?
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) Dim LoginName As String LoginName = Environ("username") If LoginName "chuckdrago" Then If SaveAsUI = True Then Cancel = True MsgBox "Saving this form is not allowed! Print a Copy" Else ThisWorkbook.Saved = True Cancel = True MsgBox "Saving this form is not allowed! Print a Copy" End If End If End Sub
Private Sub Workbook_BeforeClose(Cancel As Boolean) ThisWorkbook.Saved = True End Sub
Moving between different sheets changes the procedure window, which is a good thing, but can also can be error prone and annoying to search through several windows searching for the procedure or module currently working on. Is there a setting somewhere to prevent VBE from changing the current procedure window?
I have a few excel files in a common shared folder. I want to allow other users to access this folder to make changes in the worksheet but should never allow them to delete the file. How can i do this?
I have a sheet with 3 columns and I would like to have these 3 columns fit the screen so that an attractive user interface is created. I do not want to be able to scroll to blank area to the right of column C
I know nothing about Visual Basic and was trying to follow the following
Private Sub Worksheet_ Active () Me. ScrollArea = Range (Me. Used Range, Me. UsedRange (2.2) .Address End Sub
I am using Excel 2000 and I either kept getting error messages or after changing the visual basic sheet headings to worksheet and Active respectively ( two headers at top of page) the macro still failed to work.
Colo HTML does not seen to work in the visual basic window so I cannot show you the page.
I have to create a number of spreadsheets with changing dates / times / both.
This would be a fairly good example:
Add one day + 1 hour for 31 days of a month. "01/01/2014 01:10" "02/01/2014 02:10" "03/01/2014 03:10" "04/01/2014 04:10" "05/01/2014 05:10" "06/01/2014 06:10" "dd/mm/yyyy hh:mm"
The above format is important, and - it has to be in quotes.
Which, if necessary I will manually add using replace, but would prefer not to.
So I may then need to take the first date... lets say 06/12/2013 07:00 then, Add one day + 3 hrs 30 mins.... so as the days roll between 1 to 31 it is obviously going into the 24 hour clock, rolling argument.
And, to top that -
1. the csv then needs to be put into software (I assume it reads the data in the sheet and not the formulas). 2. I can't have extra columns as they would need to be deleted.
I have tried copying down, like a standard auto-fill but it always goes wrong.
I am creating a spreadsheet on a British-based system using the d/m/y date system as default, but I am unfortunately entering data using the american m/d/y system and would like to change the default to the american system.
Amongst the several sheets contained in my workbook, there is one called 'Inspection Report'. Users fill in whatever data is required in the other sheets, and once they get to this one, they are supposed to enter a number from 1 to 3 into Cell X1 (which is currently selected) before they select anything else. Unfortunately, I am currently unable to stop them from doing what they should not be doing.
So, I would like to have a notification of some sort pop up into their face if they click or move the selection anywhere else while Cell X1 is still empty. Something like a validation would be nice.
Let's say I have column C blank, but every time it's filled in with something I want column A to be today's date and B to be current time. Unfortunately, the functions NOW() and TODAY() don't give me what I want. They get recalculated every time that I update the spreadsheet. Another thing that I can do is just press ctrl+shift+; to generate a non changing date/time, but I want it to happen automatically (being super lazy).
I am looking for a function to convert time given by my computer (Local time) in EST (Eastern Standard Time). We are several users of a same file (with timestamp macros) and all time need to be aligned to one time zone (EST), even if all users are working in different time zone (EST, CST and IST).
I get a "Run-time error '9': subscript out of range" error when calling a userform. The code opens a reference spreadsheet then shows a userform with a combobox and two command buttons (Continue and Quit). The userform has a private initialization sub-routine to populate the combobox with values from a list on the reference spreadsheet. When the userform is called the error comes up.
Here's my problem: The code was written on my computer and saved as an Add-in. The add-in has since been installed on a number of other computers and works properly. Recently I tried to run the code and this error started popping up, don't know what changed. All versions of Excel are the same and haven't changed.
BRF = ActiveWorkbook.Name If BRF = "Blank upload.xls" Then Workbooks.Open path & "QC Data AnalysisQCDA ref.XLS" OtherBRF.Show Workbooks("QCDA ref").Close SaveChanges:=False Goto 1 End If
Can I adapt this code so that users receive the alert if they try and go to the next field without filling in the required ones, or - better - to combine it with a code that does not run a macro, but instead gives the alert, if the required fields have been missed. (I don't require anything to do with printing, this was the closest code I could find)
Private Sub Workbook_BeforePrint(Cancel As Boolean) If Sheet1. Range("A1").Value = "" Then MsgBox "Cannot print until required cells have been completed!" Cancel = True End If End Sub
Is it possible to stop the #REF! error appearing in my formulae when I make a change to my spreadsheet? I have some complicated spreadsheets that take a lot of re-building whenever I need to make changes because of the #REF! error. I tried turning off automatic calculation and that seems to work, until you calculate, then the errors appear. I find myself copying formulae into a text file and then re-pasting back into the spreadsheet after making the changes - there's gotta be a better way! (Using Excel 2003).
I have created a daily schedule which has a number of factory variables taken into consideration which determine the date and time a particular product should, barring any mechanical problems, come off the machine. (see attached spreadsheet).
The date at the top will be editable by me only so that when I update the production quantities, the “date/time off” column automatically re-adjusts to the remaining quantities.
The formulas are a little long winded, but I have left them that way whilst I try and develop it. I should be able to figure out how to condense them later.
My problem is that the “date/time off” on the right works excellent, but over a 24 hr period.
Ordinarily, we work a 12 hour day (6am to 6pm) with overlapping shifts to cover breaks, and 20 mins warm up at the start of the day for the machine, thus maximising a 12 hour day.
Of course if demand exceeds the allotted time we put on overtime.
Is it possible to specify that normal days are only 12 hours so that if a product exceeds 6pm, it flows into the next day with the balance starting at 6:20am?
And, if the production for the week exceeds the time could I stipulate particular days which we deem are suitable for overtime? Ie, we decide Wednesday is a 14 hour day and not 12.
I had toyed with the idea of creating a 365 day table/calendar, on another worksheet which would have its individual allocated hours in an adjacent column and somehow link them to the date/time off, perhaps by way of a VLOOKUP, but I have been chasing my tail trying to figure out how to implement it.
I need to copy and paste data from the internet into Sheet 2, but it's not in the correct order, so I must swap column A and column B in Sheet 2 only. The problem with this is that when I swap them, the linked cells swap as well, which destroys my data on Sheet 1 columns C-Z.
Is there a way that I can keep the cells on Sheet 1 completely static, so that it only reads the data I put into the corresponding cell on Sheet 2?
Or maybe, is there a way I can just swap the cell information in Sheet 2 without messing around with the formatting? Just a complete swap of A1>B1 and B1>A1?
The company I work for does not use the usual calendar dates and uses a modified calendar. As an example, the month of January is Dec 31 thru Jan 27, February is Jan 28 thru Feb 24 and so on. I need to group data using a pivot table and summarize data by month, but as I just described above, calendar months will not work. Is there a way to modify what Excel sees as monthly dates?
I use the 'on time' function to kick users out of a shared workbook after 30 minutes of inactivity (i.e. no cells updated). Technically it works, as it does kick out the users.
However the time after which it does so seems to bear no relation to the time I have instructed. Sometimes shorter, sometimes longer! If it is was always longer, I would be happy that there is an error in my code somewhere (i.e. the time value is resetting on an unexpected event that I need to find and alter).
When opening a .CSV created from a third party software, one of the columns is converted to date format. The numbers are imported in #/# format. and Excel changes most of the numbers to 2-Jan, 3-Jan etc... This would not be that big of an issue if I could simply set it back. Clearing format or changing to text converts it to a 5 digit number.
The only way I have found to get it to work properly thus far is to open a blank sheet and import data and setting the column to text prior to import.
I would like to find a way of opening the CSV file without all the extra steps. Is there a setting that can be turned off?
I have referenced data in two colums on a sheet A and B. Column A contains the latest data, each month i insert new column (moving column A to column B). However all of my references continue to follow the original data (eg will change from column A to column B). this happens despite using Absolute references. (=$A$1). Is there a way to lock these cell references to only ever display column A etc?