Ejemplo n.º 1
0
        public string GenerateFileName(string fileType, string fileExtension)
        {
            if (DuplicateFileIdentifier.HasValue)
            {
                return(string.Format("{0}_{1}_{2}_{3:yyyyMMddHHmmss}_{4}.{5}", fileType,
                                     TradingPartnerId.Substring(0, 3), LdcShortName, DateTime.Now, DuplicateFileIdentifier.Value, fileExtension));
            }

            return(string.Format("{0}_{1}_{2}_{3:yyyyMMddHHmmss}.{4}", fileType,
                                 TradingPartnerId.Substring(0, 3), LdcShortName, DateTime.Now, fileExtension));
        }
Ejemplo n.º 2
0
        public string GenerateFileName(string fileType, string fileExtension)
        {
            if (!string.IsNullOrWhiteSpace(FileNamePrefix))
            {
                fileType = string.Concat(FileNamePrefix, "_", fileType);
            }

            if (DuplicateFileIdentifier.HasValue)
            {
                return(string.Format("{0}_{1}_{2}_{3:yyyyMMddHHmmss}_{4}.{5}", fileType,
                                     TradingPartnerId.Substring(0, 3), LdcShortName, DateTime.Now, DuplicateFileIdentifier.Value, fileExtension));
            }

            return(string.Format("{0}_{1}_{2}_{3:yyyyMMddHHmmss}.{4}", fileType,
                                 TradingPartnerId.Substring(0, 3), LdcShortName, DateTime.Now, fileExtension));
        }