+ Reply to Thread
Results 1 to 5 of 5

Creating input messages or comments

  1. #1
    Louise
    Guest

    Creating input messages or comments

    Hi all

    I have a large worksheet and one column contains a code consisting of two
    letters. The two letters represent the name of a particular division
    Division. For example, FG would mean 'Food Group', HR would mean
    'Healthcare'.

    As there are too many for me to remember what they all mean, is there a way
    I can click onto a cell and Excel gives me an 'input message' style box,
    telling me what the code stands for?

    I have tried to use Data Validation but can't get that to work as it shows
    the same input message regardless of what cell I am on.

    By the way, the worksheet is sorted in numerical order by another column so
    I can't sort it by the Code and then apply separate input messages.

    Does anybody have any other ideas???

    Thank you.

    Louise

  2. #2
    Guest

    Re: Creating input messages or comments

    Hi

    You need to use Data Validation on each cell, separately. If you do this,
    you can have different 'input messages' for each one.

    Andy.

    "Louise" <[email protected]> wrote in message
    news:[email protected]...
    > Hi all
    >
    > I have a large worksheet and one column contains a code consisting of two
    > letters. The two letters represent the name of a particular division
    > Division. For example, FG would mean 'Food Group', HR would mean
    > 'Healthcare'.
    >
    > As there are too many for me to remember what they all mean, is there a
    > way
    > I can click onto a cell and Excel gives me an 'input message' style box,
    > telling me what the code stands for?
    >
    > I have tried to use Data Validation but can't get that to work as it shows
    > the same input message regardless of what cell I am on.
    >
    > By the way, the worksheet is sorted in numerical order by another column
    > so
    > I can't sort it by the Code and then apply separate input messages.
    >
    > Does anybody have any other ideas???
    >
    > Thank you.
    >
    > Louise




  3. #3
    Louise
    Guest

    Re: Creating input messages or comments

    Isn't there a quicker way of doing this rather than each cell individually?
    There are hundreds of them.

    Thanks.

    "Andy" wrote:

    > Hi
    >
    > You need to use Data Validation on each cell, separately. If you do this,
    > you can have different 'input messages' for each one.
    >
    > Andy.
    >
    > "Louise" <[email protected]> wrote in message
    > news:[email protected]...
    > > Hi all
    > >
    > > I have a large worksheet and one column contains a code consisting of two
    > > letters. The two letters represent the name of a particular division
    > > Division. For example, FG would mean 'Food Group', HR would mean
    > > 'Healthcare'.
    > >
    > > As there are too many for me to remember what they all mean, is there a
    > > way
    > > I can click onto a cell and Excel gives me an 'input message' style box,
    > > telling me what the code stands for?
    > >
    > > I have tried to use Data Validation but can't get that to work as it shows
    > > the same input message regardless of what cell I am on.
    > >
    > > By the way, the worksheet is sorted in numerical order by another column
    > > so
    > > I can't sort it by the Code and then apply separate input messages.
    > >
    > > Does anybody have any other ideas???
    > >
    > > Thank you.
    > >
    > > Louise

    >
    >
    >


  4. #4
    Guest

    Re: Creating input messages or comments

    Louise

    There are many other ways of helping you with this. You could keep a list of
    the initials - along with their meanings - on a separate sheet. Using a
    VLOOKUP formula and an input cell, you could pull back the information you
    need. It depends on the layout of your sheets and the data itself, really.

    Andy.

    "Louise" <[email protected]> wrote in message
    news:[email protected]...
    > Isn't there a quicker way of doing this rather than each cell
    > individually?
    > There are hundreds of them.
    >
    > Thanks.
    >
    > "Andy" wrote:
    >
    >> Hi
    >>
    >> You need to use Data Validation on each cell, separately. If you do this,
    >> you can have different 'input messages' for each one.
    >>
    >> Andy.
    >>
    >> "Louise" <[email protected]> wrote in message
    >> news:[email protected]...
    >> > Hi all
    >> >
    >> > I have a large worksheet and one column contains a code consisting of
    >> > two
    >> > letters. The two letters represent the name of a particular division
    >> > Division. For example, FG would mean 'Food Group', HR would mean
    >> > 'Healthcare'.
    >> >
    >> > As there are too many for me to remember what they all mean, is there a
    >> > way
    >> > I can click onto a cell and Excel gives me an 'input message' style
    >> > box,
    >> > telling me what the code stands for?
    >> >
    >> > I have tried to use Data Validation but can't get that to work as it
    >> > shows
    >> > the same input message regardless of what cell I am on.
    >> >
    >> > By the way, the worksheet is sorted in numerical order by another
    >> > column
    >> > so
    >> > I can't sort it by the Code and then apply separate input messages.
    >> >
    >> > Does anybody have any other ideas???
    >> >
    >> > Thank you.
    >> >
    >> > Louise

    >>
    >>
    >>




  5. #5
    vezerid
    Guest

    Re: Creating input messages or comments

    Louise,
    I have prepared a VBA event macro, which can be fired whenever you
    select a cell in a specific column.
    It presupposes that you have somewhere in your workbook a table with
    two columns, one with the 2-letter codes and one with the full names.
    To install it you need to copy the following VBA code, after you make
    the necessary changes. The right click the sheet tab, choose View
    Code... and, once the VBA module comes up, paste the modified code.

    It is not perfect, but it might be close to what you need. Whenever the
    user clicks on a cell in the specific column, a comment comes up with
    the full name. When you click elsewhere the old comment is removed and
    the new one appears.
    --------cut below---------
    Dim oldCell As Range

    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    Dim MyColumn As Integer
    Dim cell As Range
    Dim CodesTable As Range

    Set CodesTable = Sheets("Sheet1").Range("A1:C100")

    If Not oldCell Is Nothing Then oldCell.ClearComments
    Set oldCell = Target.Cells(1, 1)

    MyColumn = 3

    Set cell = Target.Cells(1, 1)
    If cell.Column = MyColumn And Len(cell.Value) <> 0 Then
    cell.ClearComments
    cmttext = Application.WorksheetFunction.VLookup(cell.Value,
    CodesTable, 2, 0)
    cell.AddComment Text:=cmttext
    cell.Comment.Visible = False
    End If

    End Sub
    -------------End cut ---------------

    What you need to change:
    MyColumn = 3 --> change it to the number of the column where the
    2-letter codes appear.
    Set CodesTable = Sheets("Sheet1").Range("A1:B10") --> change the
    sheetname and the range with your table.
    Let us know if it works.

    HTH
    Kostis Vezerides


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1