1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How many files on a one aspx page?

Discussion in 'C#' started by dzflip, Nov 19, 2009.

  1. #1
    I think many developer don't know exactly how many files on a one aspx page. Sometimes, that is causes more problems arise.

    Exactly, one aspx page have 3 file:
    - 1 layout: example.aspx
    - 1 code behind: example.aspx.c
    - and 1 designer: example.aspx.designer.cs

    Some people will say, where is designer file? I can't see it.... Microsoft doesn't want to show you designer file. Because if you don't understand what it is, maybe you can change it and make it wrong, and aspx page will fail and can't run. So, Visual Studio will generate it automatic and hidden it .

    Have any ideal about it ? And is it necessary or not ? In some cases you will don't need it and you will make it by yourself.

    Do you want more information ?
     
    dzflip, Nov 19, 2009 IP
  2. FrenchSeo

    FrenchSeo Active Member

    Messages:
    43
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    91
    #2
    Hi, where did you heard about it ?
     
    FrenchSeo, Nov 24, 2009 IP
  3. dzflip

    dzflip Banned

    Messages:
    55
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    43
    #3
    I didn't heard about it. I saw designer file in Visual Studio :)
     
    dzflip, Nov 24, 2009 IP
  4. camjohnson95

    camjohnson95 Active Member

    Messages:
    737
    Likes Received:
    17
    Best Answers:
    0
    Trophy Points:
    60
    #4
    camjohnson95, Nov 24, 2009 IP
  5. same

    same Greenhorn

    Messages:
    66
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    16
    #5
    hi, when you create a project you are more concerned with .aspx and .aspx.cs file because the wizard will ask

    you regarding the code behind file.But the designer file we never do anything or any changes in that file .

    At the end of the day what you want to create is going to be on .aspx page .
     
    same, Nov 24, 2009 IP
  6. abhinavsmoudgil

    abhinavsmoudgil Peon

    Messages:
    24
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Yup Even I have observed this file and have also worked on such an environment where we can see all these 3 files.
    But I am not sure as to how this file
    "Designer file" can be made visible as i worked on such a application provided by client for some modification .
    But Dont know what the reason was its really a Bad experience to work with this as it needs to recompile the project again if you make a small change and also lot of time it generates error.
     
    abhinavsmoudgil, Nov 26, 2009 IP
  7. dzflip

    dzflip Banned

    Messages:
    55
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    43
    #7
    Exactly developer don't need to take care about designer file. But it is a way to understand clearly about ASP.Net and help to create control, raise event.... dynamically.
     
    dzflip, Nov 26, 2009 IP
  8. camjohnson95

    camjohnson95 Active Member

    Messages:
    737
    Likes Received:
    17
    Best Answers:
    0
    Trophy Points:
    60
    #8
    but there is only a designer file when creating a 'Web Application' in visual studio.. if you create a 'Web Site' then there is no designer file, they are completely different things.
     
    camjohnson95, Nov 28, 2009 IP
  9. hemant.yadav

    hemant.yadav Peon

    Messages:
    14
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #9
    Thanks for your valuable reply.
    I only knows .aspx and aspx.cs file in the case when user select code in separate file. Could you please post the url where you have study about this...?
    Its will really help me understand .net more.
     
    hemant.yadav, Jan 4, 2010 IP
  10. ashishrajiit

    ashishrajiit Peon

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #10
    Hey I have done classroom program in Asp.Net but not heard about this designer.cs file.
    Please provide how to see this file visual studio.
     
    ashishrajiit, Feb 19, 2010 IP
  11. dzflip

    dzflip Banned

    Messages:
    55
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    43
    #11
    You should have Visual studio enterprise/developer version to see designer.cs file.

    Exactly, designer.cs will declare variable controls for you.
    Ex:
    File Asp.Net
    
    <asp:hyperlink id="hplLogo" runat="server"></asp:hyperlink>
    
    Code (markup):
    File designer.cs
    
    protected global::System.Web.UI.WebControls.HyperLink hplLogo;
    
    Code (markup):
    If you don't want VS automatic generated code, you can delete designer.cs file, and declare variable controls in by yourself.
    File codebehind:
    
     protected System.Web.UI.WebControls.HyperLink hplLogo;
    
    Code (markup):
     
    dzflip, Feb 19, 2010 IP
  12. chengary

    chengary Banned

    Messages:
    88
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    16
    #12
    I saw designer file in Visual Studio
     
    chengary, Feb 20, 2010 IP