I am trying to save settings on close I have the following code
[Code]...
I have edited the control properties of the checkBox and bound the checkBox with settings value under application settings when I load the form the checkBox is always checked = false ? what have I done wrong?
I set up some application settings for checkboxes on an app and then decided to remove them. When I set the Application Settings to (none) in the designer and restarted the app, the checkbox constantly checks and unchecks itself. I completely remade the app and removed the file that is used to store my.settings in the Local folder of the user's appdata profile. I also made sure to uncheck the "save my.settings" on shutdown.
What is the correct way to handle saving user control settings on form close. I have a tabcontrol that a user can add tabpages during runtime. The user control has a few controls (listbox,combobox,textbox) How can I save the created tabpages and the data in each control in the usercontrol? Below is how I am calling my usercontrol
Code Public Class TabPageEx Inherits System.Windows.Forms.TabPage
[code]....
I seem to be a little lost as most documentation seems to suggest that I can not save usercontrol settings in the app.config. I have played around with the solution expl. settings tab without much success. But, then again I may be going about it all wrong. So, I am looking for a little direction on the best way to handle this on form close.
I created a form and a checkbox with default name in visual basic 2008 as i move mouse wheel, i can choose a picture for background image i can also change the checkbox's forecolor when i press any key on the keyboard and my first problem is i want to save the new background image which i has already chosen as i close my form and so does the checkbox's forecolor,move the checkbox to wherever i like and save this setting?
E.g. default setting for serial port after start up is COM1. If user sets COM2 and restarts program, is it possible to store port setting, COM2, other than still start from COM1?
This is the first time that I will have ever actually published a program and I have a question about when it goes into 'real use' Right now I have string variables that sets the values of a few text boxes that can be edited and 'saved' (the variable values change to the new input).
When I publish the program will these values be saved in the variables after the program is closed then re-opened? Or is everything reset when the program is restarted? And if it is all reset, is there anything internal (aka not a xml file or something) that will hold the data and keep the changes?
I have combobox I need settings saved when user clicks save settings button and I have add by number box I need settings saved on basicly its set on 50 but some users can change value up to 500 so I want it so that can also save settings and thats it
I was thinking adding this but I know it will be wrong
me.combobox1.SaveSettings() or me.nudResultsToShow.Settings.Save()
I just wondered if you can or can't save arrays using the settings system object. There seems to be no way of entering it at designtime. It seems implied you cannot create new user settings.subobjects at runtime. I'm looking to find the easiest way to save a populated array of PictureBox's. If the only way is a self/custom made/managed .ini file then I need to know so i can start on that but I was hoping to use some of all this phaff in the new frameworks usefully.
i have created a user setting named 'setmeup' as string, scope = user, value = "magical meow meow!".in my code i access it and assign it a new value like this...my.settings.setmeup = "howdy cowboy!"my.settings.save()application.restart()when the application restarts, i expect the my.settings.setmeup = "howdy cowboy!" but when i check its contents its still "magical meow meow!".but when i use application.exit() instead of application.restart() and manually restart the program, my.settings.setmeup = "howdy cowboy!" which is correct.what must i do? i want to use application.restart() because i don't want the users to double-click the icon again to start the program. i want the program to restart automatically.
i had this working and i foudn the info on this forum, but i cant for the life of me renemebr how to do it, and searching for the thread all i can find is this:
[URL]
Which is not it, the method i used only involved a few clicks per item to set up and it made it so what ever selection was chosen in a combobox for example was saved, and then that selection was loaded on the apps next run, i know i had to do something in the application setting/databinding area of the properties.
trying to save the settings in a settings form but every time m setting the settings (when the form is running) then exiting it and then reopening itare the settings that i setted not there Ex : I open form2 by clicking on a button thought form1 and change the settings for example i uncheck a checkbox then do i close form2 and then open it again. And the settings should be saved so the unchecked checkbox should still be unchecked.BUT when i close form1 should the settings be unsaved and go back to normal :)
i've been busy with a program and it has worked out quite well. The only thing I still want is that it is possible to customize things and save that in a text file. Normally if i want an other background for one day, i need to change it in VB or make a checkbox to do that. if i then restart the program all the settings are lost and i have to set it again. so i was wondering if the program can make a text file and put codes like 1 for theme 1 and 2 for theme 2 etc. in it, then save it and load that file when it starts up again. and is this also possible for a login form? if yes, i can also add a "Create Account" button for my program instead of adding codes in VB.
I'm trying to save a setting that keeps what background image I'm currently using.If it's an external file, there is no problem, i can just get the .location and set it in a String setting to store it.
But, if I want to store an image resource as a setting, how do i do it?I know i can store rawdata, like bitmap information, but then i can't set that type of data to the my.background.
I don't know if the question should be: "how do i reference resources", but the my.resources.resource.methodsList doesnt contain anything that seems to be of use.
I'm making a program and in which the user can select a background image from their computer, but I have not found a way to save the picture to my.settings or my.resources
I need code that will allow the user to do the following:
Select a browse button and choose the folder they want to save a file once the exe file at the end of the program runs Display the folder location the user selected in the textbox next to it
Basically this is a save dialog box but since this is a web application and not a web form I can not use the dialog boxes.
Here is the code I have so far
Protected Sub Browse_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Browse.Click Dim FilePath As String = ("C:UsersPublicDocuments")
I need code that will allow the user to do the following:
1. Select a browse button and choose the folder they want to save a file once the exe file at the end of the program runs
2. Display the folder location the user selected in the textbox next to it Basically this is a save dialog box but since this is a web application and not a web form I can not use the dialog boxes.
Protected Sub Browse_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Browse.Click Dim FilePath As String = ("C:UsersPublicDocuments") Dim targetFile As System.IO.FileInfo = New System.IO.FileInfo(FilePath)
I am writing a program that should allow the user to press a browse button to browse their directory and save a text file with the form information they wrote in.
I'm trying to save a collection of key/value settings in my application's "user settings" (they're column widths), but while I see no errors, when I run the code (in the IDE) my collection in "My.Settings" is always nothing at startup. I do a "My.Settings.Save" when the application exits, and barring the "serializers not found" errors in the IDE, no other errors occur. When I run my application as an exe, it behaves the same way..
Dim fileList As Collections.ObjectModel.ReadOnlyCollection(Of String) = My.Computer.FileSystem.GetFiles(FolderDialog1.SelectedPath, FileIO.SearchOption.SearchTopLevelOnly) For Each topLvlFile As String In fileList
[code]....
The above code reads all the files & directories in a selected path. It ignores any hidden folders, like it suppose to. Except it doesn't ignore folders inside of the hidden folders that it finds & I need it to.I can't quite wrap my head around how to make it ignore all folders & files inside of a hidden folder that it find.
I am rewritting my application to conform to ms standards. We used to save all settings to registry for user settings, servername, size and locations.so we are now saving them into My.Settings app.config the only problem is that each time there is an update clickonce will isntall the newupdate but now all settings are loist and user has to save everything all over again..
I am trying to follow the book here but it seems i keep getting stuck somewhere. registry has worked fine for years but i understand we must move on, but if stuff like this happens then i just wasted a long time converting all code to conform for it to not work..
I have set up a notify icon for my form. I want to make it so that when the user clicks the close button that it doesn't close the form it just takes it to shows the notify icon. They can exit the program from the notify icon. Can someone tell me how to keep it running?