Professional Documents
Culture Documents
Answer
Common Type System CTS :A fundamental part of the .NET Framework's Common Language
Runtime (CLR), the CTS specifies no particular syntax or keywords, but instead defines a
common set of types that can be used with many different language syntaxes.
Common Language Specification (CLS):The Common Language Specification (CLS)
describes a set of features that different languages have in common.
The CLS includes a subset of the Common Type System (CTS).
CLR : this is common language runtime.the code which is in environment of clr is called managed
code.every language has runtime in case of .net there is CLR.so that that has some
responsibilites that is to tack care of the execution of codeother responsibilites garbage
collection-in that it remove the object which are not refered for long time.using Idisposable
interface with dispose method
How do you set language in web.cofig ? Answer
To set the UI culture and culture for all pages, add aglobalization section to the Web.config file,
and then setthe uiculture and culture attributes, as shown in the
following example:
<globalization uiculture="es" culture="es-MX" />
To set the UI culture and culture for an individual page,set the Culture and UICulture attributes of
the @ Page directive, as shown in the following example:
<%@ Page UICulture="es" Culture="es-MX" %>
In web.congig you can add key and its value.And that key value u can retrive like
string connectionString = System.Configuration.ConfigurationSettings.AppSettings
["conStringWeb"].ToString()
Here conStringWeb is my key and i access its value.
In a page u have Web user controls . So what is the order in which the Page life Cycles
takes place? Answer
order of events are Init, page load, control load, page unload
How to write unmanaged code and how to identify whether the code is managed /
unmanaged ? Answer
you can only write unmanaged code in c# not in vb.net you can only call unmanaged code in
vb.net. calling and writing unmanaged code are different things.
To identify whether the code is managed or not open the file in ildasm in VS.Net Command
prompt.Also you can use a .Net tool called dumpbin, which can be
used to check the headers.
or open the dll in notepad and check for "V e r s i o n".
If you find that, it is managed assembly.
How Web Services help Us? What r the difference between Remoting and webservices
Web services are those services delivered via web and assume that ur project comprising of
timezone of u.s you need not write a code for that just call in the web method
you need for that time
Difference:-The ultimate difference between these two is When u have both client and server @
your end you can use webservices and when u have either the client or the server @ your end it
will be awesome if you opt Remoting
In remoting objects communicates thru homogineous protocols i.e.,TCP.Where as Webservices
provides funtionality thru hetrogenious protocals i.e., HTTP,SOAP.
In remoting data is passed as streams whereas webservices communicates in XML Format
If we add a textbox and give the required field validator,and i add two radio buttons 1 is
yes another one is No.And i add another one server control button ,if i click the button ,if
the radio button Yes is checked the validation control is fired ,if no the validation control is
not fired.So what you used to solve this problem. Answer
We can add the code in page_load
If Me.RadioButton1.Checked = True Then
Button1.CausesValidation = True
Else
If Me.RadioButton2.Checked = True Then
Me.Button1.CausesValidation = False
End If
End If
One Listbox showing all cities. If you select one city in list box the information related to
that particular city should be displayed in Datagrid . How do you do that? Answer
protected void ddlcity_SelectedIndexChanged(object sender,
EventArgs e)
{
sqlConnection con= new sqlConnection(" ");
string str="select * from table where city ='" +
ddlcity.SelectItem.Text ="'";
sqlDataAdapter da= new slqDataAdapter(str,con)
dataset ds = new dataset;
da.fill(ds,"City");
dgview.datasource=ds.tables["City"];
dgview.dataBind();
}
}
catch
{ }}}
Dategrid filtering and sorting How can we sort all the fields at once? Answer
Undoubtedly u need to write a sql query for this with the order by (or) sort by.
And also call the subroutine that fills the datagrid after each insert or delete so that u can see the
changes at the runtime with the new alignment(i mean sorting)...