Library code snippets
VB.NET Stylise Your Forms like you would with CSS on a webpage
Code
Sub Stylize(frm As Form)
Dim Con As Control
For i = 0 To frm.Controls.Count - 1
Con = frm.Controls(i)
If TypeOf Con Is TextBox Then Con.ForeColor = Color.Red
If TypeOf Con Is Button Then Con.FlatStyle = FlatStyle.Flat
Next
End Sub
This is just an example, setting textbox's forecolor to Red, and buttons style to Flat.
Related articles
Related discussion
-
String size limit and array upperbound limit
by Akhtar Hussain (2 replies)
-
DataGridViewComboBoxColumn events
by bogdan (0 replies)
-
hi... need help...........
by gangireddysaritha (0 replies)
-
Header and Footer in Web page print
by fhajaj (4 replies)
-
Big deal here! Please don't jump, line yourself and check it
by konikula (2 replies)
Related podcasts
-
Episode 3: Anne van Kesteren on CSS, XHR, and other Web standards
Anne van Kesteren is an Opera Software employee who is deeply involved in the standards community. Just take a look at his page on the WHATWG site and you will see the many specifications that he is actively working on, such as: access-control XMLHttpRequest XMLHttpRequest2 cssom-view css3-media...
Events coming up
-
Dec
6
Developing AJAX Web Applications with Castle Monorail
London, United Kingdom
Monorail is the model-view-controller engine of the Castle Project, bringing many of the best ideas of Ruby on Rails to the .NET world. In this talk, David De Florinier and Gojko Adzic show how Monorail makes it easy to develop .NET based AJAX applications, and how to use the Castle Project to build Web 2.0 applications effectively. Come to this session if you are a .NET web developer. Everyone is welcome!
So, how to do that with a dialog box?
This thread is for discussions of VB.NET Stylise Your Forms like you would with CSS on a webpage.