User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the ASP.NET section within the Web Development category of DaniWeb, a massive community of 426,445 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,148 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our ASP.NET advertiser: Lunarpages ASP Web Hosting
Views: 4277 | Replies: 7
Reply
Join Date: Jun 2005
Posts: 4
Reputation: larko_s is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
larko_s larko_s is offline Offline
Newbie Poster

ASP in ASP.NET application

  #1  
Jun 10th, 2005
I'm building an ASP.NET app, but there ASP includes in the dreamweaver template that includes other asp pages.

I'm getting this error:

BC30289: Statement cannot appear within a method body. End of method assumed.

Line 10:
Line 11:
Line 12: sub navTabs()
Line 13: response.write("<img src='/images/" + img + "' hspace='0' border='0' usemap='#navTabs' />")
Line 14: end sub

I brought all of the code directly into the template, but it has changed anything. Any suggestions?
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Dec 2004
Posts: 1,590
Reputation: tgreer is an unknown quantity at this point 
Rep Power: 7
Solved Threads: 35
Colleague
tgreer tgreer is offline Offline
Made Her Cry

Re: ASP in ASP.NET application

  #2  
Jun 13th, 2005
You can't mix ASP and ASP.NET.
Reply With Quote  
Join Date: Jun 2005
Posts: 4
Reputation: larko_s is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
larko_s larko_s is offline Offline
Newbie Poster

Re: ASP in ASP.NET application

  #3  
Jun 13th, 2005
Originally Posted by tgreer
You can't mix ASP and ASP.NET.

Well, I have been given some logos with ASP to be included in any pages I create. I put all the logos in a dreamweaver template which references .asp pages that reference .asp pages.

What are my options to fixing the problem?

Thanks,

Sam
Reply With Quote  
Join Date: Jun 2005
Posts: 4
Reputation: larko_s is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
larko_s larko_s is offline Offline
Newbie Poster

Re: ASP in ASP.NET application

  #4  
Jun 13th, 2005
Can you "include" in ASP.NET like in ASP? If so, is it the exact same way? If it's not the same way, can you throw me an example?

Thanks,
Sam
Reply With Quote  
Join Date: Dec 2004
Posts: 1,590
Reputation: tgreer is an unknown quantity at this point 
Rep Power: 7
Solved Threads: 35
Colleague
tgreer tgreer is offline Offline
Made Her Cry

Re: ASP in ASP.NET application

  #5  
Jun 13th, 2005
ASP.NET is completely different. For every HTML element, ASP.NET has a "server control" that emits that HTML. So you can't have an ASP.NET server control that would emit "ASP" code for further processing via an ISAPI.DLL.

Sorry, but you just can't mix the two.
Reply With Quote  
Join Date: Jun 2005
Posts: 4
Reputation: larko_s is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
larko_s larko_s is offline Offline
Newbie Poster

Re: ASP in ASP.NET application

  #6  
Jun 13th, 2005
Well, what I mean is, if I re-write the asp into ASP.NET, but kept the structure the same ("include" or whatever the .NET equivalent is), will it work?

What is the .NET equivalent?

Thanks,
Sam
Reply With Quote  
Join Date: Dec 2004
Posts: 1,590
Reputation: tgreer is an unknown quantity at this point 
Rep Power: 7
Solved Threads: 35
Colleague
tgreer tgreer is offline Offline
Made Her Cry

Re: ASP in ASP.NET application

  #7  
Jun 13th, 2005
You can dymanically load images with ASP.NET. I'm not sure why you'd need an "include", by which I guess you mean an SSI (server-side-include). Your ASP.NET WebForm code-behind file will use standard programming to render image controls.

Or, you can encode all your image selection logic in a separate WebForm, and set the src attributes of your img element to that WebForm.
Reply With Quote  
Join Date: Feb 2005
Posts: 175
Reputation: Letscode is an unknown quantity at this point 
Rep Power: 4
Solved Threads: 5
Letscode's Avatar
Letscode Letscode is offline Offline
Junior Poster

Re: ASP in ASP.NET application

  #8  
Jun 15th, 2005
Sam,
You can use Usercontrols..I think thats what you need..Just create a page as a user control and reference the user control page in every page you create..
Check out this URL..
http://msdn.microsoft.com/library/de...ercontrols.asp
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb ASP.NET Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Similar Threads
Other Threads in the ASP.NET Forum

All times are GMT -4. The time now is 2:55 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC