Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Frameset

Frameset

Scheduled Pinned Locked Moved ASP.NET
26 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    terjk
    wrote on last edited by
    #1

    Frameset is in .htm page. If i were to drag my page into the each frame. (SET PAGE FOR FRAME). So the page will be saved as .htm instead of .aspx. I'm wokring on .aspx pages. Is there any way where i can have frames in the pages instead of .aspx pages in .htm frameset.

    J T 2 Replies Last reply
    0
    • T terjk

      Frameset is in .htm page. If i were to drag my page into the each frame. (SET PAGE FOR FRAME). So the page will be saved as .htm instead of .aspx. I'm wokring on .aspx pages. Is there any way where i can have frames in the pages instead of .aspx pages in .htm frameset.

      J Offline
      J Offline
      John Kuhn
      wrote on last edited by
      #2

      :confused: Do you want the page that generates the frameset to be an ASP.NET Web Form (.aspx) or the pages contained in each frame of the frameset to be ASP.NET Web Form pages? Or, do you want one page that contains the frameset and the contents of the frames all in one page? What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

      T 1 Reply Last reply
      0
      • T terjk

        Frameset is in .htm page. If i were to drag my page into the each frame. (SET PAGE FOR FRAME). So the page will be saved as .htm instead of .aspx. I'm wokring on .aspx pages. Is there any way where i can have frames in the pages instead of .aspx pages in .htm frameset.

        T Offline
        T Offline
        T Manjaly
        wrote on last edited by
        #3

        Can you make the question more clear? You can have frameset in .htm and .aspx files without any issues. :zzz:----------------------------------------------------------------------:(( T Manjaly
        C# Tutorials and samples : http://www.dotnetspider.com

        1 Reply Last reply
        0
        • J John Kuhn

          :confused: Do you want the page that generates the frameset to be an ASP.NET Web Form (.aspx) or the pages contained in each frame of the frameset to be ASP.NET Web Form pages? Or, do you want one page that contains the frameset and the contents of the frames all in one page? What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

          T Offline
          T Offline
          terjk
          wrote on last edited by
          #4

          I want a page with frames and content all in one Web Form page.

          J 1 Reply Last reply
          0
          • T terjk

            I want a page with frames and content all in one Web Form page.

            J Offline
            J Offline
            John Kuhn
            wrote on last edited by
            #5

            OK, that's what I thought. That's not possible. Check out the definition of a frameset on the HTML Reference (here[^]). The frameset page does not contain anything except pointers to other pages. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

            T 1 Reply Last reply
            0
            • J John Kuhn

              OK, that's what I thought. That's not possible. Check out the definition of a frameset on the HTML Reference (here[^]). The frameset page does not contain anything except pointers to other pages. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

              T Offline
              T Offline
              terjk
              wrote on last edited by
              #6

              k. So is there any way i can add frames to mine web form? (without affecting whatever it's there now):confused:

              J 1 Reply Last reply
              0
              • T terjk

                k. So is there any way i can add frames to mine web form? (without affecting whatever it's there now):confused:

                J Offline
                J Offline
                John Kuhn
                wrote on last edited by
                #7

                Well, yes and no. Technically, you could create an ASP.NET Web Form that would generate a frameset page, but I can't imagine there would be much of a point to doing so. I suggest you right-click on your web project, select Add..., then select Add New Item..., then select Frameset from the Add New Item dialog box, and name the resulting page "Default.htm". Then, right-click on the main frame and select "Set Page for Frame" and then pick your existing ASP.NET web form. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                T 1 Reply Last reply
                0
                • J John Kuhn

                  Well, yes and no. Technically, you could create an ASP.NET Web Form that would generate a frameset page, but I can't imagine there would be much of a point to doing so. I suggest you right-click on your web project, select Add..., then select Add New Item..., then select Frameset from the Add New Item dialog box, and name the resulting page "Default.htm". Then, right-click on the main frame and select "Set Page for Frame" and then pick your existing ASP.NET web form. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                  T Offline
                  T Offline
                  terjk
                  wrote on last edited by
                  #8

                  So the resulting page will be .htm and not .aspx?

                  J 1 Reply Last reply
                  0
                  • T terjk

                    So the resulting page will be .htm and not .aspx?

                    J Offline
                    J Offline
                    John Kuhn
                    wrote on last edited by
                    #9

                    Correct, the Frameset will be a plain old HTML page stored in an .htm or an .html file. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                    T 1 Reply Last reply
                    0
                    • J John Kuhn

                      Correct, the Frameset will be a plain old HTML page stored in an .htm or an .html file. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                      T Offline
                      T Offline
                      terjk
                      wrote on last edited by
                      #10

                      But the rest of mine web forms are in .aspx. Wouldn't it be strange if the program have both aspx and html pages?

                      J 1 Reply Last reply
                      0
                      • T terjk

                        But the rest of mine web forms are in .aspx. Wouldn't it be strange if the program have both aspx and html pages?

                        J Offline
                        J Offline
                        John Kuhn
                        wrote on last edited by
                        #11

                        Not at all -- it is a WEB application after all... all those ASPX pages do is generate HTML. You might consider starting your app at Default.aspx if you are using any kind of authentication or authorization, then redirect to the Frameset page. The same rules (Security, etc.) will still apply to the ASPX pages. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                        T 1 Reply Last reply
                        0
                        • J John Kuhn

                          Not at all -- it is a WEB application after all... all those ASPX pages do is generate HTML. You might consider starting your app at Default.aspx if you are using any kind of authentication or authorization, then redirect to the Frameset page. The same rules (Security, etc.) will still apply to the ASPX pages. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                          T Offline
                          T Offline
                          terjk
                          wrote on last edited by
                          #12

                          When i set a ascx page for frame. It say: This type of page is not served. So does not mean that only aspx can be added to the frameset?

                          J 1 Reply Last reply
                          0
                          • T terjk

                            When i set a ascx page for frame. It say: This type of page is not served. So does not mean that only aspx can be added to the frameset?

                            J Offline
                            J Offline
                            John Kuhn
                            wrote on last edited by
                            #13

                            An ASCX is a user control, and no, it is not intended to serve itself. You have to put a user control on a page. Using a Frameset, though, you can target any other kind of URL that produces HTML at runtime: HTM, ASP, ASPX, JSP, etc... What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                            T 1 Reply Last reply
                            0
                            • J John Kuhn

                              An ASCX is a user control, and no, it is not intended to serve itself. You have to put a user control on a page. Using a Frameset, though, you can target any other kind of URL that produces HTML at runtime: HTM, ASP, ASPX, JSP, etc... What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                              T Offline
                              T Offline
                              terjk
                              wrote on last edited by
                              #14

                              That means i got to put my ascx control into a aspx page before putting in into the frame? If my web form is already done but without the frames. Does that means i have to redo the sections on different pages so that i can insert into the different frames?

                              J 1 Reply Last reply
                              0
                              • T terjk

                                That means i got to put my ascx control into a aspx page before putting in into the frame? If my web form is already done but without the frames. Does that means i have to redo the sections on different pages so that i can insert into the different frames?

                                J Offline
                                J Offline
                                John Kuhn
                                wrote on last edited by
                                #15

                                helpNeeded wrote: That means i got to put my ascx control into a aspx page before putting in into the frame? Yes. helpNeeded wrote: If my web form is already done but without the frames. Does that means i have to redo the sections on different pages so that i can insert into the different frames? Not sure what you're asking here, but here's what a frames page should look like:

                                <html>
                                <head>
                                <title>Hello!</title>
                                </head>
                                <frameset rows="64,*">
                                <frame name="banner" src="MyPage1.aspx" scrolling="no" noresize>
                                <frameset cols="150,*">
                                <frame name="contents" src="MyPage2.aspx">
                                <frame name="main" src="MyPage3.aspx">
                                </frameset>
                                <noframes>
                                <p>This HTML frameset displays multiple Web pages. To view this frameset, use a Web browser that supports HTML 4.0 and later.</p>
                                </noframes>
                                </frameset>
                                </html>

                                ... but where I've indicated the names of pages in bold, you should put the names of your actual pages. The frame named "main" should contain the first ASPX page you wish the application to present, or a blank HTML page, and then hyperlinks in the contents frame pointing to other ASPX pages. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                                T 1 Reply Last reply
                                0
                                • J John Kuhn

                                  helpNeeded wrote: That means i got to put my ascx control into a aspx page before putting in into the frame? Yes. helpNeeded wrote: If my web form is already done but without the frames. Does that means i have to redo the sections on different pages so that i can insert into the different frames? Not sure what you're asking here, but here's what a frames page should look like:

                                  <html>
                                  <head>
                                  <title>Hello!</title>
                                  </head>
                                  <frameset rows="64,*">
                                  <frame name="banner" src="MyPage1.aspx" scrolling="no" noresize>
                                  <frameset cols="150,*">
                                  <frame name="contents" src="MyPage2.aspx">
                                  <frame name="main" src="MyPage3.aspx">
                                  </frameset>
                                  <noframes>
                                  <p>This HTML frameset displays multiple Web pages. To view this frameset, use a Web browser that supports HTML 4.0 and later.</p>
                                  </noframes>
                                  </frameset>
                                  </html>

                                  ... but where I've indicated the names of pages in bold, you should put the names of your actual pages. The frame named "main" should contain the first ASPX page you wish the application to present, or a blank HTML page, and then hyperlinks in the contents frame pointing to other ASPX pages. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                                  T Offline
                                  T Offline
                                  terjk
                                  wrote on last edited by
                                  #16

                                  But one thing... How can i link the things in the different frames together? Eg, i have a checkbox list of name on the left frame. Upon selection, a table in the main frame will be generate based on the name selected. What should i do? Can this be solved?

                                  J 1 Reply Last reply
                                  0
                                  • T terjk

                                    But one thing... How can i link the things in the different frames together? Eg, i have a checkbox list of name on the left frame. Upon selection, a table in the main frame will be generate based on the name selected. What should i do? Can this be solved?

                                    J Offline
                                    J Offline
                                    John Kuhn
                                    wrote on last edited by
                                    #17

                                    Normally, with two or three frames (i.e., a "toc" frame and a "main" frame) the items in the TOC simply refer to pages that should appear in the Main frame, so something like <a href="MyPage.aspx" target="main">Display Page One</a> in the HTML of the page in the TOC frame results in another page displayed in the Main frame. In your case, I think one of two things might work out: 1) Substitute a DataList of LinkButtons in place of the CheckBoxList, and set the target attribute of each LinkButton to the name of the frame in which the content corresponding to that item should appear. LinkButton can be data bound, so that shouldn't be too much of a change. 2) Create a client-side JavaScript (JScript) method invoked from the client-side scripting onClick event that handles the process of what happens when a CheckBoxList item is checked or unchecked on the client, rather than posting back to the server. In this fashion, you could control what appears in the Main frame as well, but coding the solution will be trickier and you'd have to be very familiar with the DOM and DHTML events or find a good reference to those elements involved. Other than that, are you sure you need frames? Perhaps you might think of a way of getting from point a to point b without them. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                                    T 1 Reply Last reply
                                    0
                                    • J John Kuhn

                                      Normally, with two or three frames (i.e., a "toc" frame and a "main" frame) the items in the TOC simply refer to pages that should appear in the Main frame, so something like <a href="MyPage.aspx" target="main">Display Page One</a> in the HTML of the page in the TOC frame results in another page displayed in the Main frame. In your case, I think one of two things might work out: 1) Substitute a DataList of LinkButtons in place of the CheckBoxList, and set the target attribute of each LinkButton to the name of the frame in which the content corresponding to that item should appear. LinkButton can be data bound, so that shouldn't be too much of a change. 2) Create a client-side JavaScript (JScript) method invoked from the client-side scripting onClick event that handles the process of what happens when a CheckBoxList item is checked or unchecked on the client, rather than posting back to the server. In this fashion, you could control what appears in the Main frame as well, but coding the solution will be trickier and you'd have to be very familiar with the DOM and DHTML events or find a good reference to those elements involved. Other than that, are you sure you need frames? Perhaps you might think of a way of getting from point a to point b without them. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.

                                      T Offline
                                      T Offline
                                      terjk
                                      wrote on last edited by
                                      #18

                                      I guess both cant work for me. First, im not familiar with DOM and DHTML. Secondly, I have to use checkbox. (allow multiple clicks which link button don't allow) And finally, i required to used frames. Not that i wanted but i'm asked to do so. =( What should I do. Checkboxlist doesn't allow the use of tooltip for each item in the list too.

                                      J 1 Reply Last reply
                                      0
                                      • T terjk

                                        I guess both cant work for me. First, im not familiar with DOM and DHTML. Secondly, I have to use checkbox. (allow multiple clicks which link button don't allow) And finally, i required to used frames. Not that i wanted but i'm asked to do so. =( What should I do. Checkboxlist doesn't allow the use of tooltip for each item in the list too.

                                        J Offline
                                        J Offline
                                        John Kuhn
                                        wrote on last edited by
                                        #19
                                        1. Go back to the person writing the specifications and tell him or her that frames suck and that they're hard to work with. 2) Put a button at the end of the checkboxlist called "Submit" or something, store all the checkboxlist values in session, then redirect the entire app back to the original frameset page, and reload everything in each of the frames from scratch based on the values stored in session. 3) Good luck... What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.
                                        T 1 Reply Last reply
                                        0
                                        • J John Kuhn
                                          1. Go back to the person writing the specifications and tell him or her that frames suck and that they're hard to work with. 2) Put a button at the end of the checkboxlist called "Submit" or something, store all the checkboxlist values in session, then redirect the entire app back to the original frameset page, and reload everything in each of the frames from scratch based on the values stored in session. 3) Good luck... What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.
                                          T Offline
                                          T Offline
                                          terjk
                                          wrote on last edited by
                                          #20

                                          hee... now there is no need for me to do the frames anymore. I free from this now! Thanks for your help. I told my supervisor what you have told me. but now i have another problem not sure if you could help me with it. It regarding imagebutton. To add an handler to the imagebutton that i create programmatically (not user control) imgholi.ImageUrl = Server.MapPath("Pics\pencil.gif") AddHandler imgholi.Click, AddressOf Me.ImageClickHandler cellleft.Controls.Add(imgholi) Private Sub ImageClickHandler(ByVal sender As Object, ByVal e As ImageClickEventArgs) Response.Redirect("MyBookingNewBooking.aspx") End Sub why is it that when i click on the image button, there is no event call. If a user control was used. the sub routine will end with .handles img.click. Is this where the problem lies? Since my imgbtn is not delcared therefore i cannot add .handles img.click. Another thing, when dim img as new IMAGE they prompt me with an error. why is it that imagebutton can be new and image cannot. Must i import ot inherit anything?

                                          J 1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups