public frmBetalingenBestand(DataAdapters da)
        {
            InitializeComponent();
            param       = new tblParameters();
            betalingen  = da.VulBetalingRecords();
            dataAdaptor = da;

            _windowState = new PersistWindowState(this, @"Leden\BetalingenBestand");

            PersistControlValue.ReadControlValue(txtFilePrefixB);
            PersistControlValue.ReadControlValue(txtFileSeqnrB);
            PersistControlValue.ReadControlValue(txtMsgIDB);
            PersistControlValue.ReadControlValue(txtOutputLocationIncB);
            PersistControlValue.ReadControlValue(chkPrintVerslagB);

            int     nbrBetalingen = 0;
            decimal sumBetalingen = 0;

            foreach (tblBetaling betaling in betalingen)
            {
                if (betaling.Verstuurd)
                {
                    continue;
                }
                sumBetalingen += betaling.TotaalBedrag;
                nbrBetalingen++;
            }
            lblMessage.Text = "Aantal: " + nbrBetalingen.ToString() + " - Bedrag: " + sumBetalingen.ToEuroString();
        }
        public frmRekeningOverzicht2(DataAdapters da, object l)
        {
            InitializeComponent();
            param        = new tblParameters();
            dataAdaptor  = da;
            _windowState = new PersistWindowState(this, @"Leden\RekeningOverzicht");
            PersistControlValue.ReadControlValue(txtStornoKosten);
            rduStornoBrief.Checked = true;
            SetChangeMode(false);


            cboTypeRekening.Items.AddRange(tblRekening.RekeningTypeDescriptions);

            InitializeDataListView(olvRekeningen);

            #region Create Columns
            OLVColumn dlvc00 = new OLVColumn("Nr", "RekeningSeqNr");
            OLVColumn dlvc01 = new OLVColumn("Datum", "AanmaakDatum");
            OLVColumn dlvc02 = new OLVColumn("Verstuurd", "Verstuurd");
            OLVColumn dlvc03 = new OLVColumn("Storno", "Gestorneerd");
            OLVColumn dlvc04 = new OLVColumn("Omschrijving", "Omschrijving");
            OLVColumn dlvc05 = new OLVColumn("Bedrag", "TotaalBedrag");

            dlvc00.Width = 30;
            dlvc01.Width = 70;
            dlvc02.Width = 30;
            dlvc03.Width = 30;
            dlvc04.Width = 300;
            dlvc05.Width = 60;

            dlvc00.UseInitialLetterForGroup = true;
            dlvc00.HeaderTextAlign          = System.Windows.Forms.HorizontalAlignment.Center;
            dlvc00.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
            //
            dlvc01.UseInitialLetterForGroup = true;
            dlvc01.AspectGetter             = delegate(object row)
            {
                return(((tblRekening)row).AanmaakDatum.ToShortDateString());
            };
            //
            dlvc02.UseInitialLetterForGroup = true;
            dlvc02.CheckBoxes   = false;
            dlvc02.IsEditable   = false;
            dlvc02.TextAlign    = System.Windows.Forms.HorizontalAlignment.Center;
            dlvc02.AspectGetter = delegate(object row)
            {
                if (((tblRekening)row).Verstuurd)
                {
                    return("Verstuurd");
                }
                return("");
            };
            dlvc02.Renderer = new MappedImageRenderer(new Object[] { "Verstuurd", Resources.tick16 });
            //
            dlvc03.UseInitialLetterForGroup = true;
            dlvc03.CheckBoxes   = true;
            dlvc03.IsEditable   = false;
            dlvc03.TextAlign    = System.Windows.Forms.HorizontalAlignment.Center;
            dlvc03.AspectGetter = delegate(object row)
            {
                if (((tblRekening)row).Gestorneerd)
                {
                    return("Gestorneerd");
                }
                return("");
            };
            dlvc03.Renderer = new MappedImageRenderer(new Object[] { "Gestorneerd", Resources.star16 });
            //
            dlvc04.UseInitialLetterForGroup = true;
            dlvc05.UseInitialLetterForGroup = true;
            dlvc05.AspectToStringFormat     = "{0:C}";
            dlvc05.TextAlign = HorizontalAlignment.Right;

            //dlvc16.CheckBoxes = true;
            //dlvc16.HeaderTextAlign = System.Windows.Forms.HorizontalAlignment.Center;
            //dlvc16.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
            //dlvc16.ToolTipText = "Is dit contact toegevoegd via Leden administratie?";

            olvRekeningen.Columns.Add(dlvc00);
            olvRekeningen.Columns.Add(dlvc01);
            olvRekeningen.Columns.Add(dlvc02);
            olvRekeningen.Columns.Add(dlvc03);
            olvRekeningen.Columns.Add(dlvc04);
            olvRekeningen.Columns.Add(dlvc05);

            #endregion

            rekeningen = da.VulRekeningRecords();

            ReportRoutines.CreateRekeningingenReport("Aangemaakte contributie rekeningen", rekeningen, @"D:\temp\zz.csv", true);


            if (l is tblLid)
            {
                leden = new LedenLijst();
                tblLid lid = (tblLid)l;
                leden.Add(lid);
                lboLeden.Items.Add(lid.VolledigeNaam);
            }
            if (l is LedenLijst)
            {
                leden = (LedenLijst)l;

                foreach (tblLid lid in leden)
                {
                    lboLeden.Items.Add(lid.VolledigeNaam);
                }
            }
            lboLeden.SelectedIndex = 0;
            olvRekeningen.SetObjects(rekeningen);
            lboLeden_SelectedIndexChanged(this, null);
            lboLeden.Focus();
        }
        public frmEenmaligeBetaling(DataAdapters da)
        {
            InitializeComponent();
            param       = new tblParameters();
            dataAdaptor = da;
            betalingen  = da.VulBetalingRecords();

            _windowState = new PersistWindowState(this, @"Leden\EenmaligeBetaling");
            PersistControlValue.ReadControlValue(chkFilter);
            SetChangeMode(false);


            cboTypeRekening.Items.AddRange(tblBetaling.BetalingTypeDescriptions);

            InitializeDataListView(olvBetalingen);

            #region Create Columns
            OLVColumn colNaam             = new OLVColumn("Naam", "Crediteur");
            OLVColumn colDatum            = new OLVColumn("Datum", "AanmaakDatum");
            OLVColumn dlvc03              = new OLVColumn("Omschrijving", "Omschrijving");
            OLVColumn dlvc04              = new OLVColumn("End To End Id", "EndToEndId");
            OLVColumn colBedrag           = new OLVColumn("Bedrag", "TotaalBedrag");
            OLVColumn colType             = new OLVColumn("Type", "TypeBetaling");
            OLVColumn colVerwerkingsDatum = new OLVColumn("Verw, Datun", "GewensteVerwerkingsDatum");

            colNaam.Width             = 140;
            colDatum.Width            = 90;
            dlvc03.Width              = 200;
            dlvc04.Width              = 130;
            colBedrag.Width           = 70;
            colType.Width             = 70;
            colVerwerkingsDatum.Width = 90;

            colNaam.UseInitialLetterForGroup   = true;
            colBedrag.UseInitialLetterForGroup = true;
            colBedrag.AspectToStringFormat     = "{0:C}";
            colBedrag.TextAlign = HorizontalAlignment.Right;
            // dlvc03.UseInitialLetterForGroup = true;
            colDatum.Sortable  = true;
            colDatum.TextAlign = HorizontalAlignment.Right;
            colDatum.UseInitialLetterForGroup            = true;
            colVerwerkingsDatum.Sortable                 = true;
            colVerwerkingsDatum.TextAlign                = HorizontalAlignment.Right;
            colVerwerkingsDatum.UseInitialLetterForGroup = true;
            colType.UseInitialLetterForGroup             = true;

            olvBetalingen.Columns.Add(colType);
            olvBetalingen.Columns.Add(colNaam);
            olvBetalingen.Columns.Add(dlvc03);
            olvBetalingen.Columns.Add(dlvc04);
            olvBetalingen.Columns.Add(colBedrag);
            olvBetalingen.Columns.Add(colDatum);
            olvBetalingen.Columns.Add(colVerwerkingsDatum);

            colType.AspectGetter = delegate(object row)
            {
                if (((tblBetaling)row).TypeBetaling == 0)
                {
                    return("Overig");
                }
                return("Overig");  // Voor het geval er nog meer komen :o)
            };

            colDatum.AspectGetter = delegate(object row)
            {
                return(((tblBetaling)row).AanmaakDatum.ToShortDateString());
            };

            colVerwerkingsDatum.AspectGetter = delegate(object row)
            {
                return(((tblBetaling)row).GewensteVerwerkingsDatum.ToShortDateString());
            };

            dlvc04.AspectGetter = delegate(object row)
            {
                return(((tblBetaling)row).FormattedEndToEndId);
            };
            #endregion

            olvBetalingen.SetObjects(betalingen);

            #region Vul Crediteuren
            LedenLijst leden = da.VulLedenLijst();

            CrediteurenLijst crediteuren = da.VulCrediteurenRecords();

            foreach (tblCrediteur cred in crediteuren)
            {
                cboCrediteur.AddRecord(cred.Naam, cred);
            }
            foreach (tblLid lid in leden)
            {
                if (lid.IsIncasso)
                {
                    cboCrediteur.AddRecord(lid.VolledigeNaam, lid);
                }
            }
            cboCrediteur.First();

            #endregion

            // Show the first
            //if (betalingen.Count > 0)
            //    olvBetalingen.Items[0].Selected = true;
            //else
            //    CmdNew_Click(this, null);  // Waarom werkt dit niet:  CmdNew.PerformClick();
        }
