Five moves make applications more approachable

Source: Internet
Author: User

In Visual Studio, there are many ways to make applications more approachable. Here are five examples for your reference.

1. enable visual styles to make the application interface more beautiful.

In traditional applications, the button is usually a square or rectangle that is positive and looks very rigid. If you can change the button to a rounded rectangle, it looks much more comfortable. Another example is to move the mouse over a widget, such as a button, without any changes. If you can change the color when hovering the pointer over the control, it can clearly remind users and reflect it more intuitively. To achieve this effect, it may be difficult on other platforms, but it will become very simple on Visual Studio.

In fact, this credit is still due to the development of WindowsXP. In the XP operating system, a similar function has been implemented, introducing the appearance and behavior of the new Windows user interface. Only this implementation mechanism is introduced in Visual Studio. To enable the XP visual style feature, you can enable it as follows. Select a specific project in Solution Explorer, and then select Properties in the project menu. Click the Application tab and select the Enable XP visual style check box. If you do not need to enable the XP visual style, you only need to cancel this check box. By default, the system enables this function.

When setting this attribute, you need to pay attention to two items. First, not all platforms support this XP visual style. If it is used in Linux, it may not be supported. If you run an application on a platform that does not support XP themes, the appearance of the application will be restored to the traditional appearance and behavior. That is, the buttons and other controls are not displayed as rounded corners or the color is not changed. Second, this attribute is only applicable to applications under a project. If you want to enable visual styles for all applications on this platform, you must set them one by one. This means that the system allows different attribute values to be set for different projects or applications on the same platform. You can enable or disable the XP visual style as needed.

2. Enable Custom User authentication to improve user logon methods.

In a Windows application environment, you can use Windows authentication to identify the currently logged-on user. This recognition function is very important. Because many permissions are controlled based on this. However, there is not only one authentication method. In some cases, users may want to use other methods for identity authentication. For example, a webpage connects to various applications such as forums, mailboxes, and OA. Users prefer one-stop logon. That is, you only need to perform one authentication to use these applications at the same time. In this case, you can write your own code to perform user authentication, instead of using the Windows authentication method. To achieve this, you only need to change the Authentication Mode defined by the application.

To enable the custom authentication mode, follow these steps. Select a specific project in Solution Explorer, and click Properties in the project menu. Select the Application tab in the displayed dialog box, and select the Authentication Mode defined by the application from the Authentication Mode drop-down list. The user-defined authentication code is also provided. When using the custom authentication mode, you must note that the relevant code is compiled by the user, so strict tests are required. Generally, experienced programmers use the relevant code as a template. You can use it when you need to develop other applications. Because the user's authentication module is a relatively independent function. It has little to do with the application itself. Therefore, it can be used multiple times in other applications.

3. Add an appropriate icon for the application.

Each application has a corresponding icon. Good icons help you identify applications. Generally, the icons used must have a certain meaning. If you see the icon of the outlook application, you will know that it is an email-related application. On the Visual Studio platform, you can specify the required icons for the application as needed. To implement this function, you must use the icon attribute. The icon attribute of a project can specify the icon file displayed by the compiled application in the Windows resource manager or taskbar.

To specify a specific icon for an application, you can select a specific project in Solution Explorer. Select an application and select the icon file from the drop-down list. However, this property is different from the two attributes mentioned above. You can also set icons for the entire project. This is sometimes very convenient. This operation is similar to the above, so we will not repeat the description here.

The last thing to note is that the application icons should not be too big. If it is too large, it will affect the display speed and the application performance. In addition, you must first convert the icon file to an ico file using a graphic processing tool. This is a special icon file format.

4. Set an appropriate initial screen.

When starting an application, you often need an initial screen. In particular, some applications may use an independent authentication server to authenticate their identities. In this case, you need to use an initial screen for excessive authentication. You can send greetings to users based on their information. Some initial screens can also be used to set different greetings based on specific dates. For example, special greetings are given to users on their birthdays or holidays. Similar functions can be implemented on the Visual Studio platform. For example, a preset initial screen form template is provided in Visual Basic. You can add this template to an application project. Adjust relevant parameters as needed to implement different functions. The most common function is to display different greetings based on different logon user identities. To add an initial screen template, select a project in Solution Explorer and click Add new project in the project menu. In the Add new project dialog box, select the initial screen template and click Add. In this case, the template will be added to the project. Note that the more initial templates, the better. Some companies may use the same or similar initial screen for their own products to improve brand awareness. After all, the initial screen is also a good advertising platform that gives users a first impression. So the initial screen does not need to be very fancy, as long as it can reflect the connotation of the application.

5. Set the appropriate application closing behavior to facilitate user operations.

Sometimes users may open multiple windows, and these windows may have a causal relationship directly. In this case, what should be done if the user closes a window, such as the last window opened? This needs to be selected based on different application types. For example, in some applications, when closing a window, the user is reminded to close a window before closing the window or the entire application. Is the design reasonable? This should be handled according to different situations. For example, for an email client, open a writing window and then open the attachment window from this window. The two windows form a parent-child window relationship. In this case, if you need to close the writing window, you must first close the attachment window. It is reasonable to set up a designer. However, if it is a browser, click to open another webpage from a webpage. It is obviously troublesome to close the page in sequence according to the order in which the page is opened. Therefore, you still need to set the closing behavior of the application based on the actual situation. For example, you can set the attribute to when the startup form is closed. When the application's initial window is closed, if other windows are opened, other windows are closed automatically, and the entire application ends automatically.

To change this attribute, select "when the form is closed" or "when the last form is closed" in the shutdown mode drop-down list. You can select two different modes to try them. Select the operation method as needed.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.