This script works great in 2003 in formatting text brought from Access, but fails in 97 - unfortunately I don't have direct access to Excel 97 - can anyone with it (or with a compendious knowledge of the differences!)
My company has several users that access a file (File A) that has a macro in that opens another file on their F drive called TEST.XLS. The code (in File A) to do this is:
Workbooks.Open Filename:="F: est.xls"
Just recently this code has failed for some users but not others. For those where it failed I confirmed that they do indeed have the file located on drive F.
As a test, one of the users where the above code failed ran the macro recorder while opening the file (Test.xls) on their F drive. The recorder produced the following code:
It works great in xl2003, and it works properly in XL2007 until you try and change it. I changed the column F to Column D and now it gives me a #value.
I convert text file into Excel. Then what I want is to look in column C for cell value “UNT:” (it is chopped word account: ) and copy value what is in the same row next column D into column K.
Then in column K copy down the value until next not empty cell.
My problem is that it works on Excel 97 and 200 but 2003 doesn’t work.
The below code works fine in excel 2003 but when I run it in excel 2007 it crashes excel. (Microsoft Excel has encountered a problem and needs to shut down etc etc)
I often need to use Paste Special . .. Values, using Excel 2003. So I recorded a Macro into "Personal.xls" and assigned a shortcut key combination "CTRL-Shift-V" so that it would always be available. I first select one or more cells and hit CTRL-C to copy to clipboard, click on another cell, then hit CTRL-Shift-V to run the following macro:
It often works . . . and it often fails. When it is working it seems to keep working over and over. When it is failing it keeps failing. So it is almost as if there are two "modes" of operation, which for lack of terms, for this post I will coin the terms "fail mode" and "fixed mode". Once I am in one of the two modes, it stays there for a while. When it is in the "fail mode", I always get the dreaded:
Run-time error 1004: "Pastespecial method of Range class failed".
Since this problem is very intermittent, I believe this is why there are so many posts in the Internet about this, and so many people are replying back "it works fine for me". I have seen many solutions offered but none work so far for just a simple shortcut key to do a PasteSpecial :Values. Some solutions "work" . . . such as adding the PasteSpecial button to the Toolbar, or pressing ALT-E-S-V <Enter> - but both of these bring up the Paste Special dialog box which I want to avoid.
I spent days trying the many solutions offered but so far all I have found is a trick to convert Excel from "fail mode" to "fixed mode". The trick is to add a line to the macro to first do a "Paste Special: Format:
Then select and copy any cell/s, click on another cell, and run the macro just ONCE - it will paste the formatted value successfully and you are now in the "fixed mode". Now you can remove the PasteSpecial:Format line that you just added, to get back to the original macro with just the "Paste Special: Values" line:
Now Excel is in the "fixed mode" and the original macro will once again start working properly. BUT only for a while !! Then some time later, usually within a day or a couple hours . . . Excel goes back into that "mode" where once again the macro fails repeatedly. I have been unable to isolate what causes the mode to return to failure.
Any simple way to either change the code so that it ALWAYS is successful, why this often is not successful ? I believe that the fact that adding in the Paste Special : Format code and running it just once to fix the problem, also could be a clue as to what causes this problem to "sometimes" occur.
I have an annual leave (vacation) work book with a summary page work sheet and separate work sheets for each month i.e. Jan, Feb, Mar.....to......Dec. In order to protect the formulas I have protected them by allowing only access to the input cells on each work sheet and the protect each work sheet.
When someone either joins or leaves the team I have to manually unprotect each sheet and protect again when I have completed the amendments to each of the 13 tabs.
macro code I would need to unprotect all the works sheets in one go (as I use the same password for all the sheets) and reset the passwords (protect) the sheets with more macro code.
I will be running the two macros from my own personal.xls file and ideally they would be fully automatic i.e. I would not need to input the passwords in to unlock or lock the work sheets as the password would be written in the code already
I am trying to conditionally format using AND() to reference if there is a value in the top line of a table and the title in the right most column for each cell in the table, the formula I am using works when i paste it into cells (i get the correct TRUE or FALSE for each cell in the sheet) but is not working as a format formula, I dont get an error but the shading does not happen.
I need to create conditional formatting on a worksheet where I need to change the cell colour based on 6 cases.
The VBA that I have found does not work with referenced cells to another worksheet in the workbook which I need as all the data is referenced with calculations.
I also need to specify the cells that the VBA will apply to as I need to apply 6 or 7 different different sets of conditional formatting on the same worksheet to different groups of cells.
The problem i have is with the sum offset function. The formula i use is to sum up the totals for each page of an accounts document. At the top of each page there is a column with " £ p " in it and i use that as the basis of the formula. This formula is entered in the bottom of every page to calculate the total for each page.
This works all the time but when text is entered into column F (the column i'm adding up) it messes up with the formula. the formula will instead find the £ p but for a page 2/3 pages before the one i'm calculating on. This formula only faults when text is entered. Another thing; this excel sheet i'm working on is an output from a different computer program. it is outputted as csv file i think.
Like i said the formula works a treat except when text is entered. The obvious way around this not to enter text but that is not an ideal option. I cannot think of another way of calculating the total for each page although i'm sure another exists.
Im using the following code on a User login userform. This code is for the Login command button to access the workbook (the user clicks on it after entering there username and password).
For some reason if the password is numbers only it just returns message box "Incorrect password, try again."
As soon as I put a single letter into the password it works fine,
I use Excel 2003. I want to do a conditional formatting on a cell (e.g. A1), which value is from an If() formulas. The value could be a percentage or a text “DataNAvail”. The conditional formatting on A1 is based on another cell’s value (e.g. B1), which is also a percentage.
Since in Excel 2003 there are only three options for conditional formatting. I used two for green (A1 greater than B1) and yellow (formulas in A1 equals AND(A1<B1, A1>=B1*0.75)). I want to set A1 to red when its value <B1*0.75 or is “DataNAvail”. Since they are not the same type, I don’t know how to do it.
In column P of my Excel 2003 worksheet named: Data, I need the following text in the cells to have the interior colors (as shown below):
Any Situation - RGB = 255,204,0 (with black text); Apples - RGB = 153, 204, 0 (with black text); Apples / Rasberry = 153, 153, 255 (with black text); Jam = 128,0,128 (with white text); Nectarine = 0,0,128 (with white text); Nectarine / Apples = 255,255,153 (with black text); Nectarine / Rasberry = 255,204,153 (with black text); Orange = 255,153,204 (with black text); Rasberry = 153,204,255 (with black text); and Sausage = 0,0,0 (with white text).
The range is P3:P20
I tried using conditional formatting but it only allowed me to use three conditions.
I am having a fit trying to get this darn spreadsheet to do what I need it to do. I have to flag rolling dates on a spreadsheet (i.e. if a training date is to occur every three years, I need for it to change colors according to the date given - like if it is past three years, then it needs to turn red. if the date is in the next six months, it needs to turn green). I have already coded the spreadsheet to change dates every day, but when I use the EDATE function in the conditional response and try to copy it to the cells in the rest of the colum, it won't work.
I have a series of tabs with data, 25 columns by 600 rows, all with numbers. A cell should be red and lined out if its' corresponding cell on the very last tab is less than 50. I've tried to name range the area on the last tab (RawBuyers) and use it in a Formula Is CF on the first worksheet, but I get errors.
I'm seeking help with a CF formula that I can apply to each tabs data range.
I've seen threads similar to my issue, so I apologize if this is redundant (but nothing I've found is doing the trick.)
I'm looking for a way to use conditional formatting to flag a cell in a list if the user enters a value that already exists in that list. Just trying to keep any values from being entered twice.
I understand how to set cond form to flag a cell, but not what criteria to enter to activate the formatting when a value has already been used.
I work in a call centre and I record my daily figures. My target is 82%, and I would like a bar chart in Excel 2003 to colour the chart according to wether I hit target or not. If my daily figure >=82% the bar should be green.
When I copy from Excel 2003 (values & formulas) and paste special into Excel 2007 i get the option screen to select unicode text,sylk etc instead of the other screen with the option of values,formulas,formats etc.How can I select the option for value,formulas? Sorry cannot attach a screen shot as it is above the allowed limit.
I'm having a 6000+ records, (contacts DB) exported in Excel 2003 format from MS Outlook.
Except the "First" and "LastName", all other contact elements are in the field "Notes" (which is the BZ column according to the exported outlook layout) multiplied by 6469 (records in total)
Now, I want every time to take the part of the text says "TER:something..." (part of which is date, but not every time with the known format dd-mm-yyyy, as you see here is yyy, followed by something else, with parenthesis here and maybe more data) and copy it in a new cell..., e.g:CO Column, same Row...
Above and every field which by the way is formatted as General (and it is text mainly) are made by merging older excel fields where data laid here and there, that's why you see the commas...with the method of a module with the following code:
Function MyMerge(Rng As Range) For Each Cell In Rng Temp = Temp & Cell.Value & ", " Next Cell Temp = Mid(Temp, 1, Len(Temp) - 2) MyMerge = Temp End Function
Note1:Records with the above string (TER:dd-mm-yyy) are 771 from 6469. Note2: As an alternative solution I can see an extraction of the TER:dd-mm-yyy string and the copy in a new place, like the:CO Column, same Row...
Is there any way users can cut and paste while keeping the Conditional Formatting of the source cells intact? It is the same as copy-paste and then delete the source cell contents after copying.
Is it possible to protect an inserted text box from being moved, stretched, etc. while allowing data input into the cell/s? I'm using a 2003 version of excel.
I've attached the sheet in question. The yellow text boxes are what I want to lock, yet still allow data input.
This refers to Excel 2003. I will be dragging contents of cells to another place on the same worksheet. To make myself clear, the text must be moved from the source cells to the destination cells, leaving the format of both source and destination cells - such as borders and fill - unchanged.
NOTE: I know that I can copy the cells and return to the destination cells to delete the content that I want to move. This wastes time when doing many drags and drops.
NOTE: I know that I can paste special, pasting the Values only. Again, this is a lot of extra clicking or keyboard shortcuts. Again this wastes time when dragging and dropping many times.
I am using Excel 2003. I have a spread sheet and I am trying to use conditional formatting. But I can't figure out how to use conditional formatting across multiple columns and so I have been doing each column individually which has been kind of a hassle. I also am trying to figure out how to put in a formula so that every occurrence of a certain text will show up a certain color. I know that I can just do "cell value is", "equal to" and click on the cell, but the information in this spread sheet is organized alphabetically and is going to be added to frequently therefore every time I add information it re-organizes. This then messes up my conditional formatting because the text value that was in the cell gets bumped up or down.
Date: 17/09/2013 KO: 19:45 Ref: B Malone Att: 7,574 extraction of text from the above text string which is say in A1. What l need is for Date to go in A2, KO in B2, Ref in C2, & Att in D2. I'm using Excel 2003
I was wondering if it is possible to have cells formatted based on the presence of an autofilter? I have a large worksheet, and to clean it up I would like to make the entire sheet (minus the category headers) invisible. Then, when the user applies a filter, the cells become visible.
I am creating a heat map using two variables from a questionnaire: firstly the number of people impacted by a question; and secondly, the level of the impact. Respondents are asked to give these values in two adjacent cells. These are then multiplied to give a weight eg 1000 people x level 3 impact = 3000. I have used Conditional Formatting to colour the cell according to the impact level (0 = none - white (default), 1 = moderate - tan, 2 = significant - orange, 3 = high - red). What I want to do is then change the font size to give an indication of the number of people impacted, eg 1 - 1000 font 8, 1001 - 3000 font 12, 3001 - 8000 font 16, 8000 - 2000 font 24 etc. The size of font and colour will then represent the number of respondents and their impact.
I can't use Conditional Formatting as the value of 3000 could be derived from 1000 people at level 3 (red), or 3000 people at level 1 (tan). Is there another way of setting the font size depending on the cell value, eg by VBA?
On one of our computers at work, Excel is acting especially strange. The conditional formatting in Excel on one of our computers is not working. In addition, we cannot fill a cell with any color or change the color of the writing. We can click a color for the letters and type it in, but immediately after another cell is highlighted, the writing goes black again. When we try to highlight multiple cells with the cursor, the cells are black instead of the normal color. This happens to not just spreadsheets that are new, but existing spreadsheets on our shared drive from only this one computer as well. No other computers are affected this way. All other computers show the spreadsheets fine and do not have any functionality issues.