473,804 Members | 2,100 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ASP .NET 2.0 Unanswered questions...

I've asked this before, but not gotten any clear answers, so I'd figure I'd
try again.

I am an experienced ASP .NET 1.1 developer and I understand the differences
between an ASP .NET 2.0 "Web Site" vs an ASP .NET 2.0 "Web Application"
(among other things, all compiled code placed in several assembly files vs.
one assembly file).

Here are my 2 questions:

ASP .NET 2.0 "Web Application Project"
=============== ==============
In ASP .NET 1.1, when you use a DataAdapter (say with the DataAdapter
Configuration Wizard), you'd be able to see all the wizard's generated code
in the code-behind and perhaps tweak it. In ASP .NET 2.0 Web Application
Project, if I use a TableAdapter and configure it using the designer, I
can't find any code (yes, I know to look in the designer.vb file, rather
than the code-behind) for it.

Where is the code that makes all this new cool ASP .NET stuff work with some
configuration? I know I can't just see the underlying code for the class,
but I want to see the code for the instance. Where is it?!

ASP .NET 2.0 "Web Site"
=============== ===
Where are the compiled assembly files placed? I don't see them anywhere in
my site's directory structure.
No offense, but please only respond if you *know* the answers, not if you
just have suggestions on where I *could* look.

Thanks,

Scott
Oct 12 '07 #1
22 1466
I will attempt to answer your questions here without upsetting you too much
as I'm pretty sure I "know" the answers to your questions:

1, Where's the data adapter code?

In 2.0, in the web application project, XSD designers including data
adapters are considered partial classes. They are also compiled and the code
is generated for them at run-time. Therefore, there is no code to view. If
you want to override a method or property, add attributes, directives or
change the way those adapters work or map outside of the designer, simply
create a new code file in your App_Code directory and define a class (in
your dataset adapters namespace) called the exact same name as the data
adapter and mark it as partial (e.g. public partial class
MyDataTableAdap ter), no need for inheritence, this will already be set up
for you, you can however add interfaces if you wish. Then you will notice
when typing "override", you are provided with the virtual methods and
properties from your data adapter and can manipulate the class without
having to "inherit" from it.

2, Where have all the assemblies gone?

C:\WINDOWS\Micr osoft.NET\Frame work\v2.0.50727 \Temporary ASP.NET Files\%app
name%\
and then followed by intertwined assembly directories and cache created by
the runtime, e.g. agentonline\88a b2d2c\588ae2f5\ and then you will find your
assemblies such as App_Browsers.dl l, App_Code.dll, App_Web_wu_bfbz-.dll,
etc.

Hope this helps you out.

Regards,
Chad
"Scott M." <s-***@nospam.nosp amwrote in message
news:uT******** ******@TK2MSFTN GP04.phx.gbl...
I've asked this before, but not gotten any clear answers, so I'd figure
I'd try again.

I am an experienced ASP .NET 1.1 developer and I understand the
differences between an ASP .NET 2.0 "Web Site" vs an ASP .NET 2.0 "Web
Application" (among other things, all compiled code placed in several
assembly files vs. one assembly file).

Here are my 2 questions:

ASP .NET 2.0 "Web Application Project"
=============== ==============
In ASP .NET 1.1, when you use a DataAdapter (say with the DataAdapter
Configuration Wizard), you'd be able to see all the wizard's generated
code in the code-behind and perhaps tweak it. In ASP .NET 2.0 Web
Application Project, if I use a TableAdapter and configure it using the
designer, I can't find any code (yes, I know to look in the designer.vb
file, rather than the code-behind) for it.

Where is the code that makes all this new cool ASP .NET stuff work with
some configuration? I know I can't just see the underlying code for the
class, but I want to see the code for the instance. Where is it?!

ASP .NET 2.0 "Web Site"
=============== ===
Where are the compiled assembly files placed? I don't see them anywhere
in my site's directory structure.
No offense, but please only respond if you *know* the answers, not if you
just have suggestions on where I *could* look.

Thanks,

Scott

Oct 12 '07 #2
It seems to me that by having to generate the code for, say a TableAdapter
at runtime, the application execution would be slowed. Do you mean that
this code is generated at build time and then added to the assembly?

