How to automatically get the latest version of all the asp.net solution items from Source Safe when opening the solution?
In VS.NET you can go to Tools > Options > Source Control > General and check the checkbox for Get everything when a solution opens. This retrieves the latest version of all solution items when you open the solution.
Why do I get the error message ‘Object must implement IConvertible’. How can I resolve it
The common cause for this error is specifying a control as a SqlParameter’s Value instead of the control’s text value. For example, if you write code as below you’ll get the above error: VB.NET Dim nameParameter As SqlParameter = command.Parameters.Add(‘@name’, SqlDbType.NVarChar, 50) nameParameter.Value = txtName C# SqlParameter nameParameter = command.Parameters.Add(‘@name’, SqlDbType.NVarChar, 50); nameParameter.Value = txtName ; To resolve it, specify the control’s Text property instead of the control itself. VB.NET nameParameter.Value = txtName.Text C# nameParameter.Value =txtName.Text;
Why is default.aspx page not opened if i specify http://localhost. I am able to view this page if i hardcode it as http://localhost/default.aspx
If some other default page comes higher in the list, adjust the default.aspx to be the number one entry inside the IIS configuration. If you have multiple websites inside IIS, make sure the configuration is applied on the right website (or on all websites by applying the configuration on the server-level using the properties dialog, configure WWW service).
How to get the hostname or IP address of the server?
You can use either of these: HttpContext.Current.Server.MachineName HttpContext.Current.Request.ServerVariables[‘LOCAL_ADDR’] The first one should return the name of the machine, the second returns the local ip address. Note that name of the machine could be different than host, since your site could be using host headers
What is the meaning of validateRequest=true in .net framework1.1?
The value of validateRequest is set to ’true’ by default, which means that the framework will automatically deny submission of the ’<’ and ’>’ characters.