All time running macro

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there a way the user can input data into a spreadsheet and have a macro
running at the same time?

Like moving water or flying birds while they enter the data?

tim
 
If you want a macro to run every time the user enters anything or changes
anything on a particular spreadsheet, you can use the Change event of that
worksheet.

In VBA Editor, in projects, under your workbook, under Microsoft Excel
Objects, double-click that worksheet and enter the macro below.

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
MsgBox "worksheet changed"
End Sub


If you want a macro to run every time the user enters anything or changes
anything on ANY worksheet, you can use the SheetChange event of the
workbook.

In VBA Editor, in projects, under your workbook, under Microsoft Excel
Objects, double-click "ThisWorkbook" and enter the macro below.

Private Sub Workbook_SheetChange(ByVal Sh As Object, _
ByVal Target As Excel.Range)
MsgBox "one of the worksheets changed"
End Sub

Regards,
Edwin Tam
(e-mail address removed)
http://www.vonixx.com
 
Edwin,

This is very useful information you have forwarded to me...

I am just wondering, is it possible for a macro to be running at the same
time as a person is typing in data...not when they make a change to then have
the macro run...but have the macro always running and let the user imput or
whatever they want to do?

Does that help any?
 
Basically no, not simultaneously.

MrHappy said:
Edwin,

This is very useful information you have forwarded to me...

I am just wondering, is it possible for a macro to be running at the same
time as a person is typing in data...not when they make a change to then have
the macro run...but have the macro always running and let the user imput or
whatever they want to do?

Does that help any?
 
Yes, I agree with gocush. That could be not possible, as while the user is
typing into a cell, macros cannot be fired.
 
Boy...hummm...good answers all...thank you very much...

I can get it to work...it just pauses when they start typing
then when they stop it then continues like it never stopped...

I was just wondering if there was a way to keep it still ticking while
entering! I'm convinced now there is not.

Again, thank you all for your responses, they were most
helpful :)~

Tim
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top