Hi
Since i have not yet been able to learn MVC .I thought of reading data from text files as a method of passing information amongst various sub components.Also i have still not figured out how to make a simple frame within a frame.I read Making Simple apps,but i am not in a position to create a simple app for it.Is it possible that instead of storing and reading data in text files,i do that with RAM
I recommend the pubsub module for passing information among components in an application. Here are a couple of links:
http://wiki.wxpython.org/PubSub
http://wiki.wxpython.org/Controlling%20GUI%20with%20pubsub
Hope that helps!
···
On Thu, Oct 15, 2009 at 9:50 AM, nipun batra nipunreddevil@gmail.com wrote:
Hi
Since i have not yet been able to learn MVC .I thought of reading data from text files as a method of passing information amongst various sub components.Also i have still not figured out how to make a simple frame within a frame.I read Making Simple apps,but i am not in a position to create a simple app for it.Is it possible that instead of storing and reading data in text files,i do that with RAM
Mike Driscoll
Blog: http://blog.pythonlibrary.org
nipun batra wrote:
Since i have not yet been able to learn MVC.
MVC aside, you have two separate issues:
1) Notification of events -- wx.lib.pubsub, or regular old wx Events and things like wx.CallAfter().
2) sharing data -- there is certainly no reason to use files for this within the same app. One of the easiest ways to get "global" data sharing:
import Amodule
Amodule.somedata = "this is some data"
Now you can import Amodule anywhere, and .somedata will be there.
-Chris
···
--
Christopher Barker, Ph.D.
Oceanographer
Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chris.Barker@noaa.gov