Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet_Change and Workbook_SheetChange not firing
Hi,
I have 2 workbooks, WB1 and WB2. WB1 contains a link to WB2, e.g., A1 on sheet1 in WB1 is linked to A1 on sheet1 in WB2. I would like to run some code when the cell WB1.A1 changes as a result of WB2.A1 changing, but neither of the events mentioned fire when A1 in WB2 changes, even tho the value in WB1 does change. VBA Help, under "SheetChange Event" says "Occurs when cells in any worksheet are changed by the user or by an external link." I would have thought this qualifies as "an external link", but maybe not? Anyway, if anyone can tell me how to make this work, I'd appreciate it. Thanks in advance David Jenkins |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet_Change and Workbook_SheetChange not firing
Hi
use the worksheet_calculate event in this case -- Regards Frank Kabel Frankfurt, Germany David Jenkins wrote: Hi, I have 2 workbooks, WB1 and WB2. WB1 contains a link to WB2, e.g., A1 on sheet1 in WB1 is linked to A1 on sheet1 in WB2. I would like to run some code when the cell WB1.A1 changes as a result of WB2.A1 changing, but neither of the events mentioned fire when A1 in WB2 changes, even tho the value in WB1 does change. VBA Help, under "SheetChange Event" says "Occurs when cells in any worksheet are changed by the user or by an external link." I would have thought this qualifies as "an external link", but maybe not? Anyway, if anyone can tell me how to make this work, I'd appreciate it. Thanks in advance David Jenkins |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet_Change and Workbook_SheetChange not firing
Hi,
Thank you, that does trap the event, but it doesn't provide a "Target" parameter as worksheet_change does, which as you know indicates the range that changed. I need to know which cell changed, because the code I want to kick off as a result should only be run if a particular cell has changed. Any ideas? David Jenkins -----Original Message----- Hi use the worksheet_calculate event in this case -- Regards Frank Kabel Frankfurt, Germany David Jenkins wrote: Hi, I have 2 workbooks, WB1 and WB2. WB1 contains a link to WB2, e.g., A1 on sheet1 in WB1 is linked to A1 on sheet1 in WB2. I would like to run some code when the cell WB1.A1 changes as a result of WB2.A1 changing, but neither of the events mentioned fire when A1 in WB2 changes, even tho the value in WB1 does change. VBA Help, under "SheetChange Event" says "Occurs when cells in any worksheet are changed by the user or by an external link." I would have thought this qualifies as "an external link", but maybe not? Anyway, if anyone can tell me how to make this work, I'd appreciate it. Thanks in advance David Jenkins . |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet_Change and Workbook_SheetChange not firing
Hi
then the only way is to store the old cell values somethee (e.g. static variables, hidden sheet, etc.9 and compare them after each calculate event -- Regards Frank Kabel Frankfurt, Germany David Jenkins wrote: Hi, Thank you, that does trap the event, but it doesn't provide a "Target" parameter as worksheet_change does, which as you know indicates the range that changed. I need to know which cell changed, because the code I want to kick off as a result should only be run if a particular cell has changed. Any ideas? David Jenkins -----Original Message----- Hi use the worksheet_calculate event in this case -- Regards Frank Kabel Frankfurt, Germany David Jenkins wrote: Hi, I have 2 workbooks, WB1 and WB2. WB1 contains a link to WB2, e.g., A1 on sheet1 in WB1 is linked to A1 on sheet1 in WB2. I would like to run some code when the cell WB1.A1 changes as a result of WB2.A1 changing, but neither of the events mentioned fire when A1 in WB2 changes, even tho the value in WB1 does change. VBA Help, under "SheetChange Event" says "Occurs when cells in any worksheet are changed by the user or by an external link." I would have thought this qualifies as "an external link", but maybe not? Anyway, if anyone can tell me how to make this work, I'd appreciate it. Thanks in advance David Jenkins . |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet_Change and Workbook_SheetChange not firing
Yep, that's what I was thinking. Thanks again.
David Jenkins -----Original Message----- Hi then the only way is to store the old cell values somethee (e.g. static variables, hidden sheet, etc.9 and compare them after each calculate event -- Regards Frank Kabel Frankfurt, Germany David Jenkins wrote: Hi, Thank you, that does trap the event, but it doesn't provide a "Target" parameter as worksheet_change does, which as you know indicates the range that changed. I need to know which cell changed, because the code I want to kick off as a result should only be run if a particular cell has changed. Any ideas? David Jenkins -----Original Message----- Hi use the worksheet_calculate event in this case -- Regards Frank Kabel Frankfurt, Germany David Jenkins wrote: Hi, I have 2 workbooks, WB1 and WB2. WB1 contains a link to WB2, e.g., A1 on sheet1 in WB1 is linked to A1 on sheet1 in WB2. I would like to run some code when the cell WB1.A1 changes as a result of WB2.A1 changing, but neither of the events mentioned fire when A1 in WB2 changes, even tho the value in WB1 does change. VBA Help, under "SheetChange Event" says "Occurs when cells in any worksheet are changed by the user or by an external link." I would have thought this qualifies as "an external link", but maybe not? Anyway, if anyone can tell me how to make this work, I'd appreciate it. Thanks in advance David Jenkins . . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Workbook_sheetChange event | Excel Programming | |||
workbook_sheetchange | Excel Programming | |||
Workbook_SheetChange will not fire | Excel Programming | |||
worksheet_change vs. calculate, and worksheet_change not running | Excel Programming | |||
worksheet_change vs. calculate, and worksheet_change not running | Excel Programming |