Пример #1
0
        private static void Main(string[] args)
        {
            ////TODO: Embed dependent dll's into ExcelDnaDoc.exe

            if (args.Length < 1)
            {
                Console.Write("dnaPath not provided.\r\n\r\n" + usageInfo);
#if DEBUG
                Console.WriteLine("Press any key to exit.");
                Console.ReadKey();
#endif
                return;
            }

            string dnaPath = args[0];

            // verify dna file exists

            if (!File.Exists(dnaPath))
            {
                Console.Write("No dna file found at the specified location.");
#if DEBUG
                Console.WriteLine("Press any key to exit.");
                Console.ReadKey();
#endif
            }
            else
            {
                HtmlHelp.Create(dnaPath, excludeHidden: args.Any("/ExcludeHidden".Contains));
            }
        }
Пример #2
0
        private static void Main(string[] args)
        {
            ////TODO: Embed dependent dll's into ExcelDnaDoc.exe

            if (args.Length < 1)
            {
                Console.Write("dnaPath not provided.\r\n\r\n" + usageInfo);
#if DEBUG
                Console.WriteLine("Press any key to exit.");
                Console.ReadKey();
#endif
                return;
            }

            string dnaPath = args[0];

            // verify dna file exists

            if (!File.Exists(dnaPath))
            {
                Console.Write("No dna file found at the specified location.");
#if DEBUG
                Console.WriteLine("Press any key to exit.");
                Console.ReadKey();
#endif
            }
            else
            {
                bool excludeHidden = args.Any(
                    x => x.Equals(
                        @"/ExcludeHidden", StringComparison.OrdinalIgnoreCase) ||
                    x.Equals(@"/X", StringComparison.OrdinalIgnoreCase));

                bool skipCompile = args.Any(
                    x => x.Equals(
                        @"/SkipCompile", StringComparison.OrdinalIgnoreCase) ||
                    x.Equals(@"/S", StringComparison.OrdinalIgnoreCase));

                bool runAsync = args.Any(
                    x => x.Equals(
                        @"/Async", StringComparison.OrdinalIgnoreCase) ||
                    x.Equals(@"/A", StringComparison.OrdinalIgnoreCase));

                HtmlHelp.Create(dnaPath, excludeHidden: excludeHidden, skipCompile: skipCompile);
                Console.WriteLine("Successful");
#if DEBUG
                Console.WriteLine("Press any key to exit.");
                Console.ReadKey();
#endif
            }
        }