Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA + add multiple cells in code.
Stab in the dark here but as a guess one of the cell addresses you are
referencing is not a number, but rather is text of some sort. Excel does not understand what you want to do when you try to add a number to a text string and you get a type mismatch error... HTH "Adam" wrote: I keep getting a data type mismatch. What am i doing wrong on the addition?? If Worksheets("Int Project").Cells(Row, 186) 0 Then Worksheets("Int Quote").Cells(Row, 109) = "Doors & Frames - " & "Apply " & Round(Worksheets("Int Project").Cells(Row, 184), 0) & " Coats " & "- Time: (" & (Worksheets("Int Project").Cells(Row, 72).Value + Worksheets("Int Project").Cells(Row, 78).Value) & " hours)" & " " & Worksheets("Int Project").Cells(Row, 186) & " Gallons of ____________" 'Average Doors and Frames Thanks.. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA + add multiple cells in code.
No I changed it to see if that was it, but it was not.
(Worksheets("Int Project").Cells(Row, 72).Value + Worksheets("Int Project").Cells(Row, 78).Value) is what I am trying to add, and they are both numbesr. "Jim Thomlinson" wrote: Stab in the dark here but as a guess one of the cell addresses you are referencing is not a number, but rather is text of some sort. Excel does not understand what you want to do when you try to add a number to a text string and you get a type mismatch error... HTH "Adam" wrote: I keep getting a data type mismatch. What am i doing wrong on the addition?? If Worksheets("Int Project").Cells(Row, 186) 0 Then Worksheets("Int Quote").Cells(Row, 109) = "Doors & Frames - " & "Apply " & Round(Worksheets("Int Project").Cells(Row, 184), 0) & " Coats " & "- Time: (" & (Worksheets("Int Project").Cells(Row, 72).Value + Worksheets("Int Project").Cells(Row, 78).Value) & " hours)" & " " & Worksheets("Int Project").Cells(Row, 186) & " Gallons of ____________" 'Average Doors and Frames Thanks.. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
finding multiple code dates for multiple item number | Excel Worksheet Functions | |||
Delete Blank Rows Code - Multiple Worksheets - Multiple Documents | Excel Discussion (Misc queries) | |||
macro copy/paste data from multiple cells to multiple cells | Excel Discussion (Misc queries) | |||
make multiple cells in 1 worksheet equal multiple cells in another | Excel Worksheet Functions | |||
Can you "duplicate" "copy" listboxes and code to multiple cells? | Excel Programming |