This class will allow you to create customized non-modal message boxes, you can change colors, fonts, add bitmaps to the background, use RichStrings, etc.
Requirements:
- B4A 2.xx
- RichString Lib
- StringUtils Lib
- Add the Class module "CustomMsgBox.bas" to your project
How to use:
Initialize the class like this for example:
	
	
	
	
	
	
	
		
			
			
			
			
			
		
	
	
	
		
	
	
		
	
Then, create your custom message box:
	
	
	
	
	
	
	
		
			
			
			
			
			
		
	
	
	
		
	
	
		
	
That's it!!.
All the available methods are self explanatory.
UPDATE: Added parameter to align the message
ShowMessage(BoxMessage As String, Alignment As String)
Updated to Version 1.0.4 on Feb 15, 2013.
The attached sample shows one of the many ways it can be used.
Screen shots:
	
	
	
		
		
		
			
		
		
	
	
		![6jJaIl.png]Shot 1](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2F6jJaIl.png%5DShot+1&hash=13ce24c28b5728861ca9dd36f17f100f) 
	
 
	
	
	
		
		
		
		
	
	
		![c0Odjl.png]Shot 2](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2Fc0Odjl.png%5DShot+2&hash=f0192678ce89882a98d836044429bd59) 
	
	
	
	
		
		
		
		
	
	
		![fdE9El.png]Shot3](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2FfdE9El.png%5DShot3&hash=204e4b13bd4bf8785585fbd6051d5fb1) 
	
 
	
	
	
		
		
		
		
	
	
		![9Xxwel.png]Shot 4](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2F9Xxwel.png%5DShot+4&hash=8f5dbd50c75420bcf95c7fc613d5d970) 
	
			
			Requirements:
- B4A 2.xx
- RichString Lib
- StringUtils Lib
- Add the Class module "CustomMsgBox.bas" to your project
How to use:
Initialize the class like this for example:
			
				B4X:
			
		
		
		Sub Globals
    Dim MyMsgBox As CustomMsgBox
End SubThen, create your custom message box:
			
				B4X:
			
		
		
		'With Icon
myMsgBox.Initialize(Activity, Me, "Default", "H", 1, 95%x, 200dip, LoadBitmap(File.DirAssets, "WarningIcon.png"))
'Without Icon
myMsgBox.Initialize(Activity, Me, "Default", "H", 1, 95%x, 200dip, Null)
'Then add text to the Title and Body of the custom msgbox
MyMsgBox.Title.Text = "Custom MsgBox v1.0"
MyMsgBox.ShowMessage("Simple box with 1 button, horizontal")
...
'This routine will get the button tapped, in this case "Default" 
'is the name of the message box, you can name yours with whatever name you like
Sub Default_Click
    Msgbox(myMsgBox.ButtonSelected, "Button Pressed")
            
End SubThat's it!!.
All the available methods are self explanatory.
UPDATE: Added parameter to align the message
ShowMessage(BoxMessage As String, Alignment As String)
Updated to Version 1.0.4 on Feb 15, 2013.
The attached sample shows one of the many ways it can be used.
Screen shots:
![6jJaIl.png]Shot 1](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2F6jJaIl.png%5DShot+1&hash=13ce24c28b5728861ca9dd36f17f100f) 
	![c0Odjl.png]Shot 2](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2Fc0Odjl.png%5DShot+2&hash=f0192678ce89882a98d836044429bd59) 
	![fdE9El.png]Shot3](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2FfdE9El.png%5DShot3&hash=204e4b13bd4bf8785585fbd6051d5fb1) 
	![9Xxwel.png]Shot 4](/android/forum/proxy.php?image=http%3A%2F%2Fi.imgur.com%2F9Xxwel.png%5DShot+4&hash=8f5dbd50c75420bcf95c7fc613d5d970) 
	Attachments
			
				Last edited: 
			
		
	
							 
				 
 
		 
 
		 
 
		 
 
		 
 
		 
 
		 
 
		 
 
		 
 
		 
 
		 
 
		