+ Reply to Thread
Results 1 to 5 of 5

Create button that toggles "show translation" of vocabulary words to the right of word?

  1. #1
    Registered User
    Join Date
    08-10-2014
    Location
    Lafayette, Louisiana
    MS-Off Ver
    office 2013
    Posts
    14

    Create button that toggles "show translation" of vocabulary words to the right of word?

    Simply, need to create a sheet with a list of language vocabulary words in one column, a toggle button in next right column that shows/hides translation in another language in third right column cell.

    For example:

    Before toggle button selected:


    Col 1 | Col 2 | Col 3

    Dog | show/hide translation | (blank)



    After button selected:


    Dog | show/hide translation | Cane



    How can I create a macro or something that does this for a list of 500 to 1000 or so words? The toggle translation button would be in a cell between the two words (the original and its translation).


    thanks for any assistance

  2. #2
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: Create button that toggles "show translation" of vocabulary words to the right of word

    Hello,

    I'm not sure that adding 500 buttons to a sheet is a good idea. You could set up a SelectionChange event that monitors if a cell is clicked. The visible words are in column A, the translations are in column B and formatted with custom format ";;;" - which will effectively hide them. With the macro below, you can click on the original word to show the translation in column B. Then click on the translation in column B to hide it again. If you click anywhere outside column A, all translations will be hidden.

    Please Login or Register  to view this content.
    See attached file for a working example.
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    08-10-2014
    Location
    Lafayette, Louisiana
    MS-Off Ver
    office 2013
    Posts
    14

    Re: Create button that toggles "show translation" of vocabulary words to the right of word

    Thanks Teylyn, this gives me something substantial to work with. It is a great elegant solution.

  4. #4
    Registered User
    Join Date
    08-10-2014
    Location
    Lafayette, Louisiana
    MS-Off Ver
    office 2013
    Posts
    14

    Re: Create button that toggles "show translation" of vocabulary words to the right of word

    Quote Originally Posted by teylyn View Post
    Hello,

    I'm not sure that adding 500 buttons to a sheet is a good idea. You could set up a SelectionChange event that monitors if a cell is clicked. The visible words are in column A, the translations are in column B and formatted with custom format ";;;" - which will effectively hide them. With the macro below, you can click on the original word to show the translation in column B. Then click on the translation in column B to hide it again. If you click anywhere outside column A, all translations will be hidden.

    Please Login or Register  to view this content.
    See attached file for a working example.
    Now I want to make it where it plays a sound file (translation) when clicking on original word. Any suggestions?

  5. #5
    Registered User
    Join Date
    05-06-2016
    Location
    Riobamba,Ecuador
    MS-Off Ver
    2013
    Posts
    8

    Re: Create button that toggles "show translation" of vocabulary words to the right of word

    Select References in Tools afrer


    Cells(2, 2).Select
    Application.Speech.Speak Selection

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 3
    Last Post: 01-02-2014, 02:15 PM
  2. "Fun times in no mans land" Translation - "Selective Duplication"
    By amonty87 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-09-2013, 03:21 AM
  3. If cell contains "word" then replace with "these words"
    By yellow281 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-21-2013, 07:19 PM
  4. Create a Command Button to "Save As" and "Close" an Excel Workbook
    By thedunna in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 05-26-2013, 05:38 PM
  5. [SOLVED] If a cell contains a "word" (within other words) then enter a "word"
    By jtmann in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-19-2013, 02:20 PM
  6. Application.ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",False)" not working
    By redders in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-31-2011, 03:52 PM
  7. Using "Find" to return results if a word is found within multiple words in a cell
    By pylauzier in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-01-2011, 01:37 PM
  8. Create a button to "show all" in Filter
    By The Salad in forum Excel General
    Replies: 1
    Last Post: 02-05-2008, 09:05 AM

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