Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Reservation Project

Posted on 2006-04-09
3
Medium Priority
?
368 Views
Last Modified: 2010-04-23
I have this vb.net program about Airline Reservation that is due tonight.  I have worked on it about 40 hours already and am completely lost.  I can't get past this part:
--------------------------------
There are three arrays
   1) two dimensional array of strings to maintain a seating chart with passengers names.
   2) two dimensional control array to show available seats on the form.
   3) An array for the waiting list.

There are 10 rows with 4 seats in a row.  I cant get the area to update the text boxes (by colors- green if available, red if not).  I am really stuck and need some SERIOUS help, ASAP....
0
Comment
Question by:slyfist
3 Comments
 
LVL 6

Expert Comment

by:tone28
ID: 16413960
Can you show what your code looks like now?
0
 
LVL 14

Accepted Solution

by:
PockyMaster earned 1500 total points
ID: 16418908
As a possible startoff:

just iterate through your passenger list.

if you want to keep it very simple:
first iterate all your controls and color them red
then iterate all items in your seating chard
if you find a passenger on seat, update the control array on that same index

That pretty much covers your issue i guess
0
 
LVL 2

Expert Comment

by:manojkumarps
ID: 16424910
Hello slyfist,
          As your two dimensional arrays for names and availablility count will be same I dont think there will be much problem for you.

Herein you have to follow a good naming convention to do it simpler. I would recommend you to postfix it with numbers as ctrl0101,ctrl0102 etc for controls. and psg0101,psg0102 for passenger array. The first 2 numbers would be x and second two would be y in the two dimensional arrays.

       Now it will be very easy for you to loop through them.

while looping check the availability.I fpresent colour the control with that number to red. else green.  


Or there is one more way set the tag for the control as the name of the passenger. then loop it and colour it.

Regards,
Manoj
0

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Kernel Data Recovery is a renowned Data Recovery solution provider which offers wide range of softwares for both enterprise and home users with its cost-effective solutions. Let's have a quick overview of the journey and data recovery tools range he…
Suggested Courses

577 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question