Well, I *think* I've fixed it by replacing the line:
destrange.Value = SourceRange.Value
with:
SourceRange.Copy
destrange.PasteSpecial
It seems to be pasting the larger cells now. Weird.
But why do I only get an error with cells containing too many characters? The other times I run the macro, the SourceRange would seem to be multi-cell (again, I did not write this original code), and everything runs fine.
I didn't know the error line number before, but I just turned off my error handling and tried it again. The line number is Line 103: "destrange.Value = SourceRange.Value
I'm sorry, I completely forgot to list the error. It's 1004 - Application-defined or Object-defined error. Usually I only get that when I'm trying to access "Row 0" or something.
The macro stops halfway through, where it's already added the new worksheet to my current workbook, named it, and...
I need to include a macro in my spreadsheet that will take a directory of files and combine them into a single specific sheet in my spreadsheet. I found code here(http://www.rondebruin.nl/fso.htm) that I could tweak for my specific purposes, and it works in most cases. After a few test runs...
I'm working with the Worksheet_Change event for the first time. It works fine when individual cells are changed, recalculating all my relevant columns. Unfortunately, copy/pasting or deleting entire rows of cells will call the subroutine so many times that everything slows down to a crawl. I...
Thank you for your replies. Unfortunately, that gives me the same error beep and disabled Undo, PH. (Also, it updates the column even when all the user has done is click on a cell). Even changing it from SelectionChange to Change didn't fix it, though. Any other ideas in your hat?
I’m trying to add a “Last Time Updated” column to my spreadsheet of product information. I got it to work (it updates Cell BQ every time any cell in that row is changed), but it has “broken” the Undo function in Excel. I just get an error beep and nothing is undone. If I can’t fix that, I’ll...
Hey, I think I've come up with something that works. I'll post the code below in case someone stumbles upon this later. Thank you for trying to help me, though. I appreciate your time.
Private Sub UserForm_Initialize()
ActiveWorkbook.Sheets("Sheet1").Activate
'Look for the first...
Are you using ComboBox and DropDown interchangeably or do they mean something different?"
I just meant that a dropdown is part of a ComboBox. When you first see the ComboBox, there is nothing in the field, but you can see the limited choices available once you click on it.
"Why 15...
Let's say the spreadsheet has 6 products, and their color column looks like this -
Color:
Spruce
Moondust
Starry Night
Spruce
Pink
Starry Night
My form would have 15 or so comboboxes, empty as a default, with the list of Color Family choices waiting in the dropdowns. I would fill in the...
Now you are saying that the user does not do this. Only TWO people do this. But they are doing the selection of a Color based on WHAT? "
My original question was referring to our 2 employees when it said "users". Suppliers as "users" didn't seem important at the time; I'm sorry if it was...
That is how I originally programmed it, but the Boss would like the Color Family to be determined only by two approved employees, for consistency. One man's Light Brown is another man's Medium Brown, and all that. The suppliers will use the main data entry form and send it to us. Our two...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.