![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Apr 2002
Posts: 26
|
Hi!
I used a worksheet change and I get in the routine but Target.Column does not work. What do I use to address the cells? I want column E to be a formula : Column D * Column C. Private Sub Workbook_SheetChange(ByVal AssetInventory As Object, _ ByVal Source As Range |
|
|
|
|
|
#2 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: Auckland, New Zealand
Posts: 4,209
|
Quote:
Please explain further exactly what it is you want to happen via this event? |
|
|
|
|
|
|
#3 |
|
New Member
Join Date: Apr 2002
Posts: 26
|
Columns are:
Asset ID, Description, Unit Price, Quantity, Extended Price, and Location. Originally, I wanted Extended Price to be a formula Unit Price * Quantity, but I didn't want to fill in the formula, because the $0.00 was displayed. Now, I filled in the formula and hide the money by making the background and display color the same. Now, what I want to do is change the background when data is entered in the row. Private Sub Workbook_SheetChange(ByVal AssetInventory As Object, _ ByVal Source As Range) MsgBox "In Change ... " & ActiveCell.Rows.Address - This displays correct address $E$17 If ActiveCell.Rows.Address = "$E$" & Range("E" & Right(ActiveCell.Rows.Address, 2)) Then ------ this doesn't execute Module3.ShowExtPrice Else MsgBox "$E$" & Range("E" & Right(ActiveCell.Rows.Address, 2)) ---- This display $E$extended price money like $E$2200 for Unit Price of $1100 and Quantity of 2 End If End Sub ----- I prefer the formula be used in column E automatically. Any suggestions? |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|