[Gtk-sharp-list] Empty Properties from GUI
Baltasar GarcĂa Perez-Schofield
baltasarq at gmail.com
Sat Feb 4 09:53:23 UTC 2017
Hi, Sascha,
> Currently i'm putting input to the properties in Glade.cs:
>
> PublicationTitle = entryTitle.Text;
>
> Environment = cboEnvironment.ActiveText;
>
> DocType = cboDocType.ActiveText;
>
> Language = entryLanguage.Text;
>
> In GetConfig.cs it reads the App.config and connects them to the
> properties and gives out all properties on the terminal.
> But it looks like the PublicationTitle, Environment, DocType and Language
> are empty.
>
>
You're not connecting PublicationTitle, Environment or DocType to anything.
In getconfig.cs:
==
public static string PublicationTitle { get; set; }
public static string Environment { get; set; }
public static string DocType { get; set; }
...
var dictionary = new Dictionary<string, string>()
{
{"PublicationTitle", PublicationTitle},
{"DocType", DocType},
{"Environment", Environment},
{"Language", Language},
{"Firstname", Firstname},
{"Surname", Surname},
==
Those are the only apparitions of that properties in the class. Yes, the
other properties have data, since they are loaded from an XML file.
As far as I understand your project, you should create an instance of
GetConfig inside Glade, and when the "Run publication" button is pressed,
you should store that properties in GetConfig so they can have a value.
===
var config = new GetConfig();
config.PublicationTitle = PublicationTitle;
config.DocType = DocType;
condig.Language = Language;
===
-- Baltasar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: twitter.png
Type: image/png
Size: 1418 bytes
Desc: not available
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0006.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: spacer.gif
Type: image/gif
Size: 1097 bytes
Desc: not available
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0001.gif>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: facebook.png
Type: image/png
Size: 956 bytes
Desc: not available
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0007.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: linkedin.png
Type: image/png
Size: 1141 bytes
Desc: not available
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0008.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: skype.png
Type: image/png
Size: 1632 bytes
Desc: not available
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0009.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: github.png
Type: image/png
Size: 2345 bytes
Desc: not available
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0010.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: xing.png
Type: image/png
Size: 2636 bytes
Desc: not available
URL: <http://lists.dot.net/pipermail/gtk-sharp-list/attachments/20170204/cca99cce/attachment-0011.png>
More information about the Gtk-sharp-list
mailing list