Tuesday, February 8, 2011

.Net Interview Question - 2


    1. What is garbage collection?
      Garbage collection is a CLR feature which automatically manages memory.
      CLR automatically releases objects when they are no longer in use and referenced. CLR runs on non-deterministic to see the unused objects and cleans them. One side effect of this non-deterministic feature is that we cannot assume an object is destroyed when it goes out of the scope of a function. We should avoid using destructors because before GC destroys the object it first executes destructor in that case it will have to wait for code to release the umanaged resource. resulting in additional delays in GC. So its recommended to implement IDisposable interface and write cleaup code in Dispose method and call GC.SuppressFinalize method so instructing GC not to call your constructor.
      Assemblies which are critical to your application’s start up time should either be precompiled synchronously or asynchronously with priority 1. Priority 1 and 2 assemblies are precompiled aggressively while Priority 3 assemblies are only precompiled during machine idle-time. Synchronously precompiling your critical assemblies guarantees that the native images will be available prior to the first time your end user launches the application but increases the time taken to run your application’s set up program.
      You can uninstall an assembly and its dependencies (if no other assemblies are dependent on them) from the native image cache by running the following command.
      ngen.exe uninstall
      Native images created using Ngen.exe cannot be deployed; instead they need to be created on the end user’s machine. These commands therefore need to be issued as part of the application’s setup program. Visual Studio .NET can be used to implement this behavior by defining custom actions in a Microsoft Installer (MSI) package.
    2. Can we force garbage collector to run ?
      System.GC.Collect()forces garbage collector to run. This is not recommended but can be used if situations arises.
    3. What is reflection?
      All .NET assemblies have metadata information stored about the types defined in modules. This metadata information can be accessed by mechanism called as “Reflection”. Reflection can be used to browse through the metadata information.
      Using reflection you can also dynamically invoke methods usingSystem.Type.Invokemember.
    4. What are different types of JIT?
      JIT compiler is a part of the runtime execution environment. In Microsoft .NET there are three types of JIT compilers:
      • Pre -JIT: Pre-JIT compiles complete source code into native code in a single compilation cycle. This is done at the time of deployment of the application.
      • Econo -JIT : Econo-JIT compiles only those methods that are called at runtime. However, these compiled methods are removed when they are not required.
      • Normal -JIT : Normal-JIT compiles only those methods that are called at runtime. These methods are compiled the first time they are called, and then they are stored in cache. When the same methods are called again, the compiled code from cache is used for execution.
    5. What are Value types and Reference types?
      Value types directly contain their data which are either allocated on the stack or allocated in-line in a structure. Reference types store a reference to the value’s memory address, and are allocated on the heap. Reference types can be self-describing types, pointer types, or interface types.
      Variables that are value types each have their own copy of the data, and therefore operations on one variable do not affect other variables. Variables that are reference types can refer to the same object; therefore, operations on one variable can affect the same object referred to by another variable. All types derive from the System.Object base type.
    6. What is boxing and unboxing?
      Boxing permits any value type to be implicitly converted to type object or to any interface type implemented by value type. Boxing is a process in which object instances are created and copy values in to that instance.
      Unboxing is vice versa of boxing operation where the value is copied from the instance in to appropriate storage location.

      Dim x As Integer
      Dim y As Object
      x = 10
      ‘ boxing process
      y = x
      ‘ unboxing process
      x = y
    7. What are main differences between VB.NET and C#?
      Its a subjective matter which language is best. Some like VB.NET’s natural style and some like professional and terse C# syntaxes. Both use the same framework and speed is also very much equivalents. But still let’s list down some major differences between them :
      Advantages of VB.NET:
      • Has support for optional parameters which makes COM interoperability much easy.
      • With Option Strict off late binding is supported.Legacy VB functionalities can be used by using Microsoft.VisualBasic namespace.
      • Has the WITH construct which is not in C#.
      • The VB.NET part of Visual Studio .NET compiles code in the background. While this is considered an advantage for small projects, people creating very large projects have found that the IDE slows down considerably as the project gets larger.
      Advantages of C#:
      • XML documentation is generated from source code but this is now been incorporated in VS 2005 for both languages.
      • Operator overloading which is not in current VB.NET but is been introduced in VS 2005.
      • Use of this statement makes unmanaged resource disposal simple.
      • Access to Unsafe code. This allows pointer arithmetic etc, and can improve performance in some situations. However, it is not to be used lightly, as a lot of the normal safety of C# is lost (as the name implies).This is the major difference that you can access unmanaged code in C# and not in VB.NET.
    8. What is the difference between System exceptions and Application exceptions?
      All exception derives from Exception Base class. Exceptions can be generated programmatically or can be generated by system. Application Exception serves as the base class for all application-specific exception classes. It derives from Exception but does not provide any extended functionality. You should derive your custom application exceptions from Application Exception.
    9. What is code access security?
      Code access security (CAS) is part of .NET security model that determines whether or not a piece of code is allowed to run and what resources it can use while running. Example CAS will allow an application to read but not to write and delete a file or a resource from a folder.
    10. What is a satellite assembly?
      Satellite assemblies are assemblies which do not contain source code. They only contain resource files. You can create a satellite assembly using utilities like rsgen.exe (Resource Generator) and al.exe (Assmbly Linker). They are in binary DLL format which makes it easier to ship it during deployment. So finally during deployment you do not need to ship the resx files but only the compiled satellite DLL.
      Once you made your resx file or text file you should first convert in to a “.resource” files. This is done by using the resgen.exe. Below is the command snippet for resgen.exe where LoginScreen.aspx.el.resx is the resx file and output is Greek.resources file. If you do not provide the output file name it will generate “LoginScreen.resources”.
      resgen LoginScreen.aspx.el.resx Greek.resources
      Now once the resource file is generated its time make the compiled assembly of the same so that it can be shipped during deployment. This is accomplished by using the assembly linker tool al.exe provided by Microsoft.
      al.exe /out:el.dll /c:ge /embed:greek.resources
      In the /out switch you need to provide the output DLL name. /c you need to specify the culture of the resource file. /embed you need to specify all the resources which are present in the resource file.
    11. I)What is ResourceManager class?
      ResourceManager class helps us to read the resource files and get the values using key. First you need to create the object of resource manager. You need to specify the resource name and the assembly in the constructor.
      private ResourceManager objResourceManager = new ResourceManager ("Globalization.resource",System.Reflection.Assembly.GetExecutingAssembly());
      Once the resource manager is populated with details you can then use the GetString function to get by key. For instance in the below code snippet we are using the “cmdAddNew” key to get the value for button “cmdAddNew””.
      cmdAddNew.Text = objResourceManager.GetString("cmdAddNew");
    12. A)How do we deploy satellite assemblies?
      When we deploy the assembly, the folder structure has to very organized. MainFolder is the main application folder. All satellite assemblies should be deployed in the Main application folder with in there own respective folder. The respective folder is denoted by the culture code (/en-ca, /hi, /el etc.).
      If the program does not find resource file for a culture it uses the invariant culture satellite assembly. The above folder structure is a strict requirement when we deploy the satellite assembly. Any mismatch in the folder structure will lead to in appropriate results.
    13. How to prevent my .NET DLL to be decompiled?
      By design .NET embeds rich Meta data inside the executable code using MSIL. Anyone can easily decompile your DLL back using tools like ILDASM (owned by Microsoft) or third-party tools like Reflector for .NET. So any one can easily look in to your assemblies and reverse engineer them back in to actual source code and understand some real good logic which can make it easy to crack your application.
      The process by which you can stop this reverse engineering is using “obfuscation”. It’s a technique which will foil the decompilers. There are many third parties (XenoCode, Demeanor for .NET) which provide .NET obfuscation solution. Microsoft includes one that is Dotfuscator Community Edition with Visual Studio.NET.
    14. What is the difference between Convert.ToString and .ToString() method ?
      We can convert, say, the integer “i” using “i.ToString()” or “Convert.ToString” so what’s the difference. The basic difference between them is “Convert” function handles NULLS while “i.ToString()” does not it will throw a NULL reference exception error. So as good coding practice using “convert” is always safe.
    15. What is Native Image Generator (Ngen.exe)?
      The Native Image Generator utility (Ngen.exe) allows you to run the JIT compiler on your assembly’s MSIL and generate native machine code which is cached to disk. After the image is created .NET runtime will use the image to run the code rather than from the hard disk. Running Ngen.exe on an assembly potentially allows the assembly to load and execute faster, because it restores code and data structures from the native image cache rather than generating them dynamically.
      Below are some points to be remembered for Native Image Generator:
      • Native images load faster than MSIL because JIT compilation and type-safety verification is eliminated.
      • Native images enable code sharing between processes.
      • If you are sharing code between process Ngen.exe improves the performance significantly. As Native image generated Windows PE file so a single DLL file can be shared across applications. By contrast JIT produced code are private to an assembly and can not be shared.
      • Native images require more storage space and more time to generate.
      • Startup time performance improves lot. We can get considerable gains when applications share component assemblies because after the first application has been started the shared components are already loaded for subsequent applications. If assemblies in an application must be loaded from the hard disk, does not benefit as much from native images because the hard disk access time shadows everything.
      • Assemblies in GAC do not benefit from Native image generator as the loader performs extra validation on the strong named assemblies thus shadowing the benefits of Native Image Generator.
      • If any of the assemblies change then Native image should also be updated.
      • Native images require more storage space and more time to generate.
      • You should have administrative privilege for running Ngen.exe.
      • While this can decrease your application startup times as the code is statically compiled but it can be somewhat slower than the code generated dynamically by the JIT compiler. So you need to compare how the whole application performance with Ngen.exe and with out it.
      To run Ngen.exe, use the following command line.
      ngen.exe install assemblyname
      This will synchronously precompile the specified assembly and all of its dependencies. The generated native images are stored in the native image cache.
      In .NET Framework 2.0 there is a service (.NET Runtime Optimization Service) which can precompile managed assemblies in the background. You can schedule your assemblies to be precompiled asynchronously by queueing them up with the NGEN Service. Use the following command line.
      ngen.exe install assemblyname /queue:priority
    16. If we have two version of same assembly in GAC how do we make a choice ?
      You need to specify “bindingRedirect” in your config file. For instance in the below case “ClassLibraryVersion” has two versions “1.1.1″ and “1.1.2″ from which “1.1.2 is the recent version. But using the bindingRedirect we can specify saying “1.1.1″ is the new version. So the client will not use “1.1.2″.





  • Friday, November 19, 2010

    How To Insert Multiple Rows Using GridView

    Introduction

    ASP.NET GridView control is one of the most popular control when it comes to displaying and editing tabular data. However, when it comes to inserting data the GridView has very little to offer. Using a technique as illustrated in my article titled Inserting a New Row in GridView you can insert a single record using EmptyDataTemplate of the GridView. However, what if you want to insert multiple rows using GridView? In real world cases developers often require such a mechanism. Though there is no out of the box answer to this problem this article is going to demonstrate a possible solution. Read on…

    Example Scenario

    Have a look at the following figure that shows part of a web form.
    The web form consists of a GridView control and two buttons. The interesting part is that the GridView is showing five rows that are empty. The user can enter data in those five rows and then click on “Save All” button to save the data in the database. Clicking on the “CLear Grid” will clear the entered data.

    GridView and data source

    By design the GridView control is a data bound control. That means it always requires some data source to bind with. It cannot be used in unbound fashion. In order to display empty rows in the GridView you need to have a data source that contains empty items. Remember that there is a difference between “empty data source” and “data source with empty rows”. Once you have such a data source you can bind it with grid so as to render its rows. Accepting data from the user is just a matter of creating template columns.

    Example

    To illustrate how all this works create a new web site using Visual Studio. Add a new class to the web site named Customers. The following code shows the Custoemrs class:
    public class Customer
    {
        private string strCustomerID;
        private string strCompanyName;
        private string strContactName;
        private string strCountry;
    
        public string CustomerID
        {
            get
            {
                return strCustomerID;
            }
            set
            {
                strCustomerID = value;
            }
        }
    
        public string CompanyName
        {
            get
            {
                return strCompanyName;
            }
            set
            {
                strCompanyName = value;
            }
        }
    
        public string ContactName
        {
            get
            {
                return strContactName;
            }
            set
            {
                strContactName = value;
            }
        }
    
        public string Country
        {
            get
            {
                return strCountry;
            }
            set
            {
                strCountry = value;
            }
        }
    
    }
    The Customer class consists of four private variables and four public properties viz. CustomerID, CompanyName, ContactName and Country – that encapsulate them. We use a generic List of Customer objects to bind with the GridView. We opted for generic collection over DataSet or DataTable so as to make our application lightweight.
    Now drag and drop a GridView and two buttons as shown in the above figure. Add four TemplateField columns to the GridView and set their HeaderText property to Customer ID, Company Name, Contact Name and Country respectively. Design all the four template columns to have one textbox in the ItemTemplate. (see below).
    Open the data bindings editor for the textboxs and bind them with CustomerID, CompanyName, ContactName and Country columns respectively.
    Remember that we are binding Text property of the textboxes with the properties of the Customer class.
    Go in the code behind of the web form and create a private method called BindGrid().
    private void BindGrid()
    {
    List items = new List(5);
    for (int i = 0; i < 5; i++)
    {
    Customer c = new Customer();
    items.Add(c);
    }
    GridView1.DataSource = items;
    GridView1.DataBind();
    }
    The BindGrid() method creates a generic List of customers with capacity of five elements. It then runs a for loop to create five objects of Customer class. The List is then bound with the GridView. Since we just want to insert new records we need not set any properties of the Customer class. Had it been an update operation you would have set the properties of Customer objects to the appropriate values from the database.
    The BindGrid() method is called from two places – Page_Load event handler and Click event handler of “Clear Grid” button.
    protected void Page_Load(object sender,
    EventArgs e)
    {
            if(!IsPostBack)
            {
                BindGrid();
            }
    }
    protected void Button2_Click(object sender,
    EventArgs e)
    {
            BindGrid();
    }
    The main job of inserting the entered data goes inside the Click event of “Save All” button. We also need few of helper methods namely BeginAdd(), AddCustomer() and CompleteAdd().
    The BeginAdd() method looks as shown below:
    SqlConnection cnn = new SqlConnection
    ("data source=.;initial catalog=northwind;
    user id=sa;password=sa");
    SqlCommand cmd = new SqlCommand();
    
    private void BeginAdd()
    {
    cnn.Open();
    SqlTransaction tran= cnn.BeginTransaction();
    cmd.Connection = cnn;
    cmd.Transaction = tran;
    cmd.CommandText = "insert into customers
    (customerid,companyname,contactname,country)
    values(@custid,@company,@contact,@country)";
    SqlParameter p1 = new SqlParameter
    ("@custid",SqlDbType.VarChar);
    SqlParameter p2 = new SqlParameter
    ("@company", SqlDbType.VarChar);
    SqlParameter p3 = new SqlParameter
    ("@contact", SqlDbType.VarChar);
    SqlParameter p4 = new SqlParameter
    ("@country", SqlDbType.VarChar);
    cmd.Parameters.Add(p1);
    cmd.Parameters.Add(p2);
    cmd.Parameters.Add(p3);
    cmd.Parameters.Add(p4);
    }
    The code declares a connection and command at the class level. The BeginAdd() method establishes a connection with the Northwind database and initiates a transaction. In our example we insert all the records as a single transaction. You may omit the transactional operation if you don’t need it. The code then configures Connection, Transaction and CommandText properties of the command object. The CommandText property specifies an INSERT statement that inserts a record to Customers table of the Northwind database. The code then adds four parameters to the command object. The BeginAdd() method needs to be called before actual INSERT operation begins.
    The actual INSERT operation is carried out by another method called AddCustomer().
    private void AddCustomer(string custid, string company,
    string contact, string country)
    {
    try
    {
    cmd.Parameters[0].Value = custid;
    cmd.Parameters[1].Value = company;
    cmd.Parameters[2].Value = contact;
    cmd.Parameters[3].Value = country;
    cmd.ExecuteNonQuery();
    }
    catch
    {
    cmd.Transaction.Rollback();
    }
    }
    The AddCustomer() method accepts four parameters representing customer ID, company name, contact name and country. It then sets the respective parameter values of SqlCommand object we configured in BeginAdd() method earlier. Then ExecuteNonQuery() method of the command object is called. The catch block traps any exceptions occured during the INSERT operation and calls Rollback() method of the transaction object. The AddCustomer() method is called multiple times depending on the rows entered by the user.
    The CompleteAdd() method commits the transaction.
    private void CompleteAdd()
    {
    try
    {
    cmd.Transaction.Commit();
    Label1.Text = "Customers added successfully!";
    }
    catch(Exception ex)
    {
    Label1.Text = "Error completing the operation!";
    }
    finally
    {
    cnn.Close();
    }
    }
    The ComplateAdd() method calls Commit() method of transaction object and displays a success or failure message. Finally, it closes the connection that was opened in BeginAdd() method.
    The BeginAdd(), AddCustomer() and CompleteAdd() methods are used in the click event handler of “Save All” button.
    protected void Button1_Click(object sender,
    EventArgs e)
    {
    BeginAdd();
    foreach (GridViewRow row in GridView1.Rows)
    {
    if (row.RowType == DataControlRowType.DataRow)
    {
    string custid = ((TextBox)row.FindControl
    ("TextBox1")).Text;
    string company = ((TextBox)row.FindControl
    ("TextBox2")).Text;
    string contact = ((TextBox)row.FindControl
    ("TextBox3")).Text;
    string country = ((TextBox)row.FindControl
    ("TextBox4")).Text;
    if (custid != "")
    {
    AddCustomer(custid, company, contact, country);
    }
    }
    }
    CompleteAdd();
    }
    The click event handler of the button calls the BeginAdd() method. It then starts iterating through the rows of the GridView. With each iteration it extracts the values from the four textboxes using FindControl() method. We assume that if CustomerID is entered then that record is to be added to the database. You can add extra validations here. The AddCustomer() method is then called by passing newly entered customer ID, company name, contact name and country. Finally, ComplateAdd() method is called to complete the insert operation.

    Simple Web Service Authentication using SOAP Headers

    Introduction:


    I had recently worked on a smart client application which uses the web service to check for the data update. Since we had used web service method to check for data update from the centralized database, the web method request has to be authenticated whether it is sent from a valid user. So the simple way I found was to authenticate the Web Service using SOAP Headers.


    Overview:


    This article is intended to provide an overview of the steps involved in authenticating a Web Service using SOAP Headers. The article is primarily for those who are new to Web Service and Web Service Authentication.

    Step 1: Create a Web Service


    Create a new Web Service Application project with name set as WebServer.


    Place the below given code.

    using System;
    using System.Web;
    using System.Web.Services;
    using System.Web.Services.Protocols;

    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    public class Service : System.Web.Services.WebService
    {
    public Service () {

    //Uncomment the following line if using designed components 
    //InitializeComponent(); 
    }

    public AuthHeader SoapAuthentication;
    [SoapHeader("SoapAuthentication",Required=true)]//
    [WebMethod(Description = "A sample Web Method to demonstrate a simple web Service Authentication using SOAP Headers")]
    public string SampleWebMethod() 
    {

    if (SoapAuthentication.Username == "demo" && SoapAuthentication.Password == "123")
    {
    return SoapAuthentication.Username + " is an Authenticated User to access the Web Method";
    }
    else
    {
    return "Access Denied for " + SoapAuthentication.Username;
    }

    }
    }
    public class AuthHeader : SoapHeader
    {
    public string Username;
    public string Password;
    }

    In the above given code we have created a web method (SampleWebMethod) which uses the SOAP header for authentication (ie)SOAP Header will validate whether the request is coming from a valid client or not and a class AuthHeader is derived from the SoapHeader class
    Using the SOAP header SoapAuthentication, User credentials are checked for authentication. If the credentials are valid, then the authenticated message is returned to the client. If not, then an Access Denied for the user message is returned to the client.
    Now run the WebServer.

    Step 2: Create a Client Application


    Create a new web application with name set as WebClient. Add a button control, two text box controls and a label control.

    Right click the project and select Add Web Reference

    Type the url of the Web Service we created in step 1. Example:http://localhost:1999/WebServer/Service.asmx. Set the name as webreference.Click the Add Reference button. Now place the below given code inside the button click event.


    webreference.AuthHeader objAuth = new webreference.AuthHeader();
    objAuth.Username = usertxt.Text;
    objAuth.Password = passtxt.Text;

    webreference.Service objService = new webreference.Service();
    objService.AuthHeaderValue = objAuth;
    string str = objService.SampleWebMethod();
    resultlbl.Text = str;
    usertxt.Text = "";

    In the above given code we have created an object objAuth for the AuthHeader class in the WebServer using the webreference namespace. We assign values to the objAuth (AuthHeader object) property ie:Username and Password.Then we create an object objService for Service class which contains the Web Method. The object objAuth in assigned to objService property (AuthHeaderValue).At last we call the Web Method (SampleWebMethod) using the objService.

    Step 3:


    Now run the WebClient application.
    The Output screen similar to the fig given below is displayed.

    Test the authentication with valid username and password ("demo" "123") 



    Test the authentication with invalid username and password.


    Conclusion


    In this article we have come across the steps involved in creating a Web Service Authentication using SOAP Headers. This is a simple sample application to make you understand about Web Service Authentication using SOAP Headers. 


    Reference: http://www.dotnetspider.com/resources/2439-Simple-Web-Service-Au-entication-using-SOAP-Heade.aspx

    Thursday, May 20, 2010

    Sharepoint Interview Questions

    Q What is Sharepoint?
    Ans: Portal Collaboration Software.

    Q What is the difference between SharePoint Portal Server and Windows SharePoint Services?Ans: SharePoint Portal Server is the global portal offering features like global navigation and searching.Windows SharePoint Services is more content management based with document libraries andlists. You apply information to certain areas within your portal from windows sharepoint Services or directly to portal areas.


    Q What is a document library?
    Ans: A document library is where you upload your core documents. They consist of a row and columnview with links to the documents. When the document is updated so is the link on your site. Youcan also track metadata on your documents. Metadata would consist of document properties.

    Q What is a meeting workspace?
    Ans: A meeting workspace is a place to store information, attendees, and tasks related to a specificmeeting.

    Q What is a document workspace?
    Ans: Document workspaces consist of information surrounding a single or multiple documents.

    Q What is the difference between a document library and a form library?
    Ans:Document libraries consist of your core documents. An example would be a word document,excel, Powerpoint, visio, pdf, etc… Form libraries consist of XML forms.

    Q What is a web part zone?
    Ans: Web part zones are what your web parts reside in and help categorize your web parts when designing a page.

    Q How is security managed in SharePoint?
    Ans: Security can be handled at the machine,domain, or sharepoint level.

    Q How are web parts developed?
    Ans: Web parts are developed in Visual Studio .Net. VS.Net offers many web part and page templates and can also be downloaded from the Microsoft Site.

    Q What is a site definition?
    Ans: It’s a methods for providing prepackaged site and list content.

    Q What is a template?
    A template is a pre-defined set of functions or settings that can be used over time. There are manytemplates within SharePoint,Site Templates, Document Templates, Document Library and ListTemplates.

    Q How do you install web parts?
    Ans: Web Parts should be distributed as a .CAB (cabinet) file using the MSI Installer.

    Q What is CAML?
    Ans: CAML stands for Collaborative Application Markup Language and is an XML-based languagethat is used in Microsoft Windows SharePoint Services to define sites and lists, including, for Eg, fields, views, or forms, but CAML is also used to define tables in the Windows SharePoint Servies database during site provisioning.

    Q What is a DWP?
    Ans: The file extension of a web part.

    Q What is the GAC?
    Ans: Global Assembly Cache folder on the server hosting SharePoint. You place your assemblies there for web parts and services to share them.

    Q What are the differences between web part page gallery, site gallery,Virtual server galleryand online gallery?
    Ans: Web Part Page Gallery is the default gallery that comes installed with SharePoint. Site Gallery isspecific to one site. Virtual Server gallery is specific to that virtual server and online gallery aredownloadable web parts from Microsoft.

    Q What is the difference between a site and a web?
    Ans: The pages in a web site generally cover one or more topics and are interconnected through hyperlinks. Most Web sites have a home page as their starting point. While a Web is simply a blank site with SharePoint functionality built in; meaning you have to create the site from the ground up.


    Q What is Microsoft Windows SharePoint Services? How is it related to Microsoft OfficeSharePoint Server 2007?
    Ans: Windows SharePoint Services is the solution that enables you to create Web site for information sharing and document collaboration. Windows SharePoint Services — a key piece of theinformation worker infrastructure delivered in Microsoft Windows Server 2003 — providesadditional functionality to the Microsoft Office system and other desktop applications, and itserves as a platform for application development.Office SharePoint Server 2007 builds on top of Windows SharePoint Services 3.0 to provideadditional capabilities including collaboration, portal, search,Enterprise content management,business process and forms, and business intelligence.

    Q. Who is Office SharePoint server 2007 designed for?
    Ans: Office SharePoint Server 2007 can be used by information workers, IT administrators, and application developers.

    Q. What are the main benefits of Office SharePoint Server 2007?
    Ans: Office SharePoint Server 2007 provides a single integrated platform to manage intranet, extranet,and Internet applications across the enterprise.

    * Business users gain greater control over the storage, security, distribution, and management oftheir electronic content, with tools that are easy to use and tightly integrated into familiar,everyday applications.

    * Organizations can accelerate shared business processes with customers and partners acrossorganizational boundaries using InfoPath Forms Services–driven solutions.

    * Information workers can find information and people efficiently and easily through thefacilitated information-sharing functionality and simplified content publishing. In addition, accessto back-end data is achieved easily through a browser, and views into this data can bepersonalized.

    * Administrators have powerful tools at their fingertips that ease deployment, management, and system administration, so they can spend more time on strategic tasks.

    * Developers have a rich platform to build a new class of applications, called Office BusinessApplications, that combine powerful developer functionality with the flexibility and ease ofdeployment of Office SharePoint Server 2007. Through the use of out-of-the-box applicationservices, developers can build richer applications with less code.


    Q. What is the difference between Microsoft Office SharePoint Server 2007 for Internet sites and Microsoft Office SharePoint Server 2007?
    Ans: Microsoft Office SharePoint Server 2007 for Internet sites and Microsoft Office SharePoint Server2007 have identical feature functionality. While the feature functionality is similar, the usagerights are different.If you are creating an Internet, or Extranet, facing website, it is recommended that you useMicrosoft Office SharePoint Server 2007 for Internet sites which does not require the purchase client access licenses. Websites hosted using an “Internet sites” edition can only be used forInternet facing websites and all content, information, and applications must be accessible to nonemployees.Websites hosted using an “Internet sites” edition cannot be accessed by employees creating, sharing, or collaborating on content which is solely for internal use only, such as an Intranet Portal scenario.

    Q.What suites of the 2007 Microsoft Office system work with Office SharePoint Server 2007?

    Ans: Office Outlook 2007 provides bidirectional offline Synchronization with SharePoint documentlibraries, discussion groups, contacts, calendars, and tasks.vabnix.page.tlMicrosoft Office Groove 2007, included as part of Microsoft Office Enterprise 2007, will enablebidirectional offline synchronization with SharePoint document libraries.Features such as the document panel and the ability to publish to Excel Services will only beenabled when using Microsoft Office Professional Plus 2007or Office Enterprise 2007.Excel Services will only work with documents saved in the new Office Excel 2007 file format(XLSX).

    Q. How do I invite users to join a Windows SharePoint Services Site? Is the site secure?
    Ans: SharePoint-based Web sites can be password-protected to restrict access to registered users, whoare invited to join via e-mail. In addition, the site administrator can restrict certain members' rolesby assigning different permission levels to view post and edit.

    Q Can I post any kind of document?
    Ans: You can post documents in many formats, including .pdf, .htm and .doc. In addition, if you areusing Microsoft Office XP, you can save documents directly to your Windows SharePointServices site.

    Q Can I create custom templates?
    Ans: Yes you can. You can have templates for business plans, doctor's office, lawyer's office etc.

    Q. How can I make My site public?
    Ans: By default, all sites are created private.If you want your site to be a public Web site, enable anonymous access for the entire site. Then you can give out your URL to anybody in yourbusiness card, e-mail or any other marketing material. The URL for your Web site will be:http:// yoursitename.wss.bcentral.comHence, please take special care to name your site.These Web sites are ideal for information and knowledge intensive sites and/or sites where youneed to have shared Web workspace.Remember: Under each parent Web site, you can create up to 10 sub-sites each with uniquepermissions, settings and security rights.

    Q. How do the sub sites work?
    Ans: You can create a sub site for various categories.
    For example:* Departments - finance, marketing, IT* Products - electrical, mechanical, hydraulics* Projects - Trey Research, Department of Transportation, FDA* Team - Retention team, BPR team* Clients - new clients, old clients* Suppliers - Supplier 1, Supplier 2, Supplier 3* Customers - Customer A, Customer B, Customer C* Real estate - property A, property BThe URLs for each will be, for example:* http://yoursitename.wss.bcentral.com/finance* http://yoursitename.wss.bcentral.com/marketingYou can keep track of permissions for each team separately so that access is restricted whilevabnix.page.tlmaintaining global access to the parent site.


    Q.How do I make my site non-restricted?
    Ans: If you want your site to have anonymous access enabled (i.e., you want to treat it like any site onthe Internet that does not ask you to provide a user name and password to see the content of thesite), follow these simple steps:

    # Login as an administrator
    # Click on site settings
    # Click on Go to Site Administration
    # Click on Manage anonymous access
    # Choose one of the three conditions on what Anonymous users can access:** Entire Web site** Lists and libraries** NothingDefault condition is nothing; your site has restricted access.
    The default conditions allow you to create a secure site for your Web site.

    Q. Can I ask users outside of my organization to participate in my Windows SharePointServices site?
    Ans: Yes. You can manage this process using the Administration Site Settings. Simply add users via their e-mail alias and assign permissions such as Reader or Contributor.

    Q. Are there any restrictions or requirements for accessing the Windows SharePoint Services?Ans: No. There are no system or bandwidth limitations for international trial users. Additionallylanguage packs have been installed which allow users to set up sub-webs in languages other thanEnglish. These include: Arabic, Danish, Dutch, Finnish, French, German, Hebrew, Italian,Japanese, Polish, Portuguese (Brazilian), Spanish and Swedish.

    Q. Are there any browser recommendations?
    Ans: Yes. Microsoft recommends using the following browsers for viewing and editing WindowsSharePoint Services sites: Microsoft Internet Explorer 5.01 with Service Pack 2, MicrosoftInternet Explorer 5.5 with Service Pack 2, Internet Explorer 6, Netscape Navigator
    6.2 or later.vabnix.page.

    Q.What security levels are assigned to users?
    Ans: Security levels are assigned by the administrator who is adding the user. There are four levels bydefault and additional levels can be composed as necessary.
    * Reader - Has read-only access to the Web site.
    * Contributor - Can add content to existing document libraries and lists.
    * Web Designer - Can create lists and document libraries and customize pages in the Web site.
    * Administrator - Has full control of the Web site.

    Q.What is the difference between an Internet and an intranet site?
    Ans: An internet site is a normal site that anyone on the internet can access (e.g., www.msn.com,
    www.microsoft.com, etc.). You can set up a site for your company that can be accessed by anyonewithout any user name and password.An intranet (or internal network), though hosted on the Web, can only be accessed by people whoare members of the network. They need to have a login and password that was assigned to them when they were added to the site by the site administrator.

    Q. What is a workspace?
    Ans: A site or workspace is when you want a new place for collaborating on Web pages, lists anddocument libraries. For example, you might create a site to manage a new team or project,collaborate on a document or prepare for a meeting.

    Q.How customizable is the user-to-user access?
    Ans: User permissions apply to an entire Web, not to documents themselves. However, you can haveadditional sub webs that can optionally have their own permissions. Each user can be given any offour default roles. Additional roles can be defined by the administrator.

    Q.Can each user have access to their own calendar?
    Ans: Yes there are two ways to do this,
    * by creating a calendar for each user, or
    * by creating a calendar with a view for each user.

    Q. What types of files can I upload / post to the site?
    Ans: The only files restricted are those ending with the following extensions: .asa, .asp, .ida, .idc, .idq.Microsoft reserves the right to add additional file types to this listing at any time. Also, no content that violates the terms of service may be uploaded or posted to the site.

    Q.Can SharePoint be linked to an external data source?
    Ans: SharePoint data can be opened with Access and Excel as an external data source. Thus, SharePoint can be referenced as an external data source. SharePoint itself cannot reference an external datasource.

    Q. Can SharePoint be linked to a SQL database?
    Ans: This is possible via a custom application, but it not natively supported by SharePoint or SQLServer.

    Q.Can I customize my Windows SharePoint Services site?
    Ans: YES! Windows SharePoint Services makes updating sites and their content from the browser easier then ever.SharePoint includes tools that let you create custom lists, calendars, page views, etc. You can apply a theme; add List, Survey and Document Library Web Parts to a page; create personalviews; change logos; connect Web Parts and more.To fully customize your site, you can use Microsoft FrontPage 2003. Specifically, you can useFrontPage themes and shared borders, and also use FrontPage to create photo galleries and top tenlists, utilize standard usage reports, and integrate automatic Web content.

    Q. Will Microsoft Office SharePoint Server 2007 run on a 64-bit version of MicrosoftWindows?Ans: Windows SharePoint Services 3.0, Office SharePoint Server 2007, Office Forms Server 2007, andOffice SharePoint Server 2007 for Search will support 64-bit versions of Windows Server 2003.

    Q. What are the features that the portal components of Office SharePoint Server 2007 include?Ans: The portal components of Office SharePoint Server 2007 include features that are especially useful for designing, deploying, and managing enterprise intranet portals, corporate Internet Websites, and divisional portal sites. The portal components make it easier to connect to people withinthe organization who have the right skills, knowledge, and project experience.

    Q.What are the advanced features of MOSS 2007?
    Ans: * User Interface (UI) and navigation enhancements
    * Document management enhancements
    * The new Workflow engine
    * Office 2007 Integration
    * New Web Parts
    * New Site-type templates
    * Enhancements to List technology
    * Web Content Management
    * Business Data Catalog
    * Search enhancements
    * Report Center
    * Records Management
    * Business Intelligence and Excel Server
    * Forms Server and InfoPath
    * The “Features” feature
    * Alternate authentication providers and Forms-based authentication

    Q.What are the features of the new Content management in Office SharePoint 2007?
    Ans: The new and enhanced content management features in Office SharePoint Server 2007 fall within three areas:

    * Document management
    * Records management.
    * Web content managementOffice SharePoint Server 2007 builds on the core document management functionality providedby Windows SharePoint Services 3.0, including check in and check out, versioning, metadata, and role-based granular access controls. Organizations can use this functionality to deliver enhancedauthoring, business document processing, Web content management and publishing, recordsmanagement, policy management, and support for multilingual publishing.

    Q.Does a SharePoint Web site include search functionality?
    Ans: Yes. SharePoint Team Services provides a powerful text-based search feature that helps you finddocuments and information fast.

    Q.What are the benefits of Microsoft Office SharePoint Server 2007?
    Ans: * Provide a simple, familiar, and consistent user experience.* Boost employee productivity by simplifying everyday business activities.* Help meet regulatory requirements through comprehensive control over content.* Effectively manage and repurpose content to gain increased business value.* Simplify organization-wide access to both structured and unstructured information acrossdisparate systems.* Connect people with information and expertise.* Accelerate shared business processes across organizational boundaries.* Share business data without divulging sensitive information.* Enable people to make better-informed decisions by presenting business-critical information inone central location.* Provide a single, integrated platform to manage intranet, extranet, and Internet applicationsacross the enterprise.

    Q.Will SharePoint Portal Server and Team Services ever merge?
    Ans: The products will come together because they are both developed by the Office team.

    Q.What does partial trust mean the Web Part developer?
    Ans: If an assembly is installed into the BIN directory, the code must be ensured that provides errorhandling in the event that required permissions are not available. Otherwise, unhandled securityexceptions may cause the Web Part to fail and may affect page rendering on the page where theWeb Part appears.

    Q.How can I raise the trust level for assemblies installed in the BIN directory?
    Ans: Windows SharePoint Services can use any of the following three options from ASP.NET and the CLR to provide assemblies installed in the BIN directory with sufficient permissions. The following table outlines the implications and requirements for each option.

    1.Option Pros Cons Increase the trust level for the entire virtual server.
    In a development environment,increasing the trust level allows you to test an assembly with increased permissions while allowing you to recompile assemblies directly into the BIN directory without resetting IIS. This option is least secure. This option affects all assemblies used by the virtual server.There is no guarantee the destination server has the required trust level. Therefore, Web Parts may not work once installed on the destination server.

    2.Create a custom policy file for your assemblies. For more information, see "How do I create acustom policy file?" Recommended approach.This option is most secure.An assembly can operate with a unique policy that meets the minimum permission requirementsfor the assembly.By creating a custom security policy, you can ensure the destination server can run your WebParts.

    3.Requires the most configuration of all three options.Install your assemblies in the GACEasy to implement.This grants Full trust to your assembly without affecting the trust level of assemblies installed inthe BIN directory.This option is less secure.Assemblies installed in the GAC are available to all virtual servers and applications on a serverrunning Windows SharePoint Services. This could represent a potential security risk as itpotentially grants a higher level of permission to your assembly across a larger scope thannecessaryIn a development environment, you must reset IIS every time you recompile assemblies.Licensing issues may arise due to the global availability of your assembly.

    Q. Does SharePoint work with NFS?Yes and no.
    Ans: It can crawl documents on an NFS volume, but the sharepoint database or logs cannotbe stored there.

    Q.How is SharePoint Portal Server different from the Site Server?
    Ans: Site Server has search capabilities but these are more advanced using SharePoint. SPS uses digital dashboard technology which provides a nice interface for creating web parts and showing them ondashboards (pages). SS doesn't have anything as advanced as that. The biggest difference wouldbe SPS document management features which also integrate with web folders and MS Office.