trying to incorporate saving and loading of sessions
I'm creating a desktop application using visual studio express 2012, and I'm trying to make it possible for the user to save their session, and then load it again after the program has been re-opened. I learned about the propertybag object, but when I type public propertybag1 as new propertybag, it says type propertybag is not defined. I also tried to import certain references to get it to work, but without any luck. Is there someway I can use the propertybag object, or is there an alternative and easy way of preserving and loading data between instances? Thanks for any suggestions.
Re: trying to incorporate saving and loading of sessions
Welcome to VBForums :wave:
Thread moved from the 'VB6 and Earlier' forum to the 'VB.Net' (VB2002 and later) forum
Re: trying to incorporate saving and loading of sessions
Re: trying to incorporate saving and loading of sessions
Thanks si_the_geek. And dunfiddlin, thanks as well. I'll look into that and let you know how it goes.
Re: trying to incorporate saving and loading of sessions
Quote:
Originally Posted by
dunfiddlin
The thing is, I want more than one session to be able to be saved at any given time, and for the user to be able to load any of those sessions from a sessions list on the main menu. So there would have to be new settings that are uniquely identified, that are added during runtime, representing an additional saved session. If user scope settings can only be added at design time as I think they are, as opposed to run time, I don't think my.settings will work for me (unless I limit the number of sessions the user can save at any given time which I'd rather not do). Is there a way to add/remove user scope settings during run time, as opposed to just changing and reading from already existing ones?
Re: trying to incorporate saving and loading of sessions
In that case you've really little choice but to save to file in some form or integrate a database. Both have pros and cons so you just need to work out what's going to be most suitable.
Re: trying to incorporate saving and loading of sessions
I think I've found a way to make it happen. Thanks