Exemple #1
0
        public void SetHeader(ADIFHeader header)
        {
            _header = header;

            // This library only writes one version, so we need to change the header just in case.
            _header.Version = _ADIF_VER;
        }
Exemple #2
0
        public ADIWriter(string filepath, bool append, ADIFHeader header)
        {
            Initialize();

            Open(filepath, append);

            _header = header;

            // This library only writes one version, so we need to change the header just in case.
            _header.Version = _ADIF_VER;
        }
Exemple #3
0
        public ADIWriter(string filepath, bool append, ADIFHeader header)
        {
            Initialize();

            Open(filepath, append);

            _header = header;

            // This library only writes one version, so we need to change the header just in case.
            _header.Version = _ADIF_VER;
        }
Exemple #4
0
        private void Initialize()
        {
            ADIF_VERSION = _ADIF_VER;

            _header = new ADIFHeader();

            _header.ProgramId      = string.Empty;
            _header.ProgramVersion = string.Empty;
            _header.TimeStamp      = null;
            _header.Version        = _ADIF_VER;
            _header.InitialComment = string.Empty;

            _streamer = null;
        }
Exemple #5
0
        private void Initialize()
        {
            ADIF_VERSION = _ADIF_VER;

            _header = new ADIFHeader();

            _header.ProgramId = string.Empty;
            _header.ProgramVersion = string.Empty;
            _header.TimeStamp = null;
            _header.Version = _ADIF_VER;
            _header.InitialComment = string.Empty;

            _streamer = null;
        }
Exemple #6
0
        public void SetHeader(ADIFHeader header)
        {
            _header = header;

            // This library only writes one version, so we need to change the header just in case.
            _header.Version = _ADIF_VER;
        }
        private void ExportADIFile(string path)
        {
            ADIWriter writer = new ADIWriter(path, false);
            ADIFHeader header = new ADIFHeader();

            // This should be counted by the writer.
            int num = _qsoLog.QSOs.Count;

            header.InitialComment = Constants.ADIF_HEADER_COMMENT;
            header.ProgramId = Constants.APPLICATION_NAME;
            header.TimeStamp = DateTime.Now;

            writer.SetHeader(header);

            writer.WriteHeader();

            writer.WriteQSOLinkedList(_qsoLog.QSOs);

            writer.Close();

            MessageBox.Show(string.Format("Records exported: {0}", num), "ADIF Export", MessageBoxButton.OK, MessageBoxImage.Information);
        }