I published the code with Visual Studio 2010 and then deployed the pulished code on production server.
Everthing is working fine.
Suppose if I need to make some changes in code behind file (.cs file). Do I need to publish the code again and again from visual studio 2010?
Or Can I just need to replace the bin folder on production server?
Currenlty I publish the code each time I change the code in code behind file and replace the publish code on production server.
Your bin directory will contain your compiled code so if that’s all you change you can only deploy the bin folder.
But when you change other files, like your web.config, aspx, css or javascript files, those changes will not show up in your bin directory. Those physical files will need to be deployed.
Because deploying can be a tedious and repetitive process, it would be best to automate this. If you setup your webserver for WebDeploy, you can automatically deploy from Visual Studio to your server. WebDeploy will keep track of all changes and make sure they are deployed.