Thanks Chad!

"Chad Scharf" <ch********@com munity.nospamwr ote in message
news:ON******** ******@TK2MSFTN GP04.phx.gbl...
>I will attempt to answer your questions here without upsetting you too much
as I'm pretty sure I "know" the answers to your questions:

1, Where's the data adapter code?

In 2.0, in the web application project, XSD designers including data
adapters are considered partial classes. They are also compiled and the
code is generated for them at run-time. Therefore, there is no code to
view. If you want to override a method or property, add attributes,
directives or change the way those adapters work or map outside of the
designer, simply create a new code file in your App_Code directory and
define a class (in your dataset adapters namespace) called the exact same
name as the data adapter and mark it as partial (e.g. public partial class
MyDataTableAdap ter), no need for inheritence, this will already be set up
for you, you can however add interfaces if you wish. Then you will notice
when typing "override", you are provided with the virtual methods and
properties from your data adapter and can manipulate the class without
having to "inherit" from it.

2, Where have all the assemblies gone?

C:\WINDOWS\Micr osoft.NET\Frame work\v2.0.50727 \Temporary ASP.NET Files\%app
name%\
and then followed by intertwined assembly directories and cache created by
the runtime, e.g. agentonline\88a b2d2c\588ae2f5\ and then you will find
your assemblies such as App_Browsers.dl l, App_Code.dll,
App_Web_wu_bfbz-.dll, etc.

Hope this helps you out.

Regards,
Chad
"Scott M." <s-***@nospam.nosp amwrote in message
news:uT******** ******@TK2MSFTN GP04.phx.gbl...
>I've asked this before, but not gotten any clear answers, so I'd figure
I'd try again.

I am an experienced ASP .NET 1.1 developer and I understand the
differences between an ASP .NET 2.0 "Web Site" vs an ASP .NET 2.0 "Web
Application" (among other things, all compiled code placed in several
assembly files vs. one assembly file).

Here are my 2 questions:

ASP .NET 2.0 "Web Application Project"
============== ===============
In ASP .NET 1.1, when you use a DataAdapter (say with the DataAdapter
Configuratio n Wizard), you'd be able to see all the wizard's generated
code in the code-behind and perhaps tweak it. In ASP .NET 2.0 Web
Application Project, if I use a TableAdapter and configure it using the
designer, I can't find any code (yes, I know to look in the designer.vb
file, rather than the code-behind) for it.

Where is the code that makes all this new cool ASP .NET stuff work with
some configuration? I know I can't just see the underlying code for the
class, but I want to see the code for the instance. Where is it?!

ASP .NET 2.0 "Web Site"
============== ====
Where are the compiled assembly files placed? I don't see them anywhere
in my site's directory structure.
No offense, but please only respond if you *know* the answers, not if you
just have suggestions on where I *could* look.

Thanks,

Scott


Oct 12 '07 #3
Yes, that's what I meant. Sorry.
"Scott M." <s-***@nospam.nosp amwrote in message
news:%2******** ********@TK2MSF TNGP05.phx.gbl. ..
It seems to me that by having to generate the code for, say a TableAdapter
at runtime, the application execution would be slowed. Do you mean that
this code is generated at build time and then added to the assembly?

Thanks Chad!

"Chad Scharf" <ch********@com munity.nospamwr ote in message
news:ON******** ******@TK2MSFTN GP04.phx.gbl...
>>I will attempt to answer your questions here without upsetting you too
much as I'm pretty sure I "know" the answers to your questions:

1, Where's the data adapter code?

In 2.0, in the web application project, XSD designers including data
adapters are considered partial classes. They are also compiled and the
code is generated for them at run-time. Therefore, there is no code to
view. If you want to override a method or property, add attributes,
directives or change the way those adapters work or map outside of the
designer, simply create a new code file in your App_Code directory and
define a class (in your dataset adapters namespace) called the exact same
name as the data adapter and mark it as partial (e.g. public partial
class MyDataTableAdap ter), no need for inheritence, this will already be
set up for you, you can however add interfaces if you wish. Then you will
notice when typing "override", you are provided with the virtual methods
and properties from your data adapter and can manipulate the class
without having to "inherit" from it.

