Inside my local publish folder I have Global.asax
and Global.asax.cs
where Global.asax is not updated (dated one month ago) and Global.asax.cs is updated.
I check the "Build action" of the Global.asax
file which is set to "Content" and Copy always in the file properties.
How to update global.asax together with global.asax.cs on publish command?
Global.asax
doesn't usually change. Global.asax
is compiled into a class deriving from the Global
class in your Global.asax.cs
.
You don't have to do anything for that. The server's compiler will pick it up itself. You just need to copy the Global.asax
to your production server, where the Global.asax.cs
will be compiled into an assembly.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With