Working with Microsoft Windows: open a dialog box: : Win32API « Windows Platform « Ruby






Working with Microsoft Windows: open a dialog box:

require 'Win32API'

title = "My Application"
text = "Hello, world!"

Win32API.new('user32', 'MessageBox', %w{L P P L}, 'I').call(0, text, title, 0)

 








Related examples in the same category

1.Use Win32API to get a pointer a function
2.Read from keyboard
3.Open a dialog and check the result
4.Get cursor position with Win32API