TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Kelvin Loke
NA
22
0
array problem
Jun 1 2007 9:38 AM
Hi,I´m new with C# and I need to create a global array, but I´m doing something wrong.. This is how I create the global array.. public class MyClass { int i = 0; int[] vrgb = new int[3000]; public static int[] RGB { get { return vrgb[i]; } set { vrgb[i] = value; } } } This is how I call it: int i; i = Program.Indice; int[] contenedor; contenedor = RGBvector.MyClass.RGB; contenedor[i] = ValorRojo; RGBvector.MyClass.RGB = contenedor[i]; note that Valor rojo = int. can anyone help me? the errors I get are: 1.cannot implicitly covert int to int[] 2.Error 4 An object reference is required for the nonstatic field, method, or property 'RGBvector.MyClass.vrgb' Thank you very much.
Reply
Answers (
1
)
values from database
Method call