Share My Creation InputBox

Hi, I want to share with you a module for the use of the InputBox function. To use it just add it to the project and write in the code the following statement:

Private s as string
s=InputBox.Show(MainForm, "Hi how are you?", "My greeting", "Fine thanks")
Log(s)

upload_2017-4-1_7-51-13.png


I hope it is useful...
 

Attachments

  • InputBox.bas
    1.8 KB · Views: 418
Last edited:

ThRuST

Well-Known Member
Licensed User
Longtime User
Exactly what I need. However I am trying to make it compatible with my current mainform, so I wonder if you can make it compatible with a main form or tell me how to do that, since it interferes with the main one. Anyway it's really nice. Looking forward for an update :)
 

Diego Roman

Member
Licensed User
Exactly what I need. However I am trying to make it compatible with my current mainform, so I wonder if you can make it compatible with a main form or tell me how to do that, since it interferes with the main one. Anyway it's really nice. Looking forward for an update :)

Modeless Inputbox
Hi ThRuST, how are you? I have gladly to help you to modified the module so that it does not interfere with the main form. I have included an event that warns when the user has pressed the OK button. The module is well documented for better compression

InputBox.Show(MainForm,"Hi how are you?", "My greeting", "Fine thanks","Main","IB")

Private Sub IB_TextEntered(Text As Object)
fx.Msgbox(MainForm, Text, "¡The event has been executed!")
End Sub


I hope I've helped;)
 

Attachments

  • InputBox.bas
    2.1 KB · Views: 396
Last edited:

ThRuST

Well-Known Member
Licensed User
Longtime User
Hi Diego, I'm taking care of myself thank you :) I've implemented your updated version but my mainform still locks up when the inputbox appears.
This is my initial code to show my main form

B4X:
    MainForm = Form1
    MainForm.RootPane.LoadLayout("Form1") 'Load the layout file.
    MainForm.SetFormStyle("TRANSPARENT")
    MainForm.Icon = fx.LoadImage(File.DirAssets, "Mindcraft_logo80x80.png")
   
    'MainForm.WindowWidth = fx.PrimaryScreen.MaxX - fx.PrimaryScreen.MinX
       'MainForm.WindowLeft = fx.PrimaryScreen.MinX
    paneCODE.LoadLayout("1")
    'paneCODE.RootPane.LoadLayout("1") 'Load the layout file.
    'CodeArea1.Setup(MainPanel, paneCODE,0,0, 100,100)
    
    TableView.PrefWidth = 780
    MainForm.WindowHeight = fx.PrimaryScreen.MaxY - fx.PrimaryScreen.MinY
    SplitPane1.SetSize (800, fx.PrimaryScreen.MaxY - fx.PrimaryScreen.MinY - 50)
       MainForm.WindowTop = fx.PrimaryScreen.MinY
    MainForm.Show

I have created a settings form for my project so I might use that for many things. I was going to use your inputbox to allow the user to change the title for each contextmenu since they can be programmed with an associated document. I will leave your module as it is for now until someone find a solution for this and if you update it I will gladly try it because I really like your effort so far. If there's an alternative way for this let me know. Thanks
 

ThRuST

Well-Known Member
Licensed User
Longtime User
This is what Mindcraft v0.9.9g looks like :)

Mindcraftv099g_screenshot1.jpg


And with the contextmenu (programmable bank#1)

Mindcraftv099g_screenshot2.jpg


I think you'll get the idea what it's all about :rolleyes:
 
Top