Thursday October 8th

Wednesday October 7th

Quick Tip: Use System.IO.Path.Combine instead of string concatenation

System.IO.Path has a number of utility methods that are useful when you have to progamatically build a file path ...


Yep, System.IO.Path is the way to go. I see application errors just waiting to happen whenever I see paths being built in our applications without using the Combine() method.

Just make sure you watch out for absolute paths in the second argument. I have seen security holes caused by people trying to use Path.Combine to keep users within a specific directory.!410AE16A9B73776E!164.entry

Commenting on Stories is limited for now and will open up to those recommended by the community. Learn how
Loading DotNetKicks...
brought to you by the Kicks Network