Copying a web form within a project

E

Eric

Couple of general webform questions. Most are about html code
created/managed by the editor. I work in GridLayout Mode.

1. Is there a reference or guideline for how the html should appear
when viewing a web form in HTML format, after you've added elements in
design view? Can I change they way they are formatted for viewing?

2. What's the easist way to clone a webform while inside a project. I
don't want to inherit from it, I just want a new copy of it with a
different name in the current project. See #3 below for the wrong way
to do it.

3. I created a new web form. I then selected all the elements on an
existing web form and then copied and pasted them to the new web form.
Now I cannot draw a box around the elements on the new form to select
them. I have to select them manually. The form works and compiles, but
it's very unstable in the development environment.

Also when I copy and past an element it appears in the upper right
hand corner. It's html appears outside of the form tag so if I try to
recompile, I get a message telling me the new element needs to be
inside of the form. Looking at the html, the element has been added to
the very bottom of the html, outside of the </form> closing tag.

I've also got a <DIV> tag on the suspect form too that appeared out of
nowhere. Can anyone explain how that got there. I think he's the cause
of my problems (from the cut and paste from the source form).

Thanks in advance.
Eric
 
J

John Saunders

Answers inline:

Eric said:
Couple of general webform questions. Most are about html code
created/managed by the editor. I work in GridLayout Mode.

Sorry, I never use Grid Layout. I think that some of your problems are due
to grid layout, so I won't be able to answer those.
1. Is there a reference or guideline for how the html should appear
when viewing a web form in HTML format, after you've added elements in
design view? Can I change they way they are formatted for viewing?

It's just a readability issue, so of course, there's at least one standard
per reader. :) You have some control over the formatting by using the
options under Tools->Options->Text Editor->HTML/XML. The formatting options
have become much richer under VS 2005 (beta).
2. What's the easist way to clone a webform while inside a project. I
don't want to inherit from it, I just want a new copy of it with a
different name in the current project. See #3 below for the wrong way
to do it.

In the solution explorer, right-click the web form and choose Copy. Then
choose the folder you want it to go into and choose Paste.
3. I created a new web form. I then selected all the elements on an
existing web form and then copied and pasted them to the new web form.
Now I cannot draw a box around the elements on the new form to select
them. I have to select them manually. The form works and compiles, but
it's very unstable in the development environment.

Also when I copy and past an element it appears in the upper right
hand corner. It's html appears outside of the form tag so if I try to
recompile, I get a message telling me the new element needs to be
inside of the form. Looking at the html, the element has been added to
the very bottom of the html, outside of the </form> closing tag.

I've also got a <DIV> tag on the suspect form too that appeared out of
nowhere. Can anyone explain how that got there. I think he's the cause
of my problems (from the cut and paste from the source form).

I suspect that all of your problems in #3 are due to grid layout.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top