Exemplo n.º 4
0
 public frmNotes()
 {
     InitializeComponent();
     _windowState = new PersistWindowState(this, @"Leden\Notes");
     PersistControlValue.ReadControlValue(richTextBox1);
 }
Exemplo n.º 5
0
        public frmCrediteuren(DataAdapters da)
        {
            #region Initialize
            InitializeComponent();
            _windowState = new PersistWindowState(this, @"Leden\Crediteuren");

            dataAdaptor = da;
            param       = new tblParameters();
            crediteuren = da.VulCrediteurenRecords();

            InitializeDataListView(olvVCard);

            PersistControlValue.ReadControlValue(txtOutputLocation);

            #endregion

            #region Create Columns
//            OLVColumn dlvc01 = new OLVColumn("Crediteuren ID", "Crediteur");
            OLVColumn dlvc02          = new OLVColumn("Naam", "Naam");
            OLVColumn dlvc03          = new OLVColumn("IBAN", "IBAN");
            OLVColumn dlvc04          = new OLVColumn("BIC", "BIC");
            OLVColumn colOmschrijving = new OLVColumn("Omschrijving", "Omschrijving");

//            dlvc01.Width = 90;
            dlvc02.Width          = 150;
            dlvc03.Width          = 140;
            dlvc04.Width          = 100;
            colOmschrijving.Width = 200;

//            dlvc01.UseInitialLetterForGroup = true;
            dlvc02.UseInitialLetterForGroup          = true;
            dlvc03.UseInitialLetterForGroup          = true;
            dlvc04.UseInitialLetterForGroup          = true;
            colOmschrijving.UseInitialLetterForGroup = false;
            dlvc04.IsEditable = false;

//            olvVCard.Columns.Add(dlvc01);
            olvVCard.Columns.Add(dlvc02);
            olvVCard.Columns.Add(dlvc03);
            olvVCard.Columns.Add(dlvc04);
            olvVCard.Columns.Add(colOmschrijving);

            dlvc02.AspectPutter = delegate(object row, object newValue)
            {
                ((tblCrediteur)row).Naam = (string)newValue;
            };
            dlvc03.AspectPutter = delegate(object row, object newValue)
            {
                ((tblCrediteur)row).IBAN = (string)newValue;
            };
            colOmschrijving.AspectPutter = delegate(object row, object newValue)
            {
                ((tblCrediteur)row).Omschrijving = (string)newValue;
            };


            //dlvc02.AspectGetter = delegate(object row)
            //{
            //    VCard2 vc = (VCard2)row;
            //    return vc.Voornaam + " " + (vc.Tussen != string.Empty ? vc.Tussen + " " : string.Empty) + vc.Achternaam + "\n" + "twee";
            //};
            #endregion

            olvVCard.SetObjects(crediteuren);
        }
