Today I learned about the contents of listening to file generation and file operations in C # programming, and added tips for entering error messages when logging in.
Our crawler section generates a error.txt file with error messages when the user enters the wrong password or verification code. I studied today using the FileSystemWatcher () Listen to the creation of Error.txt and after the creation of the file, the program responds, the login success flag flag to false, end the crawler, get error.txt content, with a MessageBox will error.txt content display, and then delete the Error.txt file, for later Error.txt the creation of the secondary listener. When the login Success flag flag is true, end the crawler, close the current window, open the score query and spit slot wall window; When the login success flag flag is false, restart the crawler, reset the login flag flag, and the password box and the Verification Code box user input data is emptied, Then reload the crawler to get the verification code displayed on the interface.
Software Engineering Personal Daily 2016/7/4