Announcement

Collapse
No announcement yet.

help needed with getText function

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • help needed with getText function

    Hello,

    I am having some trouble with using the GetText function in Streetdeck. I have a button that calls the getText function. When I enter text and click save, nothing happens. Here is my code.

    Code:
     public void module_OnGetText(string UserString, string InputString, bool Cancelled)
            {
                if (!Cancelled)
                {
    		        if (UserString == "savename")
                        {                    
                            module.MsgBox("Profile was saved!", "Save Profile");
                            module.GoBack();
                        }
    			    else
                        {
                            module.MsgBox("Profile was not saved!", "Save Profile");
                        }	
    	        }
             }
    Here is how I call the function

    Code:
     public bool module_OnExec(string Description, StreetDeck.enumExecMessage eEM, int wParam)
            {
                
    
                if (Description == "EquipmentScreen")
                {
                    if (eEM == StreetDeck.enumExecMessage.eEMSelect)
                    {
                        module.GetText("Save Equipment", "Enter Equipment Serial Number", "", "savename", StreetDeck.enumGetText.eGetTextNone);        
                        return true;
                    }
    
                }
    // Other code below...
    Obviously I am doing something wrong. Any ideas

    Thanks
    Ian

  • #2
    Fixed my own problem

    I figured out what was wrong. Forgot to create the event handler.

    module.OnGetText += new StreetDeck.IModuleEvents_OnGetTextEventHandler(mod ule_OnGetText);

    Comment

    Working...
    X