473,806 Members | 2,321 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

USing shadow in vb.net and its equivalent in c#.

Hi all,

can any one tell me use of shadow keyword in vb.net and its equivalent
in c# with e.g.

Please help me.

thanks in advance.

Jan 8 '07 #1
1 6342
On 2007-01-08, tr************* *@yahoo.com <tr************ **@yahoo.comwro te:
Hi all,

can any one tell me use of shadow keyword in vb.net and its equivalent
in c# with e.g.

Please help me.

thanks in advance.
The shadow keyword allows you to hide a base implementation in an inheritance
hiearcy. This is useful in situations, such as a base class change declaring
a method already defined in your derived class. Redifining access levels, or
the readability/writeability of a property... Look in the documentation on
the shadows keyword and you will see examples and explanations of it's use.

The C# equivalent is new (not to be mistaken with new :)

public class TheClass
{
public bool TheMethod ()
{
return true;
}
}

public class TheOtherClass : TheClass
{
new public bool TheMethod ()
{
return false;
}
}

HTH,

--
Tom Shelton
Jan 9 '07 #2

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

Similar topics

2
2688
by: Acer | last post by:
hi, what's the best way to display pictures with an automatic generated shadow ?
5
28578
by: bart plessers | last post by:
Hello, Somewhere in my code I have <input TYPE="button" NAME="btnFirst" VALUE="<<" OnClick="GetFile('1')" DISABLED> I changed the layout of the INPUT with a stylesheet to INPUT { color: #FFFFFF;
5
7435
by: Bill Rust | last post by:
I have a component that needs to access files which exist in the same directory as the DLL containing the component itself. To determine the component's installation directory, I'm using System.Reflection.Assembly.GetExecutingAssembly().Location. This worked fine on my computer, but for another user, it failed because the assembly was being loaded using a shadow copy of the DLL located in a different directory. Is there a way,...
2
1924
by: Alex | last post by:
Is this correct: 1. When the first request for an application on the virtual directory comes in and ASP.NET worker process creates an AppDomain for that particular application, it copies the code-behind(if there is one) to the v1.1.4322\Temporary ASP.NET Files\(appname)\.... 2. For the lifetime of this application the code-behind in the shadow folder is locked.
4
4218
by: Barry Kelly | last post by:
I'm designing an application framework which will, amongst other things, live in an assembly hosted in the ASP.NET worker process, servicing webservice requests. Here's the scenario: APPFX is our application framework assembly. It has no life of its own - it's designed to provide components that are glued together by another, main application assembly - let us call it APP. Thus, APP uses APPFX, and APP is registered with ASP.NET as a...
2
13967
by: Lou | last post by:
I need to have a Face,Outline and drop shadow. I am close but can't get my code to work. The face and outline work fine but the shadow is not sized correctly??? Dim rec As New Rectangle(PictureBox1.Left, PictureBox1.Top, PictureBox1.Height, PictureBox1.Height) Try 'Set the Font
0
3538
by: juglesh | last post by:
Hello, I've searched and d/l'd but cant seem to find a way of creating a semi-transparent drop shadow for an image. Let me say, be fore I go on, I *do not* want one of those scripts that resizes your image a bit to the left and bottom, and then grafts a shadow onto it. I want to use a full shadow (it would be about as big as the image) and shift it a bit with CSS. So, I will have the image sitting in a DIV which will have the shadow as...
6
1811
by: pereges | last post by:
I want to begin by making simple 2D games for Dos. What particular features of C should I look to strengthen ? I am not asking about the graphics bit but in general.
6
2066
by: bravo | last post by:
Hi, select c19,name,c5,count(*) as count,sum(c13) as cost from TableA where c1 like '%' and c5 like '%' and name like 'bravo' and c19 between '2009-01-01 00:00:00' and '2012-01-01 00:00:00' group by date(c19),name,c5 limit 10000 offset 0 i am using mysql version 4.1 and there is a table having 2.5 million records , the table structure is given below.. if i run above select query time taken is 19.33 sec I have some Questions: 1. Is...
0
9719
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
10618
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10366
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
10371
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
9187
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...
1
7649
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6877
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
5678
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4329
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

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.