ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Sheet Update Problem (https://www.excelbanter.com/excel-programming/278777-sheet-update-problem.html)

Gary Desroches[_2_]

Sheet Update Problem
 
I have a LARGE excel file with more than 100 active cells,
buttons, conditional formating etc.
These cells receive information through RSLinx from
various PLC modules in our facility.

My Problem:
a few of these cells need to be used as "triggers"
When the value changes I want to open a msgbox alerting
the user of a change on that sheet or another sheet not
currently visible. Currently I can only get this to work
if the cell value changes due to direct user input from
the keyboard.
If a formula updates say from 0 to 1 the cell "value" is
still the formula typed into the cell, so the function:

Private Sub Worksheet_Change(ByVal Target As Range)
' do something
End Sub

does not fire. Likewise the function:

Private Sub Workbook_SheetCalculate(ByVal Sh As Object)
' do something
End Sub

does not fire. (These are built in excel functions I
found in the help files.)
Am I trying to to do something that is not possible, or
just doing it wrong? If wrong, can someone show me how to
do it right?

Thanks in advance

Gary


Tom Ogilvy

Sheet Update Problem
 
What version of Excel are you using?

Look at the calculate event. You might need to store the value of the
cell(s) and compare to find if there was a change. It doesn't fire for a
specific cell like change or identify what cell changed

--
Regards,
Tom Ogilvy

Gary Desroches wrote in message
...
I have a LARGE excel file with more than 100 active cells,
buttons, conditional formating etc.
These cells receive information through RSLinx from
various PLC modules in our facility.

My Problem:
a few of these cells need to be used as "triggers"
When the value changes I want to open a msgbox alerting
the user of a change on that sheet or another sheet not
currently visible. Currently I can only get this to work
if the cell value changes due to direct user input from
the keyboard.
If a formula updates say from 0 to 1 the cell "value" is
still the formula typed into the cell, so the function:

Private Sub Worksheet_Change(ByVal Target As Range)
' do something
End Sub

does not fire. Likewise the function:

Private Sub Workbook_SheetCalculate(ByVal Sh As Object)
' do something
End Sub

does not fire. (These are built in excel functions I
found in the help files.)
Am I trying to to do something that is not possible, or
just doing it wrong? If wrong, can someone show me how to
do it right?

Thanks in advance

Gary





All times are GMT +1. The time now is 01:29 PM.

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