^_^
@MaxySpark
I made a script to download song from a text file using nodejs
I am beginner so there may be some bug :p
Hope you will like it :D
https://github.com/MaxySpark/Song-Playlist-Downloader-NodeJS
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Diagnostics;
using System.Threading;
namespace MyFirstChatBot
{
class Program
{
static void Main(string[] args)
{
bool shutdown = false;
bool foundResponse;
string inputValue;
string outputValue = "";
Console.ForegroundColor = ConsoleColor.Green;
Console.WriteLine("Computer: Hello Friend!");
Console.WriteLine("");
Console.ResetColor();
while (!shutdown)
{
foundResponse = false;
Console.ForegroundColor = ConsoleColor.White;
Console.Write("User: ");
inputValue = Console.ReadLine().ToLower();
Console.WriteLine("");
Console.ForegroundColor = ConsoleColor.Green;
Console.Write("Computer: ");
switch (inputValue)
{
case "hello":
outputValue = "I've already said Hello.";
foundResponse = true;
break;
case "bye":
outputValue = "Good bye";
foundResponse = true;
break;
case "notepad":
Process ExternalProcess = new Process();
outputValue = ExternalProcess.StartInfo.FileName = "Notepad.exe";
foundResponse = true;
ExternalProcess.StartInfo.WindowStyle = ProcessWindowStyle.Maximized;
ExternalProcess.Start();
ExternalProcess.WaitForExit();
break;
}
}
if (foundResponse)
{
Console.WriteLine(outputValue);
}
else
{
Console.WriteLine("Found no response.");
}
Console.WriteLine("");
Console.ResetColor();
}
}
}
}