When you have properties like OrderID (with ID uppercase) FxCop treats it as naming rules' violation. I've been asked how to remove this error without manually excluding each occurrence.
Here is what FxCop stated:
"Resolution : "Correct the casing of 'ID' in member name 'Order.OrderID'
by changing it to 'Id'. 'Id' is an abbreviation and
therefore is not subject to acronym casing guidelines."
Help : http://msdn2.microsoft.com/library/ms182240(VS.90).aspx (String)
"
After looking into FxCop naming rules' details (using Reflector) I've found that "ID" is a hardcoded case (along with "Ok") and the only way to override is to add "ID" to casing exception in CustomDictionary.xml as:
<Acronyms>
<CasingExceptions>
<Acronym>ID</Acronym>
</CasingExceptions>
</Acronyms>
Thursday, April 23, 2009
Thursday, March 5, 2009
What is the best duration for a web session?
I think that the best definition is:
"A user should be able to get some coffee, smoke a cigarette and after return should find his web application still running".
Thanks to Siarhei Helis for the quote
"A user should be able to get some coffee, smoke a cigarette and after return should find his web application still running".
Thanks to Siarhei Helis for the quote
Wednesday, November 12, 2008
Simple script for backup
I understood some time ago that I often do the same operation:
- get come folder
- make a folders like "1","2","3" and put backup versions of the working folder there.
This habit saved me a lot of time by not letting intermediate results gone by mistake. However, the actions so routine that I decided to create a script that can be run from using the shortcut in the quick launch bar. After a few iterations I've got the following.
SET SOURCE_DIR="D:\tests\ReportBrowser\"
SET APP_NAME=ReportBrowser
SET ARCHIVE_PATH=D:\Archive\
@ECHO ON
FOR /L %%X IN (300,-1,1) DO IF NOT EXIST %ARCHIVE_PATH%%APP_NAME%\%%X SET PATH_DIR=%ARCHIVE_PATH%%APP_NAME%\%%X
MKDIR %PATH_DIR%\
XCOPY %SOURCE_DIR%*.* %PATH_DIR%\ /i /f /r /k /y /s
Now, if I need a new folder to backup, I create a copy of that script, then change 2 first variables(SOURCE_DIR and APP_NAME) and I have it working. The script copies the whole content to folder (1,2,3) in D:\Archive\ReportBrowser (in case if variables are the same as in the sample). Thus by I a single click I save the folder I need and have all previous backups to rollback in case I need it
- get come folder
- make a folders like "1","2","3" and put backup versions of the working folder there.
This habit saved me a lot of time by not letting intermediate results gone by mistake. However, the actions so routine that I decided to create a script that can be run from using the shortcut in the quick launch bar. After a few iterations I've got the following.
SET SOURCE_DIR="D:\tests\ReportBrowser\"
SET APP_NAME=ReportBrowser
SET ARCHIVE_PATH=D:\Archive\
@ECHO ON
FOR /L %%X IN (300,-1,1) DO IF NOT EXIST %ARCHIVE_PATH%%APP_NAME%\%%X SET PATH_DIR=%ARCHIVE_PATH%%APP_NAME%\%%X
MKDIR %PATH_DIR%\
XCOPY %SOURCE_DIR%*.* %PATH_DIR%\ /i /f /r /k /y /s
Now, if I need a new folder to backup, I create a copy of that script, then change 2 first variables(SOURCE_DIR and APP_NAME) and I have it working. The script copies the whole content to folder (1,2,3) in D:\Archive\ReportBrowser (in case if variables are the same as in the sample). Thus by I a single click I save the folder I need and have all previous backups to rollback in case I need it
Tuesday, October 28, 2008
Testablity
I've got a link to a pretty article regarding testability.
http://www.testabilityexplorer.org/report
It's common issue that the application is almost impossible to test by unit tests due bad design and tangled references. May be later I'll find out how to make it integrated into Continuous Integration.
http://www.testabilityexplorer.org/report
It's common issue that the application is almost impossible to test by unit tests due bad design and tangled references. May be later I'll find out how to make it integrated into Continuous Integration.
Saturday, October 25, 2008
Separate my thoughts between work and hobby
I have another blog that has mixed content on two topics:
- work, and skills
- my hobbies.
After some time I decided that it will be more clear for me and everyone else if the first topic go to another blog, which is the current one. The hobby part still stays here: http://dima-ch.blogspot.com/
I am going to publish some VB scripts to work with Outlook in more convenient fashion (and those I am using) next week.
Those are:
- sending e-mail to any department (based on organization tab in the Exchange profile)
- convert all e-mail addresses that are in To or CC fields in a letter, and composing a list of SMTP addresses separated by semi column .
- Thank you letter :)
- work, and skills
- my hobbies.
After some time I decided that it will be more clear for me and everyone else if the first topic go to another blog, which is the current one. The hobby part still stays here: http://dima-ch.blogspot.com/
I am going to publish some VB scripts to work with Outlook in more convenient fashion (and those I am using) next week.
Those are:
- sending e-mail to any department (based on organization tab in the Exchange profile)
- convert all e-mail addresses that are in To or CC fields in a letter, and composing a list of SMTP addresses separated by semi column .
- Thank you letter :)
Subscribe to:
Posts (Atom)