2, Where have all the assemblies gone?

C:\WINDOWS\Mic rosoft.NET\Fram ework\v2.0.5072 7\Temporary ASP.NET
Files\%app name%\
and then followed by intertwined assembly directories and cache created
by the runtime, e.g. agentonline\88a b2d2c\588ae2f5\ and then you will
find your assemblies such as App_Browsers.dl l, App_Code.dll,
App_Web_wu_bfb z-.dll, etc.

Hope this helps you out.

Regards,
Chad
"Scott M." <s-***@nospam.nosp amwrote in message
news:uT******* *******@TK2MSFT NGP04.phx.gbl.. .
>>I've asked this before, but not gotten any clear answers, so I'd figure
I'd try again.

I am an experienced ASP .NET 1.1 developer and I understand the
differences between an ASP .NET 2.0 "Web Site" vs an ASP .NET 2.0 "Web
Application " (among other things, all compiled code placed in several
assembly files vs. one assembly file).

Here are my 2 questions:

ASP .NET 2.0 "Web Application Project"
============= =============== =
In ASP .NET 1.1, when you use a DataAdapter (say with the DataAdapter
Configurati on Wizard), you'd be able to see all the wizard's generated
code in the code-behind and perhaps tweak it. In ASP .NET 2.0 Web
Application Project, if I use a TableAdapter and configure it using the
designer, I can't find any code (yes, I know to look in the designer.vb
file, rather than the code-behind) for it.

Where is the code that makes all this new cool ASP .NET stuff work with
some configuration? I know I can't just see the underlying code for the
class, but I want to see the code for the instance. Where is it?!

ASP .NET 2.0 "Web Site"
============= =====
Where are the compiled assembly files placed? I don't see them anywhere
in my site's directory structure.
No offense, but please only respond if you *know* the answers, not if
you just have suggestions on where I *could* look.

Thanks,

Scott



Oct 12 '07 #4
question 1:

the fundamental change with .net 2.0 was implementation of partial
classes. this changed the way designers worked.

in 1.1 they generated code il code that was then converted to the
language of choice, so that the source could be edited (sometimes by the
designer only) if needed.

in 2.0 the designer just produces il code, because it can be merged with
a language source file to produce one class. there are no hidden source
files, because they are not created anymore. this is way you can not
find the tableadapter code.

the only way to see the designer source code is to find the assembly it
ended up in (easier if in the app_code folder or seperate project, as
only one assembly is created) and recompile it (or use reflector).

question 2:

..net 2.0 (just like 1.0) creates temp folders that the web site is
copied to and compiled. where these folders are depends on configuration
but the default is under the .net installation folder.

just like 1.1 the folder are really a hashed set, with a folder for each
assembly and rev (say a recompiel of one page).

also just like 1.1 a assembly is created per page (for both web sites
and web applications), so finding the folder for the desired page is a
little work.

you can precompile the site to a work folder with the aspnet_compiler ,
and its easier to find stuff, because all assemblies are in the bin folder.

-- bruce (sqlwork.com)
Scott M. wrote:
I've asked this before, but not gotten any clear answers, so I'd figure I'd
try again.

I am an experienced ASP .NET 1.1 developer and I understand the differences
between an ASP .NET 2.0 "Web Site" vs an ASP .NET 2.0 "Web Application"
(among other things, all compiled code placed in several assembly files vs.
one assembly file).

Here are my 2 questions:

ASP .NET 2.0 "Web Application Project"
=============== ==============
In ASP .NET 1.1, when you use a DataAdapter (say with the DataAdapter
Configuration Wizard), you'd be able to see all the wizard's generated code
in the code-behind and perhaps tweak it. In ASP .NET 2.0 Web Application
Project, if I use a TableAdapter and configure it using the designer, I
can't find any code (yes, I know to look in the designer.vb file, rather
than the code-behind) for it.

Where is the code that makes all this new cool ASP .NET stuff work with some
configuration? I know I can't just see the underlying code for the class,
but I want to see the code for the instance. Where is it?!

