Difference between C# var and Javascript var
C#
var i = 10; // implicitly typed
int i = 10; //explicitly typed
//Initialization is mandatory
var a = 10;
//Allowed
a = 13;
//Not Allowed
a = "string";
By using above example we can say C# var is strongly typed, but inferred from whatever the value is being assigned.
Javascript
<script type="text/javascript">
var a = "stringValue";
a = 567;
a= "2ndString"; // allowed
</script>
Solution for the QlikView, Biztalk, DotNet and MSBI real time development problems
Search This Blog
Wednesday, November 9, 2011
Subscribe to:
Post Comments (Atom)
Popular Posts
-
Migration from Visual Studio 2008 to 2013 Without any code changes I successfully migrated from VS 2008 to 2013 but when running website f...
-
I am getting below error while executing stored procedure from C# (Ado.net, entity framework) String[2]: the Size property has an invalid ...
-
Exception : Microsoft.WindowsAzure.StorageClient.StorageClientException was unhandled Message=One of the request inputs is out of ran...
-
as is Is Operator is used to check the Compatibility of an Object with a given Type and it returns the result as a Boolean (True or ...
-
Review the permissions of the user that you're trying to impersonate. In my situation, I was only getting the error on my development ...
No comments:
Post a Comment