Home |
Search |
Today's Posts |
|
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Popup input-form on focus
Dear All,
How can i get a popup input-form when the cell has the focus or with a shotcut. I want to insert several lines of text in a small cel. The cell must stay small on the sheet because it is rarely used . Thanks, Filip |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Popup input-form on focus
Put this behind the sheet you wish to control. The cell actioned is set by
the the line "If Target.Column = 1 And Target.Row = 1 Then" change the values to suit your needs. Currently it is set to Cell A1. If you change the line to "If Target.Column = 1 Then" only then all cells in column 1 will trigger this action. Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Target.Column = 1 And Target.Row = 1 Then ActiveCell.Value = InputBox("Enter Text", "Small CellText Editor", ActiveCell.Value) End If End Sub -- Cheers Nigel "Filips Benoit" wrote in message ... Dear All, How can i get a popup input-form when the cell has the focus or with a shotcut. I want to insert several lines of text in a small cel. The cell must stay small on the sheet because it is rarely used . Thanks, Filip |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Popup input-form on focus
"Filips Benoit" wrote in message ... Dear All, How can i get a popup input-form when the cell has the focus or with a shotcut. I want to insert several lines of text in a small cel. The cell must stay small on the sheet because it is rarely used . Thanks, Filip ----------------------------------------- Filip, Go into the code for the sheet you want to edit (right click on the sheet from within the VBA editor). Then you can use something like this:- Private Sub Worksheet_Change(ByVal Target As Excel.Range) If Target.Address = "$C$1" Then Application.Run "Filter_Document" Else ' Range("F10").Value = False End If Application.EnableEvents = True End Sub For this example, when a change is recognised in cell C1 it runs the macro Filter_Document. With this you have to press enter for the macro to run. Some-one else may be able to tell you if there is a way to run a macro when you click on a cell. Regards Andi |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to use two parameters in input of popup Variables - Gary's Student | Excel Worksheet Functions | |||
Call popup box with pre-programmed input | Excel Worksheet Functions | |||
Popup Input Box | Excel Discussion (Misc queries) | |||
form popup | Excel Programming | |||
Form Popup | Excel Programming |