Example #1
0
        // shows the form in edit modus
        // links:
        //  docLink: http://sql2x.org/documentationLink/49afd26c-4f21-4992-967b-be190eacef77
        public void ShowAsEdit(string linkTypeRcd, System.Guid userId)
        {
            var service = new CrudeLinkTypeRefServiceClient();

            _isNew = false;
            try {
                _contract                   = service.FetchByLinkTypeRcd(linkTypeRcd);
                textBoxLinkType.Text        = _contract.LinkTypeRcd;
                textBoxLinkTypeName.Text    = _contract.LinkTypeName;
                _contract.UserId            = userId;
                _contract.DateTime          = DateTime.UtcNow;
                dateTimePickerDateTime.Text = _contract.DateTime.ToString();

                Show();
            } catch (Exception ex) {
                if (ex == null)
                {
                }
                else
                {
                    System.Diagnostics.Debugger.Break();
                }
            } finally {
                service.Close();
            }
        }