I created one software which written in c#.net and when i created setup file .exe file will be the output but in this .exe file is ex tractable by some software and easy to access the codes.How to prevent this?
No matter what you do, no matter what you use, somebody will be able to extract/infer the source code of your application from the binary. There's just no way around it. In the worst case they can run the application through a debugger and with assembly knowledge it could be possible to infer the source code.
Having that said, there are many good obfuscatory for .Net. They make it a bit more difficult to extract the source code from the binary. Here's a list of some of them on Wikipedia.
You could run your project through an obsfucator tool like Eazfuscator.NET.
This should make it a lot more difficult to recover the original source code given the .NET binary file. Of course, this is not 100% foolproof. With enough time and effort, an attacker would probably have a high chance of deobsfucating the binary file.