Click here to Skip to main content
15,895,494 members
Home / Discussions / C#
   

C#

 
GeneralRe: NMock expectations producing weird results Pin
N a v a n e e t h6-Jun-08 7:37
N a v a n e e t h6-Jun-08 7:37 
QuestionSuspending a process programmatically, How is that? Pin
LordCover5-Jun-08 3:21
LordCover5-Jun-08 3:21 
QuestionRe: Suspending a process programmatically, How is that? Pin
LordCover5-Jun-08 3:25
LordCover5-Jun-08 3:25 
AnswerRe: Suspending a process programmatically, How is that? Pin
CPallini5-Jun-08 3:29
mveCPallini5-Jun-08 3:29 
GeneralRe: Suspending a process programmatically, How is that? Pin
LordCover5-Jun-08 3:47
LordCover5-Jun-08 3:47 
AnswerRe: Suspending a process programmatically, How is that? Pin
Anthony Mushrow5-Jun-08 3:33
professionalAnthony Mushrow5-Jun-08 3:33 
GeneralRe: Suspending a process programmatically, How is that? Pin
LordCover5-Jun-08 4:50
LordCover5-Jun-08 4:50 
QuestionApplicationSettingBAse Issue Pin
AmithaRaghu5-Jun-08 2:46
AmithaRaghu5-Jun-08 2:46 
I am having a class as below
My settings file is as below
using System;
using System.Windows.Forms;
using System.Drawing;
using System.ComponentModel;
using System.Configuration;
namespace

Core
{
public class FormSettings : ApplicationSettingsBase
{
private static FormSettings _frmSettings = new FormSettings();
[
UserScopedSetting()]
[

DefaultSettingValueAttribute("0, 0")]

public Point FormLocation
{

get { return (Point)(this["FormLocation"]); }

set { this["FormLocation"] = value; }
}

[

UserScopedSetting()]
[
DefaultSettingValueAttribute("0,0")]

public Size FormSize
{


get { return (Size)this["FormSize"]; }

set { this["FormSize"] = value; }
}

[

UserScopedSetting()]
[

DefaultSettingValueAttribute("225, 200")]

public Size RHSPanelSize
{


get {return (Size)this["RHSPanelSize"]; }

set { this["RHSPanelSize"] = value;}
}

[

UserScopedSetting()]
[

DefaultSettingValueAttribute("Vertical")]

public Orientation TabOrientation
{


get { return (Orientation)this["TabOrientation"]; }

set { this["TabOrientation"] = value; }
}


public static Outpost.Core.FormSettings MyFormSettings
{


get { return _frmSettings; }
}


public static void SaveOrientation(string p, Orientation orientation)
{

MyFormSettings.SettingsKey = p.TrimEnd();

Outpost.Core.

FormSettings theSettings = (FormSettings)MyFormSettings;
theSettings.TabOrientation = orientation;

MyFormSettings.Save();

}
public static Orientation GetOrientation(string p)
{

MyFormSettings.SettingsKey = p.TrimEnd();

Outpost.Core.

FormSettings theSettings = (FormSettings)MyFormSettings;

return theSettings.TabOrientation;
}

}

}



And from my control having a tab,i am calling the method

this._dashboardPage.Orientation = Core.FormSettings.GetOrientation(this._dashboardPage.Name);
I dont seem to get the actual value,But i only get the default.I see the config and the correct values were saved.

What am i doing wrong???
Please help

Thanks

A
QuestionWCF plugin for VS 2005 Pin
priy@5-Jun-08 1:18
priy@5-Jun-08 1:18 
AnswerRe: WCF plugin for VS 2005 Pin
#realJSOP5-Jun-08 2:45
mve#realJSOP5-Jun-08 2:45 
AnswerRe: WCF plugin for VS 2005 Pin
teejayem5-Jun-08 3:22
teejayem5-Jun-08 3:22 
Questiona question about kernel32.dll and user32.dll Pin
Sajjad Izadi5-Jun-08 1:16
Sajjad Izadi5-Jun-08 1:16 
AnswerRe: a question about kernel32.dll and user32.dll Pin
leppie5-Jun-08 1:20
leppie5-Jun-08 1:20 
Question[Message Deleted] Pin
vinay_K5-Jun-08 0:51
vinay_K5-Jun-08 0:51 
AnswerRe: GDI+ in C# Pin
leppie5-Jun-08 1:15
leppie5-Jun-08 1:15 
General[Message Deleted] Pin
vinay_K5-Jun-08 2:18
vinay_K5-Jun-08 2:18 
GeneralRe: GDI+ in C# Pin
#realJSOP5-Jun-08 2:46
mve#realJSOP5-Jun-08 2:46 
GeneralRe: GDI+ in C# Pin
Anthony Mushrow5-Jun-08 3:02
professionalAnthony Mushrow5-Jun-08 3:02 
AnswerRe: GDI+ in C# Pin
Gareth H5-Jun-08 1:16
Gareth H5-Jun-08 1:16 
GeneralRe: GDI+ in C# Pin
leppie5-Jun-08 1:17
leppie5-Jun-08 1:17 
AnswerRe: GDI+ in C# Pin
Anthony Mushrow5-Jun-08 1:17
professionalAnthony Mushrow5-Jun-08 1:17 
QuestionHow can I add new record in database using datagrid? Pin
rmedo5-Jun-08 0:49
rmedo5-Jun-08 0:49 
AnswerRe: How can I add new record in database using datagrid? Pin
Tamimi - Code5-Jun-08 2:52
Tamimi - Code5-Jun-08 2:52 
Questionproblem with TCP connection [modified] Pin
johland5-Jun-08 0:49
johland5-Jun-08 0:49 
AnswerRe: problem with TCP connection Pin
#realJSOP5-Jun-08 2:49
mve#realJSOP5-Jun-08 2:49 

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.