ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Worksheet Change event (https://www.excelbanter.com/excel-programming/345740-worksheet-change-event.html)

Kevin O'Neill[_2_]

Worksheet Change event
 
Don't know what you call this, but here goes...
This ones a little tricky, to me atleast. The display comlumn will be
empty. When the data under D,L,W,S is inputted i need it to the display
the formula (Disp.). It would be really nice to be able to group any (D
W L S) that have the same value aswell. I'm thinking that's the tricky
part.

Here's my table, it is not limited to 2 rows.

Disp. D L W S
D+.5(L+W) 1 0.5 0.5 0
D+.5L+S 1 0.5 0 1

Any suggestions on how to approch it? This will be on a Worksheet
Change event that much I can do, just not the rest.

Cheers.
Kevin.


Kevin O'Neill[_2_]

Worksheet Change event
 
Better looking table.

Disp. D L W S

D+.5(L+W) 1 0.5 0.5 0
D+.5L+S 1 0.5 0 1


Kevin O'Neill[_2_]

Worksheet Change event
 
Any idea's on how to approach it?


Kevin O'Neill[_2_]

Worksheet Change event
 
Here's what I got so far. Pretty simple. I need to figure out 2 things.

Cells(11, 2) = Cells(11, 3) & "D+" & Cells(11, 4) & "L+" & Cells(11, 5)
& "W+" & Cells(11, 6) & "S"

1) if any of the cells is equal to 0, then write nothing, instead of
"0L" or "0W".
2) if any of the cells are equal to each other, write ".5(D+L)" as
opposed to ".5D + .5L"



All times are GMT +1. The time now is 04:31 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com