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. Methods being added to web page, not codebehind.

Methods being added to web page, not codebehind.

Scheduled Pinned Locked Moved ASP.NET
question
6 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.
  • R Offline
    R Offline
    Richard Jones
    wrote on last edited by
    #1

    I used to be able to double-click on a control, and it would add a method to the .vb file. Now, it changes to Source view mode of the .aspx file, and adds a block with the method inside. How do I change it back? <div class="ForumSig">"Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit..." "There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain..." </div>

    T 1 Reply Last reply
    0
    • R Richard Jones

      I used to be able to double-click on a control, and it would add a method to the .vb file. Now, it changes to Source view mode of the .aspx file, and adds a block with the method inside. How do I change it back? <div class="ForumSig">"Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit..." "There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain..." </div>

      T Offline
      T Offline
      tina newcoder
      wrote on last edited by
      #2

      I think you are using HTML controls ... :cool:

      R 1 Reply Last reply
      0
      • T tina newcoder

        I think you are using HTML controls ... :cool:

        R Offline
        R Offline
        Richard Jones
        wrote on last edited by
        #3

        <%@ Page Language="vb" AutoEventWireup="true" CodeBehind="Page3.aspx.vb" Inherits="ApplicationForm.Page31" %>

        <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

        <script runat="server">

        Protected Sub CheckBox1_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs)

        End Sub
        </script>

        <html xmlns="http://www.w3.org/1999/xhtml" >
        <head runat="server">
        <title>Software Install</title>
        </head>
        <body>
        <form id="form1" runat="server">
        <div>
        <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Button" />
        <asp:CheckBox ID="CheckBox1" runat="server" OnCheckedChanged="CheckBox1_CheckedChanged" /></div>
        </form>
        </body>
        </html>

        I did see what you were referring to in the help, though.

        "Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit..." "There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain..."

        A 1 Reply Last reply
        0
        • R Richard Jones

          <%@ Page Language="vb" AutoEventWireup="true" CodeBehind="Page3.aspx.vb" Inherits="ApplicationForm.Page31" %>

          <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

          <script runat="server">

          Protected Sub CheckBox1_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs)

          End Sub
          </script>

          <html xmlns="http://www.w3.org/1999/xhtml" >
          <head runat="server">
          <title>Software Install</title>
          </head>
          <body>
          <form id="form1" runat="server">
          <div>
          <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Button" />
          <asp:CheckBox ID="CheckBox1" runat="server" OnCheckedChanged="CheckBox1_CheckedChanged" /></div>
          </form>
          </body>
          </html>

          I did see what you were referring to in the help, though.

          "Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit..." "There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain..."

          A Offline
          A Offline
          AlexeiXX3
          wrote on last edited by
          #4

          If you want to use the code behind model, when you add a page to your web site, select the place code in separate file checkbox

          Alexei Rodriguez

          R 1 Reply Last reply
          0
          • A AlexeiXX3

            If you want to use the code behind model, when you add a page to your web site, select the place code in separate file checkbox

            Alexei Rodriguez

            R Offline
            R Offline
            Richard Jones
            wrote on last edited by
            #5

            I'm using VS 2005. On Add->Existing Item->Web Form, I don't get that option (checkbox), just the filename.

            "Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit..." "There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain..."

            A 1 Reply Last reply
            0
            • R Richard Jones

              I'm using VS 2005. On Add->Existing Item->Web Form, I don't get that option (checkbox), just the filename.

              "Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit..." "There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain..."

              A Offline
              A Offline
              AlexeiXX3
              wrote on last edited by
              #6

              That option is not available when adding existing items You should make the appropiate modifications by hand after adding the existing item to your project

              Alexei Rodriguez

              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