0

I have a program that needs to display a seating plan for a theatre company. It want it to be able to easily display all of the seats of which there are 420. These are made up by 14 rows with 30 seats in each. I want to be able to save these back into a file. Dat or Inifile, though Inifile would be more hassle free as I already have created for settings. I want to be able to click on the seat that is show on the screen and it bring up all the information about the person who is sitting there, there name and so on. The program must be able to be closed and the data reloaded. I wasn't sure if my best option was to add 420 buttons to a form and write a function for it and then recall it on each button. The buttons will Show Red if taken and Green if available. The data will then be recalled later on to place on the tickets that will be printed. Data should be able to also be entered into the seat, the name of the purchaser, production name, Row, Seat number and so on. What is the most convenient was of doing this?

Matt Biggs
  • 179
  • 1
  • 4
  • 15
  • 3
    write a vcl application that does it :) ...and create the components in run-time – oxo Aug 04 '12 at 06:38
  • I was just about suggesting using a TButtonGroup or TGridPanel when I spotted the Delphi-4 tag. – Uwe Raabe Aug 04 '12 at 08:33
  • 6
    I would simply draw a seating plan on a `TPaintBox` via `TPaintBox.OnPaint` and process mouse clicks via `TPaintBox.OnMouseDown`. – kludg Aug 04 '12 at 08:47
  • @Serg, I like this idea! You could even project the film on there :-) – TLama Aug 04 '12 at 08:50
  • @TLama - yeah, that should be the next question :) – kludg Aug 04 '12 at 08:52
  • 5
    Some advice you did not ask for: If this program works you can count on the theater company going to ask you for extensions: book several shows on different dates, do statistics on past ticket sales etc. That is not going to work if you store your data in some proprietary file structure. If at all possible, store your data in a database as soon as possible. – Jan Doggen Aug 04 '12 at 14:00
  • I suggest lowering your bar. You should learn about databases, and create a simple toy database app first. – Leonardo Herrera Aug 06 '12 at 02:30
  • 2
    @Matt I'm voting to close this as no real question, because your's is overly broad, and this does not have a correct answer. Maybe it belongs to [programmers](http://programmers.stackexchange.com), but not to SO. Please, take a look at [What kind of questions can I ask here](http://stackoverflow.com/faq#questions) and [what kind of questions I should not ask here](http://stackoverflow.com/faq#dontask) in the FAQ for more info. – jachguate Aug 06 '12 at 06:58

0 Answers0