Click here to Skip to main content
15,867,686 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
AnswerRe: Exe File encoding - http via vb.net Pin
jschell3-Apr-23 6:09
jschell3-Apr-23 6:09 
QuestionBad Programming??... Pin
FreakNeck71631-Mar-23 4:09
FreakNeck71631-Mar-23 4:09 
AnswerRe: Bad Programming??... Pin
Richard Deeming31-Mar-23 4:59
mveRichard Deeming31-Mar-23 4:59 
AnswerRe: Bad Programming??... Pin
Gerry Schmitz31-Mar-23 6:49
mveGerry Schmitz31-Mar-23 6:49 
AnswerRe: Bad Programming??... Pin
Dave Kreskowiak31-Mar-23 12:08
mveDave Kreskowiak31-Mar-23 12:08 
AnswerRe: Bad Programming??... Pin
jschell3-Apr-23 6:42
jschell3-Apr-23 6:42 
AnswerRe: Bad Programming??... Pin
Valley Kid31-Aug-23 19:37
Valley Kid31-Aug-23 19:37 
QuestionUpdate Settings in Winows Forms project Pin
Ron Mittelman27-Mar-23 8:06
Ron Mittelman27-Mar-23 8:06 
I haven't done a c# project in some time, and trying to remember all the things I've forgotten.

I have an application with various application & user settings. I want the user to be able to set those preferences. I figured out how to use a property grid to show settings on the appropriate form:

Properties.Settings mySettings = new Properties.Settings();

private void SettingsForm_Load(object sender, EventArgs e)
{
    this.propertyGrid1.SelectedObject = mySettings;
}

It seems I can't bind the Settings directly to the property grid, I had to create an object from the settings and bind to that. I put the object assignment at form level in case I needed it to update later, but it could also be assigned in the form load event if I don't need to refer to it later.

This shows application settings as disabled and user settings enabled in the property grid, as expected.
Now I want to change a setting and save that back to the actual settings file. I can't seem to find any recent article on how to do that. I found an article from 2009 but it was quite complex, and I feel like that should be simpler in .Net 5.

Did I properly load the property grid?

Is there a way to update all changed user settings in 1 go, or do I need to iterate each property grid item, verify if it was changed, then update the actual setting?

How do I iterate the grid items, skipping categories & disabled items, and put them back into the settings?

Thanks so much for any help....
AnswerRe: Update Settings in Winows Forms project Pin
Gerry Schmitz27-Mar-23 11:48
mveGerry Schmitz27-Mar-23 11:48 
GeneralRe: Update Settings in Winows Forms project Pin
Ron Mittelman27-Mar-23 12:34
Ron Mittelman27-Mar-23 12:34 
GeneralRe: Update Settings in Winows Forms project Pin
Gerry Schmitz28-Mar-23 7:06
mveGerry Schmitz28-Mar-23 7:06 
GeneralRe: Update Settings in Winows Forms project Pin
Ron Mittelman28-Mar-23 11:57
Ron Mittelman28-Mar-23 11:57 
AnswerRe: Update Settings in Winows Forms project Pin
Ron Mittelman28-Mar-23 11:47
Ron Mittelman28-Mar-23 11:47 
GeneralRe: Update Settings in Winows Forms project Pin
Gerry Schmitz28-Mar-23 13:04
mveGerry Schmitz28-Mar-23 13:04 
QuestionASP.NET Core on Linux Web Space Pin
temuco24-Mar-23 3:05
professionaltemuco24-Mar-23 3:05 
AnswerRe: ASP.NET Core on Linux Web Space Pin
jschell27-Mar-23 6:43
jschell27-Mar-23 6:43 
AnswerRe: ASP.NET Core on Linux Web Space Pin
BillWoodruff30-May-23 18:56
professionalBillWoodruff30-May-23 18:56 
GeneralRe: ASP.NET Core on Linux Web Space Pin
temuco30-May-23 23:06
professionaltemuco30-May-23 23:06 
QuestionMy code keeps inserting duplicate records and I can't figure out why. Pin
Ihechi Alozie12-Mar-23 19:53
Ihechi Alozie12-Mar-23 19:53 
AnswerRe: My code keeps inserting duplicate records and I can't figure out why. Pin
Pete O'Hanlon13-Mar-23 0:38
subeditorPete O'Hanlon13-Mar-23 0:38 
GeneralRe: My code keeps inserting duplicate records and I can't figure out why. Pin
Ihechi Alozie13-Mar-23 3:58
Ihechi Alozie13-Mar-23 3:58 
AnswerRe: My code keeps inserting duplicate records and I can't figure out why. Pin
Gerry Schmitz13-Mar-23 7:24
mveGerry Schmitz13-Mar-23 7:24 
GeneralRe: My code keeps inserting duplicate records and I can't figure out why. Pin
Ihechi Alozie13-Mar-23 7:37
Ihechi Alozie13-Mar-23 7:37 
GeneralRe: My code keeps inserting duplicate records and I can't figure out why. Pin
Gerry Schmitz13-Mar-23 9:24
mveGerry Schmitz13-Mar-23 9:24 
AnswerRe: My code keeps inserting duplicate records and I can't figure out why. Pin
Eddy Vluggen13-Mar-23 9:37
professionalEddy Vluggen13-Mar-23 9:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.