View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Karen53 Karen53 is offline
external usenet poster
 
Posts: 333
Default Worksheet Calculate

Hi,

Thank you both for responding.

The cell this is looking at is linked to another worksheet. When they enter
the value in that worksheet, this one updates which I thought would trigger
the worksheet calculate. Shouldn't this trigger it?

I was doing it this way because my boss does not want to see "Rental Tax" or
a 0 for the amount if the rental tax does not apply on this sheet.

You have given me some great information. I will try your suggestions
tomorrow morning at work.

Thanks!
--

Karen


"Karen53" wrote:

Hi,

I am trying to do a worksheet calculate. Initially, this would go into an
endless loop. I added the Application.EnableEvents = False and True but it
makes no changes. What do I need to do?

Private Sub Worksheet_Calculate()

On Error GoTo ws_exit
Application.EnableEvents = False

Select Case Range("H27")
Case Is 0
Me.Range("J29").Value = "Rental Tax"
Me.Range("K29").Value = "=R27,C12*R29,C11"
Case Is = 0
Me.Range("J29").Value = ""
Me.Range("K29").Value = ""
End Select

ws_exit:
Application.EnableEvents = True
End Sub

Also, my rental tax goes into a textbox as .024 for a value of 2.40% on the
main form. Then the link picks this up on another sheet and it becomes
240.00%. Is there a way to keep it from multiplying each time it's picked up?

Thanks
--

Karen