473,399 Members | 3,656 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

reusing codebehind files?

hi.

I got a mainpage wich uses cutom controls.
i want to use the same codebehind for the customcontrol as i have for the
mainpage. is this possible?

yours truely /Anders
Nov 18 '05 #1
2 884
Using the exact same code behind isn't possible, but try placing the
code you want to share into a class that you can use from either
object.

--
Scott
http://www.OdeToCode.com

On Tue, 13 Apr 2004 11:06:46 +0200, "Anders Bohlin" <ab@news.nu>
wrote:
hi.

I got a mainpage wich uses cutom controls.
i want to use the same codebehind for the customcontrol as i have for the
mainpage. is this possible?

yours truely /Anders


Nov 18 '05 #2
okay, thanx

"Scott Allen" <bitmask@[nospam].fred.net> wrote in message
news:ch********************************@4ax.com...
Using the exact same code behind isn't possible, but try placing the
code you want to share into a class that you can use from either
object.

--
Scott
http://www.OdeToCode.com

On Tue, 13 Apr 2004 11:06:46 +0200, "Anders Bohlin" <ab@news.nu>
wrote:
hi.

I got a mainpage wich uses cutom controls.
i want to use the same codebehind for the customcontrol as i have for the
mainpage. is this possible?

yours truely /Anders

Nov 18 '05 #3

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

Similar topics

1
by: richardlane | last post by:
Hi, basic question here - I'm struggling with the transfer from asp to asp.net a bit, especially in seeing the 'bigger picture' of how things are best structured. I have a website made up...
3
by: Janderlen | last post by:
Hi, Im start to learning c#.... My question is I have a webform1.asp ¿What are the difference between write code c# inside the codebehind of the page (webform1.aspx.cs), and write c# code...
6
by: Thomas Connolly | last post by:
I have 2 pages referencing the same codebehind file in my project. Originally the pages referenced separate code behind files. Once I changed the reference to the same file, everything worked...
12
by: A.M | last post by:
Hi, Using VS.NET 2003, If i use SRC page attribute instead of CodeBehind, do i still have intelisence and generally IDE support for that? Thanks, Ali
3
by: nevets2001uk | last post by:
Hi. I've just started my second ASP.NET (VB) app and I'm using codebehind this time. I'm not using visual studio but am instead coding it all in notepad (HTML, ASP.NET and CSS) I'm trying to...
2
by: Anders Bohlin | last post by:
hi. I got a mainpage wich uses cutom controls. i want to use the same codebehind for the customcontrol as i have for the mainpage. is this possible? yours truely /Anders
12
by: Wardeaux | last post by:
All, Wanting to find a way to create web pages to add to my website without having to recompile the codebehind everytime I want to add a new one... Here's the deal: I have a web app that takes...
2
by: One Handed Man \( OHM - Terry Burns \) | last post by:
I want to know if there is any way to specify the location of the class files in a directory off the route. It is possible to drag the class files to the Code directory and have it compile OK,...
6
by: Thomas Andersson | last post by:
Hi all, I've been thinking of about adding new languages to our website and is currently investigating how this could be done. And I know that one way to go would be to create new aspx-pages...
7
by: Chris | last post by:
When I create a new aspx page, VS automatically creates the assocaited codebehind file also. Is there a way to specifiy what goes in that codebehind file by default? I mean, if I wanted to see a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
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...
0
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...
0
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...

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.