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
Ryan
NA
2
0
incrumenting and outputting an array value
Nov 4 2006 3:49 AM
Hi everyone, I've got a problem with a console application I'm trying to build. I have two values, x and y which are set. The x and y values are changing every 0.5 of and being outputted to a console screen with an "*" zipping round the screen. I'm trying to store the x and y co-ordinates in an array so that more asteriks can be added to the array by incrumenting the values by plus or minus to allow one asteriks to follow another on screen Here is the code I have produced so far: int[] sLengthX = new int[4];//set length of the asteriks x value int[] sLengthY = new int[4];//set length of the asteriks y value for (int i = 0; i < sLengthY.Length; i++) //Loop to make longer { Console.Clear(); x = x + xSpeed; int sIntLengthX = x; sLengthX[i] = (sIntLengthX); y = y + ySpeed; int sIntLengthY = y; sLengthY[i] = (sIntLengthY); for(int j=0; j > 5; j++)//loop round to create length of 5 asteriks with cursor position set { Console.SetCursorPosition(sLengthX[i] + "," + sLengthY[i]); Console.Write("*"); } Thanks for the help
Reply
Answers (
0
)
Can I store but not display data when i'm using a listview?
Dynamic DataGrid