New topic: MDI interface
<http://forums.realsoftware.com/viewtopic.php?t=30545> Page 1 of 1 [ 4 posts ] Previous topic | Next topic Author Message Steve Albin Post subject: MDI interfacePosted: Sun Oct 18, 2009 9:42 pm Joined: Mon Feb 20, 2006 4:19 pm Posts: 27 Location: Montclair, NJ In the RB user guide it says the following: Quote:If you deselect Multiple Document Interface, your applicationâs windows will appear alongside other applicationsâ windows (like the REALbasic IDE) and have their own menubars. If your application can open more than one document window, it will launch another copy of itself. My understanding of "launch another copy" means that two distinct processes would be running. This would be fine for apps like Word where each window processes a file on its own. My application uses a database that can be opened by only one executable at a time. Reading this, it seems that my application must be an MDI app because if two copies of my app were launched, each copy would have to open the database and that is not allowed. Am I understanding this correctly? Steve _________________ -- Steve Albin - Montclair, NJ http://www.jazzdiscography.com/ http://www.steve-albin.com/ Top npalardy Post subject: Re: MDI interfacePosted: Sun Oct 18, 2009 10:27 pm Joined: Sat Dec 24, 2005 8:18 pm Posts: 5341 Location: Canada, Alberta, Near Red Deer More or less yes. But one thing you can do is, at app start up, detect that another copy os running and then have the new one tell the existing one to open the document so that one copy of an app can manage more than one document. There's no reason you can't make this work and, in fact, it is what the RB IDE does Open several projects and you do not get several copies of RB running _________________ My web site Great White Software RBLibrary.com REALbasic learning Top Steve Albin Post subject: Re: MDI interfacePosted: Sun Oct 18, 2009 10:49 pm Joined: Mon Feb 20, 2006 4:19 pm Posts: 27 Location: Montclair, NJ So if I understand you correctly, the first launch of the app is the master. All following launches need to communicate with the master for i/o to the database? To make is more plain, my app has two main windows for data entry and a few other windows to enter peripheral data. If I were to switch this app to be a non-mdi app, I'd have to pick one window that is always open and that is the one that allows interface with the database. The other windows would allow data entry, but go through the master window for database i/o? _________________ -- Steve Albin - Montclair, NJ http://www.jazzdiscography.com/ http://www.steve-albin.com/ Top jefftullin Post subject: Re: MDI interfacePosted: Mon Oct 19, 2009 1:25 am Joined: Wed Nov 15, 2006 3:50 pm Posts: 848 Quote:To make is more plain, my app has two main windows for data entry and a few other windows to enter peripheral data. If I were to switch this app to be a non-mdi app, I'd have to pick one window that is always open and that is the one that allows interface with the database. The other windows would allow data entry, but go through the master window for database i/o? There is a clear emphasis on 'the window does this, the window does that' among RAD coders However, there is nothing stopping you having all of the core stuff handled by the APP object, which does not even require a window to appear. You could put all the db handling into a class, and have one instance of the class only. Any window that opens can ask for data from the app or the database object which is global, and display the results as they wish. Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 4 posts ]
-- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
