Beida Jade Bird: Five crossing Campus Instructor: Hara Ngoc Minh
Analysis of common difficulties
- The same form displays different interfaces
What if a different interface is displayed in a form??
We can switch the idea, the so-called interface is different container
Solution: Implement a multi-interface form by controlling the display and hiding of the ListView control in the form form
- Dynamic Picture Display
How do I dynamically display a picture on a form?
To animate an image control
Solution: By
Solve. To the actual development can be stitching out path.
- Play songs
How do I play a song?
Solution: You can use the Windows Media Player component
Explains how to add the component
Mp1. URL = "FileName";
- Upload image
Question: How to implement the image upload function, and display the picture preview effect, and display the file name and absolute path, and copy the file to the new disk directory
Solution:
- Form Data Association changes
Issue: How to display the newly added data in the main form after you close the Add form.
Solution: Set the static variable of the form type in the main form, and then call the main form's bound data source method in the Add button of the subform.
- Select File directory
How do I pop up the Select Catalog window and display the path to the corresponding text box?
Solution:
- How to play songs dynamically
Question: How to read the song storage path from the database, stitching the selected song name on the upper bound to play the corresponding song on the disk.
solution; You can use a static field in the class to save the path of the song that is read in the database so that the path can be used anywhere in the program.
How do I add a Windows Media Player control in the toolbox?
. The first column of the ListView control cannot be centered
We all know that the data in the first column of the ListView binding is passed
ListViewItem Lvitem = new ListViewItem (Stuno);
I also did not find the solution, can do, maybe the first column width is set to 0, not the first column, starting from the second column. At this time listview1.items[i]. The Text is also not available because it corresponds to listview1[i]. Subitems[0]. Text.
Sets the size of the ToolStrip counterpart picture, which is set by Imagescalingsize.
Panel cannot implement different interfaces for the same form.
Usage of the Directory.move method: moving file issues
Directory.move ("c:\\ms168\\filemanage\\dr\\", "c:\\ms168\\backup");
Specific implementation steps:
The effect is as follows:
To implement a playlist operation:
- Write Song class Song.cs
- Writing playlist classes, providing a variety of ways to play the list
- Design Pinyin Song Form
- Implement phonetic song function
Achieve the singer Song
Cut the song:
Ensemble:
KTV Song System