In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
This article is about the sample analysis of attributes in the VB language. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
Attribute and other knowledge points are analyzed. The program interface of the case is shown in figure 1:
Figure 1
1. Knowledge supplement of print output function
The print function is mainly used to output text.
Use format:
Print space here is the content that needs to be output
Use case:
Print "output text here"
Note: we often output text in the form of a string, if it is in the form of a text string, then we must use double quotation marks to represent the text.
Second, the problem of interface control card in interface design
Question: some students find that there is a stutter in the control interface when using the VB6 development environment. How to solve the problem when dragging the control to compare the card?
The resolution steps are as follows:
1. Just right-click the VB icon on the desktop to select the properties.
two。 Click the compatibility tab.
3. Check "disable desktop elements" and "run this program as an administrator".
4. Finally, don't forget to make sure.
Third, change the color of the control
Question: how to change the background color of the control?
Use the code format:
Control name .BackColor = Color
The BackColor here means the background color.
The commonly used color defined keywords in VB are: yellow vbYellow, red vbRed, green vbGreen, blue vbBlue, black vbBlack, white vbWhite
Question: how to change the color of words in VB?
In fact, is to change the foreground color of this control.
Use the code format:
Control name .ForeColor = Color
The ForeColor here represents the foreground color.
The effect of the partially implemented program is shown in figure 2 below.
Figure 2
The code covered in this tutorial:
Private Sub Command1_Click () Label1.Caption = "singing" End Sub
Private Sub Command2_Click () Label1.BackColor = vbYellowEnd Sub
Private Sub Command3_Click () Label1.ForeColor = vbRedEnd Sub
Private Sub Label1_DblClick () Label1.Caption = "also like football" End Sub
Thank you for reading! This is the end of this article on "sample Analysis of attributes in VB language". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.