View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default Double Click on a cell to fill data into a different cell.

You could do that with event code but there is another way without VBA.

Create a Data Validation List dropdown with your 3 or 4 choices.

In an adjacent cell, have a VLOOKUP formula that references a lookup table
on another sheet for that particular question with two columns......one for
choice and one for answer.

Example for a question in A1 on Sheet1..........................

On sheet2 have a table A1:B4 with column A being choices 1 through 4.

Column B being an answer for each of the choices in A

On sheet1 in B1 create the DV dropdown list.

In C1 enter this fromula =VLOOKUP(B1,Sheet2!$A$1:$B$4,2,FALSE)

When user picks an item from the dropdown, the corresponding answer will
show in C1

Set up each question in the same manner but with a lookup table unique to
that question and its choices.


Gord

On Wed, 10 Dec 2008 17:18:01 -0800, ctefft
wrote:

Thank you,
I am going to have a lot of questions in this and don't want people to have
to type out every answer. I was going to type out the question and then give
them 3 or 4 choices that they could just double click on. Then hopefully the
answer that they double clicked on would show up in a different cell to show
their answer.

"Gord Dibben" wrote:

If the user can d-click on an answer, then that answer must already be
there.

Why would you want it repeated?

I think your description needs refining, please post back.

But........yes, there is such an event as a double-click event that can
perform an action.


Gord Dibben MS Excel MVP


On Wed, 10 Dec 2008 13:39:03 -0800, ctefft
wrote:

I am setting up a questionnaire and I would like to set it up so that the
answer will fill in automatically after someone double clicks on the answer
that they want to use. Is there any way to set that up?