Thursday, March 8, 2012

Configure IIS 7.5 Some Issues and Solutions

IIS 7.5 one the Latest Addition of web server consits few of the new Features that make life easier for web developers and provide better security features and enhanced deploys then other iis versions .I am explaining step by step how to configure iss 7.5 for Vs 4.0 Asp.net applications.

Steps to Configure Asp.net Apps On IIS 7.0 and 7.5:.

There are Few things you need to fix early by click on root node of iis.

Anonymous Authentication should enable
Classic.netAppPool must have identity Local
Enable directory Browser if disable
Check on ISAPI and CGI restrictions

Configure Asp.net Compile File to IIS Virtual Directory

1- Create Virtual directory
2- Convert that directory to the Application by right click on it.
3- By Appling all these steps you can configure your Asp 4.0 app to iis 7.5

However Few of the issues has been defined with there solutions.

Issues And Solutions In IIS 7.5 Deployment:.

Error :.

Login Failed For user IISAppPoolClassic.Net Pool

It seems that new IIS version 7.5 runs its Classic .NET AppPool process with a different identity, and from there we get error "Login failed for user 'IIS APPPOOLClassic .NET AppPool'".

Solutions






  • go into Internet Information Services (IIS) Manager



  • expand node with your computer name on left side and select "Application Pools"



  • now in the window on the right side, right click "Classic .NET AppPool" and select "Advanced    Settings..."





  •  find "Identity" property and change its value to "LocalSystem"
     By Appling the Above your Appplication will surely give the response Inshallah......


    Error 2:.

    The page you are requesting cannot be served because of the ISAPI and CGI Restriction list settings on the Web server.The page you are requesting cannot be served because of the ISAPI and CGI Restriction list settings on the Web server.

    Solution

    You will usually get the error ” The page you are requesting cannot be served because of the ISAPI and CGI Restriction list settings on the Web server” on IIS 7.0 if the ISAPI and CGI restriction is set on the webserver . You can solve the problem by disabling this restriction . You can do so by going to IIS manager , click on the hostname of the server , double click Isapi and CGI restrictions , click Edit Feature settings on the top right hand corner and the check the check box Allow unspecified CGI modules and Allow unspecified ISAPI modules .



    Error 3:.

    Server Error in Web Application

    Unsupported Operation. A document processed by the JRC engine cannot be opened in the C++ stack.
    Solution:.

    we will have this error when the reports where not present at source.we need check out the location where we place the publish file.Vs 2010 bydefult not attach the reports with publish file so we need to paste the .rpt files on the particular location where we have publish our application.In this way you can have access of Crystal reports through IIS.
     

    Sunday, December 25, 2011

    Sqlserver Issues ,Security Max Size(2005/2008 sql)

    These are some of the Maximum Capacity Specifications for SQL Server 2008/2005 the Maximum size upto

    * Database size: 524,272 terabytes
    * Databases per instance of SQL Server: 32,767
    * Filegroups per database: 32,767
    * Files per database: 32,767
    * File size (data): 16 terabytes
    * File size (log): 2 terabytes
    * Rows per table: Limited by available storage
    * Tables per database: Limited by number of objects in a database

    DataInsertion From One DataBase Column to Another DataBase Column

    we need to write the following query to Insert Data from One Database column to another database column while the column name must be same in both of the tables and the datatype of the columns.

    "Insert Into ProductDB2.dbo.Items(itm_ItemCode,itm_ItemDesc)
    Select SupplyChaindb.dbo.SI_Item.itm_ItemCode,SupplyChaindb.dbo.SI_Item.itm_ItemDesc from SupplyChaindb.dbo.SI_Item"


    Insert Into ProductDB2.dbo.Items(itm_ItemCode,itm_ItemDesc)Select SupplyChaindb.dbo.SI_Item.itm_ItemCode,SupplyChaindb.dbo.SI_Item.itm_ItemDesc from SupplyChaindb.dbo.SI_Item where SupplyChaindb.dbo.SI_Item.itm_Active='1'

    Debug Sqlserver Stored Procedure:.

    Create the above procedure.

      PROCEDURE Procdebug @in INT, @out INT out BEGINIF ( @in IS NULL ) SET
    @in = 0 WHILE ( @in < = 100 ) BEGIN SET @out = @in SET @in = @in + 10 PRINT CONVERT(VARCHAR, @in) + ' - ' + CONVERT(VARCHAR, @out) END END
    GO
    DECLARE
    EXEC
    SELECT
    @out INT Procdebug 5,@out OUTPUT @out
    After creating stored procedure , select the second script to debug it. After selecting press F11, screen will open sored procedure in debug mode.Keep Press the F11 Button to continue all the cycles of debuging by press the F11 button you will the overall stage values.


    CREATE
    AS

    Saturday, November 19, 2011

    Asp.net from 2.0 ,3.5,4.0 Versions.

    Asp.net from version 1.1 and from the latest version 4.0 changes the technology day by the developers need to be on the twose to be apart of Microsoft Technologist.The Technology used few of the very broad Libraries that reduce the code upto 25%.Few of the technical terms i am going to share with you.

    Tracing:.

    Tracing a term that displays the details about how your code was executed. It refers to collecting information about the application while it is running. Tracing information can help you to troubleshoot an application. It enables you to record information in various log files about the errors that might occur at run time. You can analyze these log files to find the cause of the errors.


    Asp.Net 4.O Issue ConfigurationManager Class Not Access

    The same happened to me... I changed my code accordingly, but the project wouldn't compile. It turns out that you need to add a reference to System.Configuration to the project, rather than simply adding it with a using statement. This can be done as:

    Add a reference to System.Configuration by clicking Project -> Add Reference... and searching through the .NET components for System.Configuration




    Thursday, October 6, 2011

    Asp.Net Codes with Best URLs

    As as the time going we have seen many latest Trends in Dotnet Platform the Latest Visual Studio 2011 has been lanual Studio 2011 has been lanuched with exsiting features for software engineers.The inclusion of MVC 3.0,Linq make the development more impressive .

    Find the Best URLs for your refrence for ASP.NET Codes
    check with exsiting features for software engineers.The inclusion of MVC 3.0,Linq make the development more impressive .

    http://www.aspdotnet-suresh.com/
    http://csharpdotnetfreak.blogspot.com/
    http://asp-net-example.blogspot.com/2008/12/aspnet-arraylist-example-using.html
    http://www.aspnettutorials.com/tutorials/advanced/Hashtable-csharp.aspx
    http://www.xmlforasp.net
    http://aspdotnetcodebook.blogspot.com

    Saturday, July 16, 2011

    Asp,net Inside MVC Architecture

    Inside MVC Architecture

    The entire ASP.NET MVC architecture is based on Microsoft .NET Framework 3.5 and in addition uses LINQ to SQL Server.
     

    What is a Model?

    1. MVC model is basically a C# or VB.NET class
    2. A model is accessible by both controller and view
    3. A model can be used to pass data from Controller to view
    4. A view can use model to display data in page.

    What is a View?

    1. View is an ASPX page without having a code behind file
    2. All page specific HTML generation and formatting can be done inside view
    3. One can use Inline code (server tags ) to develop dynamic pages
    4. A request to view (ASPX page) can be made only from a controller’s action method
    What is a Controller?
    1. Controller is basically a C# or VB.NET class which inherits system.mvc.controller
    2. Controller is a heart of the entire MVC architecture
    3. Inside Controller’s class action methods can be implemented which are responsible for responding to browser OR calling views.
    4. Controller can access and use model class to pass data to views
    5. Controller uses ViewData to pass any data to view    
      Overview:.
    • The user interacts with the user interface in some way (for example, by pressing a mouse button).
    • The controller handles the input event from the user interface, often via a registered handler or callback, and converts the event into an appropriate user action, understandable for the model.
    • The controller notifies the model of the user action, possibly resulting in a change in the model's state. (For example, the controller updates the user's shopping cart.)[4]
    • A view queries the model in order to generate an appropriate user interface (for example the view lists the shopping cart's contents). The view gets its own data from the model. In some implementations, the controller may issue a general instruction to the view to render itself. In others, the view is automatically notified by the model of changes in state (Observer) that require a screen update.
    • The user interface waits for further user interactions, which restarts the control flow cycle.






      Monday, May 30, 2011

      Asp.net Tech/web Services

      ASP.NET application life cycle and events processing 

      A web application starts when a browser requests a page of the application first time. The request is received by the IIS which then starts ASP.NET worker process (aspnet_wp.exe). The worker process then allocates a process space to the assembly and loads it. An application_start event occurs followed by Session_start. The request is then processed by the ASP.NET engine and sends back response in the form of HTML. The user receives the response in the form of page.

      The page can be submitted to the server for further processing. The page submitting triggers postback event that causes the browser to send the page data, also called as view state to the server. When server receives view state, it creates new instance of the web form. The data is then restored from the view state to the control of the web form in Page_Init event.
      The data in the control is then available in the Page_load event of the web form. The cached event is then handled and finally the event that caused the postback is processed. The web form is then destroyed. When the user stops using the application, Session_end event occurs and session ends. The default session time is 20 minutes. The application ends when no user accessing the application and this triggers Application_End event. Finally all the resources of the application are reclaimed by the Garbage collector.

      Explain the ASP.NET page lifecycle.  

       

      Lifecycle of a page in ASP.NET follows following steps:
      Page_Init(Initialization of the page) >> LoadViewState(loading of View State) >> LoadPostData(Postback data processing) >> Page_Load(Loading of page) >> RaisePostDataChangedEvent(PostBack change notification) >> RaisePostBackEvent (PostBack event handling) >> Page_PreRender (Page Pre Rendering Phase) >> SaveViewState (View state saving) >> Page_Render (Page rendering) >> Page_UnLoad (Page unloading)

       ----------------------------------------------------------------------------------

      DataSet Vs DataReader

      • DataSet Object works under Disconnected mode, While DataReader Object has Connected mode.
      • DataSet Object has Read/Write access, While DataReader Object has Read-only access.
      • DataSet Object Supports multiple tables from different databases, While DataReader Object Supports a single table based on a single SQL query of one database.
      • DataSet Object has Greater overhead to enable additional features, While DataReader Object being Lightweight object with very little overhead.
      • DataSet Object is Bind to multiple controls, While DataReader Object is Bind to a single control.
      • DataSet Object supports Forward and backward scanning of data, While DataReader Object supports Forward-only scanning of data.
      • DataSet Object has Slower access to data, While DataReader Object has Faster access to data.
      • DataSet Object is Supported by Visual Studio .NET tools, While DataReader Object Must be manually coded. 
      Machine Vs Webconfig

      Machine.config:
      1. The configurations mentioned in machine.config file are applicable to all the applications hosted in a machine/computer/server.

      2. The machine.config file is located in x:\\Microsoft.NET\Framework\\config\machine.config

      3. There can be only one machine.config file per machine (per dotnet framework installed).

      web.config:
      1. web.config file contains configurations for a single application.

      2. Web.config files overrides the configurations mentioned in machine.config file.

      3. The web configuration file is located in your application's root folder

      4. There can be multiple web.config files in a single web application in different sub folders.

        Friday, April 8, 2011

        BlackBerry & Android apps Tablet programming



        Installation Guide:
        First off the Required Downloads:
        1. VMWare virtual machine player here
        2. Adobe AIR 2.5 here
        3. BlackBerry Tablet OS SDK here
        4. BlackBerry PlayBook Simulator here
        The announcement by RIM (Research in Motion) of their latest tablet PlayBook and its accompanying application development platform is really exciting news! Yes – mobile is hot!

         BlackBerry & Android apps

        Sharing Few of the documentation for blackberry apps.

        *   http://docs.blackberry.com/en/developers/deliverables/11958/Create_a_menu_836422_11.jsp

        *   http://docs.blackberry.com/en/developers/deliverables/11958/UI_components_508102_11.jsp

        *   http://supportforums.blackberry.com/t5/Java-Development/tkb-p/java_dev%40tkb?labels=blackberry+ui