My.Settings.mytext has a value but i cannot find where it is set? - vb.net

onload i do a msgbox (my.settings.mytext)
it returns a value, but i cannot find where in the project i have set this value!! it was definitely set by me, but i cannot find it anywhere. please help
it is attached to textbox1.text, but that has no value either

Please see My.Settings:
The My.Settings object provides access
to the application's settings and
allows you to dynamically store and
retrieve property settings and other
information for your application. For
more information, see Managing
Application Settings.
and also How to: Add or Remove Application Settings:
Application settings allow you to
store and retrieve property settings
and other information for your
application dynamically. There are two
types of application settings, based
on scope: user-scoped and
application-scoped settings.
At design time, you can add
application settings either using the
Settings pane of the Project Designer,
or using the Properties window for a
form or control, which allows you to
bind a setting directly to a property.
This last line that I have emphasized is most likely where you want to look.

Maybe you could goto the Edit menu and do a Quick Find on the Settings name, if it finds it you'll probably find out where you've set the value.
Also, have you checked the Program.vb file? I always forget about that file.
Hope this has helped.

Related

WiX optional Section Content

I am trying to write a simple windows installer that has to write some fields in a .ini file if a feature is enabled. On the lower level, this is if a specific property is set from a checkbox.
I have been googling for days, but neither the internet nor the docs seem to be of help. Can anyone point me in the right direction regarding having optional fields in a section?
All changes to resources on the machine (dir,file,reg,ini and so on) are associated with components. Components are associated to features. So if a feature is being installed, the component is being installed and therefore the resource is being installed.
So you nest an IniFile element underneath a Component element.
https://wixtoolset.org/docs/v3/xsd/wix/inifile/
Checkboxes controll a property. Checked it has a value you specify. Unchecked it has no value.
There's also a little problem that Windows Installer doesn't remember property values for subsequent transactions and that the IniLocator table can only read ini files from the Windows folder.
You might want to store this value in a registry key also that way you can read it back in as part of the remember pattern.
Find my email address and hit me up. I'd be happy to walk you through it as an excercise.

How can I set PhpStorm file structure view to show inherited members by default

How can I set PhpStorm file structure view to show inherited members by default (or change key binding from Ctrl+F12 to show)?
The question pretty much says it all.
I configured file structure to show up with Ctrl+Alt+S, but cannot change the default setting for show inherited and can't change the keys either.
Is there a file, where default non editable configurations are in?
For example there is an xml file under PHPStormRoot\config\keymaps
What would the action be for that?
Is there a plugin for more configurations?
Should I consider writing a plugin myself (would I be able to change such things)?
I found that if you remove the other configurations(ctrl+F12) for opening file structure, show inherited members becomes your keybinding(ctrl+alt+S).
However it can be buggy, won't open until you re open the IDE.
Also you will be delighted to know that if the method you are looking for doesn't exist it will automatically search from inherited members too.
I also removed f12 from my keymap at PHPStormRoot\config\keymaps\$YOURCONFIGFILE.xml
EDIT: Show extra info

Update configuration file vb.net programmatically

I have created a form that shows a number of settings held in the exe.config file, that I would like the user to be able change. For example I have a text box named txtReadServer that I populate with the setting ReadServer in the following manner:
m_ConfigurationForm.txtReadServer.Text = My.Settings.ReadServer
From what I have read on this and other forums, I need to use ConfigurationManager in order to update these setting in the exe.config at runtime. My problem is that when I try anything like the following: Dim config As Configuration = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None) Visual Studio seems to not know what the Configuration object is. I have tried add an Imports System.Configuration at the top of my class, but the word Configuration is still highlighted in the dreaded red!
Any help - or suggestions on the best way to allow users to configure an app would be gratefully received.
Thanks,
Paul.
Add a reference in your project to System.Configuration.

Visual Studio My.Settings

I'm having some issues with MySettings in Visual Studio.
I set up some settings via the GUI (properties menu). Give them names and values. Everything is saved.
Let's say I have a setting: SettingA, Value=123 (User settings)
I go to display SettingA in a textbox on Formload, and nothing happens.
I go to display SettingA in a messagebox on Formload, nothing happens.
After the form loads up, if I code a button to display a setting in a textbox.... it does.
If, in code, I change the value of a setting and save it. Then have it display in a textbox, it will show the proper value.
If I close the app, and start it back up, it will either display nothing..or display an old value.
If I physically change a setting's value myself via the Properties menu of the project, then go to try to get the new value to display on Formload, or via button click.....either nothing will happen or it will still display an older value.
It seems that while the program is running, I can change values in code and have them display properly..whenever I want. After I close the program, I don't see any of the changes made in code reflect in the Properties menu.
This is just making no sense to me. If I physically changed a value myself, why won't it display/why is it still display the old value?
If I'm changing values in code, saving them in code, and then displaying them..why aren't they showing back in the Properties menu?
It's like changes just aren't being fully committed...or they are being read from more than 1 location.
Again, these are User settings.
The only code I have been using really are things like:
txtPort.Text = My.Settings.Port
My.Settings.Port = txtPort.text
My.Settings.Save()
Not necessarily in that order..just showing what I'm using.
It seems that you're changing the setting values during debug and then expecting to see those changes reflected in the development environment.
Here's the thing, the file that you're saving the settings in during debug is a copy of the file that you're working with in visual studio. It cannot affect the values inside of your visual studio project. The settings that you save will still be there the next time you debug only if you did not make any changes in the solution that require a rebuild.
If you want values that you enter via the properties window to show up in the debug then you will have to rebuild the application before debugging.
When you build the application to debug it, you're not running the program out of VS. VS creates an exe to run and runs it while retaining access to it's resources in order to give you feedback about the applications activities.
As nilllzz 7 stated, you can sync the VS Project settings to the settings in your debug files by clicking sync.

Providing help documentation in VB.NET?

I have written up troubleshooting documents for my project and would like them included in my program. I remember in VB6 there was a very easy way to do this with a control, where it already has the help document tree set up on the left and you just set it to point to certain files.
Does something like this exist for .NET? I am aware of the HelpProvider control but as far as I know this just puts in tooltips and opens documents on a button press?
Thanks for any help. :)
To the best of my knowledge no such interface exists in Visual Studio, at least in the express editions that I have installed here. As your investigations showed you, the only way to provide help is to add a HelpProvider to a form and set its HelpNamespace property to your HTM/CHM file. Then on each control you can manually set the HelpKeyword, HelpString and/or HelpNavigator properties. Setting the last option controls how the values of HelpKeyword or HelpString are passed to the external help file.