ASP .NET 2.0 "Web Site"
=============== ===
Where are the compiled assembly files placed? I don't see them anywhere in
my site's directory structure.
No offense, but please only respond if you *know* the answers, not if you
just have suggestions on where I *could* look.

Thanks,

Scott

Oct 12 '07 #5
One other point worth mentioning Scott. There are two different ways
of deploying an ASP.NET 2.0 web site - copying and "publish"

There is a tool for copying the web site in VS2005 which is a very
convenient way to deploy if you want to do incremental updates. It
does mean that no DLL assemblies are uploaded but caching on the web
server should compensate on a reasonably busy site where the traffic
is not spread among too many different pages.

The publish option does create a deployed site in a manner very
similar to the "release" version of ASP.NET 1.1 (i.e. a bin directory)
but according to Microsoft this method is not necessary unless it is a
very large site where traffic is spread over a lot if different pages.

HTH
On 12 Oct, 21:25, "Chad Scharf" <chadsch...@com munity.nospamwr ote:
Yes, that's what I meant. Sorry.

"Scott M." <s-...@nospam.nosp amwrote in message

news:%2******** ********@TK2MSF TNGP05.phx.gbl. ..
It seems to me that by having to generate the code for, say a TableAdapter
at runtime, the application execution would be slowed. Do you mean that
this code is generated at build time and then added to the assembly?
Thanks Chad!
"Chad Scharf" <chadsch...@com munity.nospamwr ote in message
news:ON******** ******@TK2MSFTN GP04.phx.gbl...
>I will attempt to answer your questions here without upsetting you too
much as I'm pretty sure I "know" the answers to your questions:
1, Where's the data adapter code?
In 2.0, in the web application project, XSD designers including data
adapters are considered partial classes. They are also compiled and the
code is generated for them at run-time. Therefore, there is no code to
view. If you want to override a method or property, add attributes,
directives or change the way those adapters work or map outside of the
designer, simply create a new code file in your App_Code directory and
define a class (in your dataset adapters namespace) called the exact same
name as the data adapter and mark it as partial (e.g. public partial
class MyDataTableAdap ter), no need for inheritence, this will already be
set up for you, you can however add interfaces if you wish. Then you will
notice when typing "override", you are provided with the virtual methods
and properties from your data adapter and can manipulate the class
without having to "inherit" from it.
2, Where have all the assemblies gone?
C:\WINDOWS\Micr osoft.NET\Frame work\v2.0.50727 \Temporary ASP.NET
Files\%app name%\
and then followed by intertwined assembly directories and cache created
by the runtime, e.g. agentonline\88a b2d2c\588ae2f5\ and then you will
find your assemblies such as App_Browsers.dl l, App_Code.dll,
App_Web_wu_bfbz-.dll, etc.
Hope this helps you out.
Regards,
Chad
"Scott M." <s-...@nospam.nosp amwrote in message
news:uT******* *******@TK2MSFT NGP04.phx.gbl.. .
I've asked this before, but not gotten any clear answers, so I'd figure
I'd try again.
>I am an experienced ASP .NET 1.1 developer and I understand the
differences between an ASP .NET 2.0 "Web Site" vs an ASP .NET 2.0 "Web
Application" (among other things, all compiled code placed in several
assembly files vs. one assembly file).
>Here are my 2 questions:
>ASP .NET 2.0 "Web Application Project"
============== ===============
In ASP .NET 1.1, when you use a DataAdapter (say with the DataAdapter
Configuratio n Wizard), you'd be able to see all the wizard's generated
code in the code-behind and perhaps tweak it. In ASP .NET 2.0 Web
Application Project, if I use a TableAdapter and configure it using the
designer, I can't find any code (yes, I know to look in the designer.vb
file, rather than the code-behind) for it.
>Where is the code that makes all this new cool ASP .NET stuff work with
some configuration? I know I can't just see the underlying code for the
class, but I want to see the code for the instance. Where is it?!
>ASP .NET 2.0 "Web Site"
============== ====
Where are the compiled assembly files placed? I don't see them anywhere
in my site's directory structure.
>No offense, but please only respond if you *know* the answers, not if
you just have suggestions on where I *could* look.
>Thanks,
>Scott- Hide quoted text -

