473,406 Members | 2,377 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,406 software developers and data experts.

difference between String and string

I notice in my code that is String is typed with an uppercase S it is
coloured light blue in the IDE and if it is typed in the lowercase
string then it is displayed in dark blue.

Can someone explain why this is, and what the difference between these
two versions of string is please.

Nov 10 '06 #1
3 1216
string is a compiler shortcut for System.String. They're the same thing.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Ramuseco Limited .NET consulting
http://www.ramuseco.com

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.

"CCLeasing" <ga**@ccleasing.co.ukwrote in message
news:11**********************@h54g2000cwb.googlegr oups.com...
>I notice in my code that is String is typed with an uppercase S it is
coloured light blue in the IDE and if it is typed in the lowercase
string then it is displayed in dark blue.

Can someone explain why this is, and what the difference between these
two versions of string is please.

Nov 10 '06 #2
string is a C# language keyword. It's usage translates to System.String,
which is the String you are referring to. These are absolutely he same in
C#. You can also use the System.String constructors using "string" notation
as follows: string s = new string('a', 10); or call the static methods of
the System.String class using the "string" keyword.

"CCLeasing" <ga**@ccleasing.co.ukwrote in message
news:11**********************@h54g2000cwb.googlegr oups.com...
>I notice in my code that is String is typed with an uppercase S it is
coloured light blue in the IDE and if it is typed in the lowercase
string then it is displayed in dark blue.

Can someone explain why this is, and what the difference between these
two versions of string is please.

Nov 10 '06 #3
Thankyou

Nov 10 '06 #4

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

Similar topics

26
by: Frank | last post by:
For my website i would like to display the age of my son in years, months, days and hours. For now i manage to get a result for totals. Like the total number of days. This is the beginning: ...
17
by: Nathan Given | last post by:
Hello All, I am trying to debug a broken query. The query uses Left$(,4) instead of Left(,4). What is the difference between the Left() and Left$() functions in Microsoft Access? Thanks!...
12
by: Tee | last post by:
String Builder & String, what's the difference. and when to use which ? Thanks.
6
by: Mark Kamoski | last post by:
Hi Everyone-- Please help. What is the difference between a Field and a Property? Here is the context. In the VS.NET 2002 documentation, in the "String Members" section, we have the...
9
by: Anoj | last post by:
Hi All, is there any performance difference between + and & operator while concating string litrels. which one is better and why?? Thanx
7
by: Bart_D | last post by:
Hi, Can anybody explain me what's the difference between for example: imports system.data implements ICallbackEventHandler inherits System.Web.UI.Page Thanks Bart
7
by: Bruce One | last post by:
What is the difference between String and string in C#? What can u do with string that you cant do with String, vice versa?
6
by: JonathanOrlev | last post by:
Hello everyone, I have a newbe question: In Access (2003) VBA, what is the difference between a Module and a Class Module in the VBA development environment? If I remember correctly, new...
6
by: =?Utf-8?B?SmVmZg==?= | last post by:
I thought this would already be covered here, but my search turned up nothing. In VS2005, if I use "String" to define a new variable/class, it colors it in the Aqua color as it does other...
45
by: anto frank | last post by:
hi friends, is ther any difference in array in c and array in c++?
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: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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,...
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
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,...
0
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...

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.