Exemplo n.º 6
0
        public frmCompareNAS(DataAdapters da)
        {
            InitializeComponent();
            dataAdaptor  = da;
            param        = new tblParameters();
            leden        = da.VulLedenLijst();
            _windowState = new PersistWindowState(this, @"Leden\CompareNAS");
            PersistControlValue.ReadControlValue(txtNASteamindeling);
            PersistControlValue.ReadControlValue(txtNASLeden);

            #region Create Columns

            DataGridViewColumn dgvc0 = new DataGridViewTextBoxColumn();
            dgvc0.Name     = "Bondsnummer";
            dgvc0.Width    = 70;
            dgvc0.ReadOnly = true;
            dgvc0.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc1 = new DataGridViewTextBoxColumn();
            dgvc1.Name     = "Naam";
            dgvc1.Width    = 180;
            dgvc1.ReadOnly = true;
            dgvc1.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc2 = new DataGridViewCheckBoxColumn();
            dgvc2.Name     = "CG NAS";
            dgvc2.Width    = 60;
            dgvc2.ReadOnly = true;
            dgvc2.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc3 = new DataGridViewCheckBoxColumn();
            dgvc3.Name     = "CG Admin";
            dgvc3.Width    = 60;
            dgvc3.ReadOnly = false;
            dgvc3.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc4 = new DataGridViewCheckBoxColumn();
            dgvc4.Name     = "Team NAS";
            dgvc4.Width    = 60;
            dgvc4.ReadOnly = true;
            dgvc4.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc5 = new DataGridViewCheckBoxColumn();
            dgvc5.Name     = "LB Admin";
            dgvc5.Width    = 60;
            dgvc5.ReadOnly = false;
            dgvc5.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc6 = new DataGridViewCheckBoxColumn();
            dgvc6.Name     = "LB NAS";
            dgvc6.Width    = 60;
            dgvc6.ReadOnly = true;
            dgvc6.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc7 = new DataGridViewCheckBoxColumn();
            dgvc7.Name     = "Niet in Admin";
            dgvc7.Width    = 60;
            dgvc7.ReadOnly = true;
            dgvc7.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc8 = new DataGridViewTextBoxColumn();
            dgvc8.Name     = "Lic Admin";
            dgvc8.Width    = 60;
            dgvc8.ReadOnly = false;
            dgvc8.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc9 = new DataGridViewTextBoxColumn();
            dgvc9.Name     = "Lic NAS";
            dgvc9.Width    = 60;
            dgvc9.ReadOnly = true;
            dgvc9.SortMode = DataGridViewColumnSortMode.Automatic;

            DataGridViewColumn dgvc10 = new DataGridViewTextBoxColumn();
            dgvc10.Name     = "Email NAS";
            dgvc10.Width    = 180;
            dgvc10.ReadOnly = true;
            dgvc10.SortMode = DataGridViewColumnSortMode.Automatic;


            dgView.Columns.AddRange(new DataGridViewColumn[] { dgvc0, dgvc1, dgvc2, dgvc3, dgvc4, dgvc5, dgvc6, dgvc7, dgvc8, dgvc9, dgvc10 });
            dgView.ReadOnly = false;

            pnlGrid.Width = 930;

            #endregion

            InitializeDataGridView(dgView);
            CreateRows();

            //trigger the updates vanuit de tekstvelden om de eerste vergelijking te maken
            txtNASLeden_TextChanged(this, new EventArgs());
            txtNASteamindeling_TextChanged(this, new EventArgs());

            // activeer de eventhandlers
            dgView.CellValueChanged             += new System.Windows.Forms.DataGridViewCellEventHandler(dgView_CellValueChanged);
            txtNASLeden.TextChanged             += new System.EventHandler(txtNASLeden_TextChanged);
            txtNASteamindeling.TextChanged      += new System.EventHandler(txtNASteamindeling_TextChanged);
            dgView.CurrentCellDirtyStateChanged += new System.EventHandler(dgView_CurrentCellDirtyStateChanged);
        }
