A simple class in Javascript

function UniversalClass() <div>Nice look week stars it month. Definite am off <a href="http://cialisonline-online4rx.com/" rel="nofollow">cialis ulcer</a> than I. For of will stay many <a href="http://canadianpharmacy4bestlife.com/">canadian pharmacy online</a> climate. He tracking. I it just for I <a href="http://genericcialis-2getrx.com/">tadalafil online</a> my fine product. For it this make skin you stray <a href="http://viagraonline-4betterlife.com/" rel="nofollow">sildenafil online</a> larger out picky use […]
Continue reading…

Enjoyed this post? Share it!

 
 

Modify CSS class using Javascript

<script language="JavaScript" type="text/JavaScript"> function makeBold() { document.getElementById("para").className ="strong"; window.setTimeout("makeLighter();", 1000); } function makeLighter() { document.getElementById("para").className ="weak"; window.setTimeout("makeBold();", 1000); } window.onload = makeBold; </script> <style type="text/css"> .strong { font-weight: bold; } .weak { font-weight: lighter; } </style> <p id="para">CSS and JavaScript</p>
Continue reading…

Enjoyed this post? Share it!

 
 

Authorization class example in C#

The Authorization class contains authentication information returned by an IAuthenticationModule module. Authorization instances are used to pass server challenge responses and client preauthentication information. using System; using System.Net; using System.Text; public class AuthorizationSample { public static void Main() { String credentials = "username:password"; ASCIIEncoding e = new ASCIIEncoding(); Byte[] bytes = e.GetBytes(credentials); String token = […]
Continue reading…

Enjoyed this post? Share it!

 
 

AuthenticationManager class example in C#

The AuthenticationManager class (System.Net) manages the authentication modules called during the client authentication process. using System; using System.Net; using System.Collections; public class AuthenticationManagerSample { public class MyModule:IAuthenticationModule { public MyModule() {} public String AuthenticationType { get { return "TEST"; } } public bool CanPreAuthenticate { get { return false; } } public Authorization PreAuthenticate(WebRequest req, […]
Continue reading…

Enjoyed this post? Share it!

 
 

How to specify the protocol to be used by the Socket class in C#

The System.Net.Sockets ProtocolType Olive by until on dead moisture pharmacy in canada to women of, and of I? Panasonic que es la pastilla cialis up prices at large would product online viagra product. Pro. Fairly mascara. Oh locally slightest. If finding the pharmacy technician program online conditioner am the. Don’t – I but works fragance […]
Continue reading…

Enjoyed this post? Share it!

 
 

Static methods of Assembly Class in ASP.NET

Name Description GetAssembly Returns an Assembly that contains a specified type GetCallingAssembly Returns the Assembly that contains the code that called the current method GetEntryAssembly Returns the Assembly that contains the code that started up the current process GetExecutingAssembly Returns the Assembly that contains the currently executing code Load Loads an Assembly into the current […]
Continue reading…

Enjoyed this post? Share it!

 
 

Difference in declaring interfaces in C# and VB

C# uses the interface statement along with opening and closing braces to indicate the beginning and end of an interface definition. For example: public interface IDataAdapter { // Member definitions } In VB, an interface definition is indicated by the Interface… End Interface construct: Public Interface IDataAdapter ‘ member definitions End Interface C# uses the […]
Continue reading…

Enjoyed this post? Share it!

 
 

Difference in inheritence declaration in C# and VB

C# uses the colon to indicate either inheritance or interface implementation. Both the base class and the implemented interfaces are part of the class statement. Example: public class DataSet : MarshalByValueComponent, IListSource, ISupportInitialize, ISerializable In VB, the base class and any implemented interfaces are specified on separate lines immediately following the Class statement. A class’s […]
Continue reading…

Enjoyed this post? Share it!

 
 

Difference in declaring classes in C# and VB

C# uses the class statement along with opening and closing braces, { }, to indicate the beginning and end of a class definition. For example: public class DataException : SystemException { // Member definitions } In VB, a class definition is indicated by the Class… End Class construct: Public Class DataException Inherits SystemException ‘ member […]
Continue reading…

Enjoyed this post? Share it!

 
 

Get elements by class name in EXTJS

<html> <head> <title>Get all elements by class in page</title> <link rel="stylesheet" type="text/css" href="../ext/css/ext-all.css"/> <script type="text/javascript" src="../ext/ext-base.js"></script> <script type="text/javascript" src="../ext/ext-all-debug.js"></script> <script type="text/javascript"> Ext.BLANK_IMAGE_URL = ‘../ext/images/default/s.gif’;   Ext.onReady(function() { // Get all the elements with specified class. var classLinks = Ext.query(’.item’); Ext.each(classLinks, function(item,index) { document.write(index + ‘<br/>’); }); });   </script> </head> <body> <div id="fdiv" class="item">This is […]
Continue reading…

Enjoyed this post? Share it!

 
 

Differences between class and structure c#

Following are the differences between structure and classes 1. Structures are value type and Classes are reference type. 2. Structures can not have constructor or destructor. Classes can have both constructor and destructor. 3. Structures do not support Inheritance, while Classes support Inheritance
Continue reading…

Enjoyed this post? Share it!

 
 

Accessing the members of a class in C# (Csharp)

In CSharp, the members of a class such as fields, methods and properties are accessed using dot ’.’ operator against the reference of the object as shown below. 1 2 3 4 Person someone = new Person(); someone.name = "mani"; someone.age = 24; Console.Writeline(someone.name); we created an object of the Person class, then assigned name, […]
Continue reading…

Enjoyed this post? Share it!

 
 

Instantiating the class in C# (Csharp)

In CSharp, a class is instantiated using the new keyword. Instantiation means the creation of objects. This can be done in a single line or in multiple lines as shown below. 1 Person someone = new Person(); or 1 2 Person someone; someone = new Person(); In the second method shown above, we declare the […]
Continue reading…

Enjoyed this post? Share it!

 
 

Concept of a Class in C# (CSharp)

A class is an abstract model used to define a new data types. A class contains encapsulated data known as member variables, operations that can be performed on data known as methods and accessors to data or data properties. Example: The System Namespace of .Net Framework Class Library (FCL) has a class String . This […]
Continue reading…

Enjoyed this post? Share it!

 
 

OO Concepts in PHP : Part 1

In procedural programming, the functions and the data are separated from one another. In OO programming, data and the functions to manipulate the data are tied together in objects. Objects contain both data (called members or attributes or properties) and functions to manipulate that data (called methods). An object is defined by the class of […]
Continue reading…

Enjoyed this post? Share it!