ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Entering data while procedure is on (https://www.excelbanter.com/excel-programming/272575-entering-data-while-procedure.html)

Pierre Leclerc

Entering data while procedure is on
 
HI

Here is my problem

My procedure goes:
ActiveCell.Offset(3, 8).Select
and then I would like to be able to enter manually a value in the
activecell. Once the value is in, I would want the procedure to go on
ActiveCell.Offset(6, 3).Select
and so on and so on

The problem is being able to enter a value in the activecell between
each vba step.

How do I go about?

Thanks
Pierre Leclerc
http://www.excel-vba.com


Tom Ogilvy

Entering data while procedure is on
 
The is no pause and wait for the user to make an entry command.

You would need to select the cell, set the enter key to trigger a macro
(using OnKey) or OnEntry.

Almost any approach would be kludgy.

If you are trying to enforce a certain pattern of cell selection, you can
try unlocking just the cells you want to nagivate to, then protecting the
sheet and set the enableSelection property to xlunlockedcells

Almost any solution would be dependent on exactly what you want to do.

Regards,
Tom Ogilvy

"Pierre Leclerc" wrote in message
...
HI

Here is my problem

My procedure goes:
ActiveCell.Offset(3, 8).Select
and then I would like to be able to enter manually a value in the
activecell. Once the value is in, I would want the procedure to go on
ActiveCell.Offset(6, 3).Select
and so on and so on

The problem is being able to enter a value in the activecell between
each vba step.

How do I go about?

Thanks
Pierre Leclerc
http://www.excel-vba.com




Gord Dibben[_3_]

Entering data while procedure is on
 
Pierre

I'm sure there are more elegant ways but here is one kludge.

Public Sub movearound()
ActiveCell.Offset(3, 8).Select
Selection.Value = InputBox("enter data")
ActiveCell.Offset(6, 3).Select
Selection.Value = InputBox("enter data")
End Sub

Gord Dibben Excel MVP - XL97 SR2 & XL2002

On Thu, 24 Jul 2003 13:32:15 -0400, Pierre Leclerc
wrote:

HI

Here is my problem

My procedure goes:
ActiveCell.Offset(3, 8).Select
and then I would like to be able to enter manually a value in the
activecell. Once the value is in, I would want the procedure to go on
ActiveCell.Offset(6, 3).Select
and so on and so on

The problem is being able to enter a value in the activecell between
each vba step.

How do I go about?

Thanks
Pierre Leclerc
http://www.excel-vba.com




All times are GMT +1. The time now is 12:18 AM.

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