locked
DropUp Menue for Buttons RRS feed

  • Question

  • Hello,

    I'm working on a HTML-Client Lightswitch project with VS 2013 and have a question.

    I am new in programming and designing and have no idea how to solve it.

    I have created some tables and screens and add commands in the command bar, but when I saw the result in browser I was wondering if it is possible to create a DropUp Menue where all the commands are inside, so that you have one button which show me the other commands.

    I have one button to add a record, one to delete it, one to search through my records and one to edit my records.If it is possible, I want one button "Options" which give me the possibility to choose between the other commands.

    I hope you understand me and can help me out.

    Regards,

    AHleonIT

    Tuesday, September 27, 2016 3:04 PM

Answers

  • You should be able to create a Popup and put all the buttons you need inside that popup and then call that popup from a single button on the command bar. Search for LightSwitch HTML Popups for more information on how to create those.

    Regards, Xander. My Blog

    • Marked as answer by AHleonIT Friday, September 30, 2016 8:05 AM
    Wednesday, September 28, 2016 7:15 PM

All replies

  • You should be able to create a Popup and put all the buttons you need inside that popup and then call that popup from a single button on the command bar. Search for LightSwitch HTML Popups for more information on how to create those.

    Regards, Xander. My Blog

    • Marked as answer by AHleonIT Friday, September 30, 2016 8:05 AM
    Wednesday, September 28, 2016 7:15 PM
  • Hi Xander,

    thanks for your reply.

    I use functions where I for example change the visibility of a command. Can you tell me how to change my code if i transfer my commands in a Popup, like you recommend to me?

    I get this error message: "TypeError: screen.findContentItem(...) is undefinend"

    Here is  an example:

    myapp.BrowseMitarbeiter.created = function (screen) {
        screen.findContentItem('Löschen').isVisible = false;
    };

    Regards,

    AHleonIT

    Thursday, September 29, 2016 10:01 AM
  • I have command buttons inside of popups and have no trouble finding them using screen.findContentItem('yourButtonName'); in the screen.created method.  Are you sure that the string name is the actual name of the contentItem vs. the displayName or a typo?
    Thursday, September 29, 2016 2:46 PM