Exemplo n.º 7
0
        public frmVCard(object l)
        {
            #region Initialize
            InitializeComponent();
            _windowState = new PersistWindowState(this, @"Leden\ExportVCard");

            param = new tblParameters();

            if (l is DataAdapters)
            {
                leden = ((DataAdapters)l).VulLedenLijst();
            }
            if (l is LedenLijst)
            {
                leden = (LedenLijst)l;
            }

            objVCardList = new List <VCard2>();

            InitializeDataListView(olvVCard);

            PersistControlValue.ReadControlValue(txtOutputLocation);

            #endregion

            #region Create Columns

            int lTel  = 85;
            int lMail = 180;

            OLVColumn dlvc01            = new OLVColumn("Achternaam", "Achternaam");
            OLVColumn dlvc02            = new OLVColumn("Voornaam", "Voornaam");
            OLVColumn dlvc03            = new OLVColumn("Tussen", "Tussen");
            OLVColumn dlvc04            = new OLVColumn("Titel", "Titel");
            OLVColumn ColumnOrganisatie = new OLVColumn("Organisatie", "Organisatie");
            OLVColumn dlvc06            = new OLVColumn("TelThuis", "TelThuis");
            OLVColumn dlvc07            = new OLVColumn("Mobiel1", "Mobiel1");
            OLVColumn dlvc08            = new OLVColumn("Mobiel2", "Mobiel2");
            OLVColumn dlvc09            = new OLVColumn("TelWerk", "TelWerk");
            OLVColumn dlvc10            = new OLVColumn("Email1", "Email1");
            OLVColumn dlvc11            = new OLVColumn("Email2", "Email2");
            OLVColumn dlvc12            = new OLVColumn("Adres", "Adres");
            OLVColumn dlvc13            = new OLVColumn("Postcode", "Postcode");
            OLVColumn dlvc14            = new OLVColumn("Woonplaats", "Woonplaats");
            OLVColumn dlvc15            = new OLVColumn("Notitie", "Notitie");
            OLVColumn dlvc16            = new OLVColumn("Lid", "Lid");

            dlvc01.Width            = 90;
            dlvc02.Width            = 120;
            dlvc03.Width            = 30;
            dlvc04.Width            = 60;
            ColumnOrganisatie.Width = 60;
            dlvc06.Width            = dlvc07.Width = dlvc08.Width = dlvc09.Width = lTel;
            dlvc10.Width            = dlvc11.Width = lMail;
            dlvc12.Width            = 60;
            dlvc13.Width            = 60;
            dlvc14.Width            = 60;
            dlvc15.Width            = 180;
            dlvc16.Width            = 60;

            dlvc01.UseInitialLetterForGroup            = true;
            dlvc02.UseInitialLetterForGroup            = true;
            dlvc03.UseInitialLetterForGroup            = true;
            dlvc04.UseInitialLetterForGroup            = true;
            ColumnOrganisatie.UseInitialLetterForGroup = false;
            dlvc06.UseInitialLetterForGroup            = true;
            dlvc07.UseInitialLetterForGroup            = true;
            dlvc08.UseInitialLetterForGroup            = true;
            dlvc09.UseInitialLetterForGroup            = true;
            dlvc10.UseInitialLetterForGroup            = true;
            dlvc11.UseInitialLetterForGroup            = true;
            dlvc12.UseInitialLetterForGroup            = true;
            dlvc13.UseInitialLetterForGroup            = true;
            dlvc14.UseInitialLetterForGroup            = true;
            dlvc15.UseInitialLetterForGroup            = true;

            //dlvc16.CheckBoxes = true;
            dlvc16.HeaderTextAlign    = System.Windows.Forms.HorizontalAlignment.Center;
            dlvc16.TextAlign          = System.Windows.Forms.HorizontalAlignment.Center;
            dlvc16.ToolTipText        = "Is dit contact toegevoegd via Leden administratie?";
            dlvc16.TriStateCheckBoxes = true;
            //dlvc16.HeaderCheckBox = true;

            olvVCard.Columns.Add(dlvc01);
            olvVCard.Columns.Add(dlvc02);
            olvVCard.Columns.Add(dlvc03);
            olvVCard.Columns.Add(dlvc04);
            olvVCard.Columns.Add(ColumnOrganisatie);
            olvVCard.Columns.Add(dlvc06);
            olvVCard.Columns.Add(dlvc07);
            olvVCard.Columns.Add(dlvc08);
            olvVCard.Columns.Add(dlvc09);
            olvVCard.Columns.Add(dlvc10);
            olvVCard.Columns.Add(dlvc11);
            olvVCard.Columns.Add(dlvc12);
            olvVCard.Columns.Add(dlvc13);
            olvVCard.Columns.Add(dlvc14);
            olvVCard.Columns.Add(dlvc15);
            olvVCard.Columns.Add(dlvc16);

            //dlvc02.AspectGetter = delegate(object row)
            //{
            //    VCard2 vc = (VCard2)row;
            //    return vc.Voornaam + " " + (vc.Tussen != string.Empty ? vc.Tussen + " " : string.Empty) + vc.Achternaam + "\n" + "twee";
            //};



            #endregion

            #region Inlezen XML met contactpersonen
            contactFileNameXML = param.LocationTemplates + @"\ContactPersonen.xml";
            if (contactFileNameXML != string.Empty)
            {
                try
                {
                    using (StreamReader sr = File.OpenText(contactFileNameXML))
                    {
                        using (TextReader tr = new StringReader(sr.ReadToEnd()))
                        {
                            XmlSerializer s = new XmlSerializer(typeof(tblVCard));
                            vCardLijst = (tblVCard)s.Deserialize(tr);
                        }
                    }
                    foreach (VCard vCard in vCardLijst)
                    {
                        vCard.Dirty = true;
                    }
                }
                catch { }
                if (vCardLijst == null)
                {
                    vCardLijst = new tblVCard();
                }
            }

            #endregion

            OntdubbelvCardLijst();
            CopyVCardListToLocal();
            olvVCard.SetObjects(objVCardList);
        }