Get Cell Value while typing

  • Thread starter Thread starter LamNgo
  • Start date Start date
L

LamNgo

Hi groups,

I write a VC++ programme that hooks user actions on Esxcel
application. One user click on a cell, my programme must detect the
location and value of that cell. Everything is ok for mouse action.

For typing action, I want to get value of the editing cell just before
user press tab or enter. But what I receive is the value of cell
before user edit it.

Is there any solution for this problem?

Thanks,
LamNgo
 
Hi LamNgo

I don't believe, it's possible.
Excel's Change-event returns, what's in the
cell, *after* the user press tab or enter.

There's no key-down event, when it comes
to entering data in a cell.
 
Hi
If I understood you this is probably not possible. Maybe you could
explain what you're trying to achieve with this information. There may
be a workaround
 
Hi,

Thanks for your respones. I want to explain a litle more about my
problem so that you could help me more.

My programme hook into the system queue to capture user action. So that
the messages system send to Excel application will be examined by our
programme before Excel app receive them. Once I detect a WM_KEYDOWN with
wParam is VK_RETURN or VK_TAB, I would like to get the information in
the cell which is being edited by user. This mean the information will
be get before Excel receive the Tab key. I used GetActiveCell() method
and got it, but the value of cell is before user edit it, not at the
time user press TAB.

Thanks,
Lam
 
If you are capturing the keystrokes, you have what the user is entering.
 
In some case, the cell value is different from what you're typed in, for
example: autocomplete, fomular...
 

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