- Show quoted text -

Oct 12 '07 #6
also just like 1.1 a assembly is created per page
>
erm .. unless I'm missing something serious..... thats just wrong.. My understanding
is that this is now true for a "web site" in ASP.Net 2.0 but was not true
for ASP.Net 1.1 and is not true for ASP.Net "Web Applications"

"Web applications" and "Web Sites" are 2 different project types in VS 2005.
I thought that Web Applications followed the Old rules(1 Dll per project)
and that the Web Sites followed the alternative view of 1 dll per page.

This was originally the only web project type in VS2005 and Web Applications
were then added back by popular demand via a ctp (or something like that)
and then later made more concrete via SP1.

Did I miss somthing?
--
Rory
Oct 12 '07 #7
Hi Bruce,

Thanks for the explanations. I have a couple of comments questions,
inline....

question 2:

.net 2.0 (just like 1.0) creates temp folders that the web site is copied
to and compiled. where these folders are depends on configuration but the
default is under the .net installation folder.
Yes, but in 1.1 the initial IL assembly was placed in the /bin folder of the
ASP .NET project directory. ASP .NET Web Sites don't seem to have this?
That is what I was inquiring about.
also just like 1.1 a assembly is created per page (for both web sites and
web applications), so finding the folder for the desired page is a little
work.
??? In 1.1 there was not one assembly per page. There was one assembly per
project. You could have 1000 pages and just one assembly.
>
you can precompile the site to a work folder with the aspnet_compiler , and
its easier to find stuff, because all assemblies are in the bin folder.
Is that NGen or someting else that pre-comiles it?

Thanks Bruce!
Oct 12 '07 #8
"Rory Becker" <Ro********@new sgroup.nospamwr ote in message
news:b0******** *************** ***@msnews.micr osoft.com...
>also just like 1.1 a assembly is created per page
erm .. unless I'm missing something serious..... that's just wrong..
It is wrong.
My understanding is that this is now true for a "web site" in ASP.Net 2.0
but was not true for ASP.Net 1.1 and is not true for ASP.Net "Web
Applications"
That is correct.
"Web applications" and "Web Sites" are 2 different project types in VS
2005.
Correct.
I thought that Web Applications followed the Old rules(1 Dll per project)
and that the Web Sites followed the alternative view of 1 dll per page.
This was originally the only web project type in VS2005 and Web
Applications were then added back by popular demand via a ctp (or
something like that) and then later made more concrete via SP1.
Right again.
Did I miss somthing?
Not really, though Web Deployment Projects add some extra options...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Oct 12 '07 #9
>Did I miss somthing?
>>
Not really, though Web Deployment Projects add some extra options...

Cheers man. For a moment there, I thought I'd slipped into a parallell world
or something.
It's been the type of week where that might have explained a lot of things :)

--
Rory
Oct 12 '07 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
1512
by: S.Tobias | last post by:
In the past weeks I asked two questions concerning unions, and I got not a single reply to either. What should I do next? Re-post them? Ask them again in csc? -- Stan Tobias sed 's///g' to email
3
1090
by: CanoeGuy | last post by:
Why do some questions go unanswered? I'm trying to get some help with a problem that I'm having and am getting nowhere!!!! -- Joe Goeke
2
1311
by: =?Utf-8?B?Um9nZXI=?= | last post by:
Hello, I have a big bunch of unanswered questions, most of them really old. Should they have to be answered as they are from MANAGED newsgroups ? By the way, I hope that, at least, THIS question will be answered 8-D Thanks --
1
1061
by: Lysander | last post by:
Not sure if this is the right place for this. If I go into Control Panel I can see any responses to messages I have subscribed to. Is there a way to do the opposite. i.e. I want to go into the Access forums and see all messages that have had no replies. (I am looking for messages that I might be able to help with, so start with looking at ones no-one else has replied to) Linked to this, where on this site should questions/queries about...
0
9712
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10343
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10341
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10089
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9171
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6862
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5530
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4308
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3831
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.