Skip to content

Instantly share code, notes, and snippets.

View neo125874's full-sized avatar

Jim neo125874

View GitHub Profile
@neo125874
neo125874 / Fader.cs
Created March 3, 2021 03:17 — forked from nathan-fiscaletti/Fader.cs
A C# class used to control fading forms in and out
using System;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace FormFader
{
/// <summary>
/// An object used to control fading forms in and out.
/// </summary>
class Fader
@neo125874
neo125874 / AESGCM.cs
Created February 9, 2017 01:32 — forked from jbtule/AESGCM.cs
I have two code examples that I wrote for best practices encrypting a string in c#. They are both using authenticated encryption. http://stackoverflow.com/a/10366194/637783
/*
* This work (Modern Encryption of a String C#, by James Tuley),
* identified by James Tuley, is free of known copyright restrictions.
* https://gist.github.com/4336842
* http://creativecommons.org/publicdomain/mark/1.0/
*/
using System;
using System.IO;
using System.Text;
@neo125874
neo125874 / Program.cs
Created July 28, 2016 07:12 — forked from DanielSWolf/Program.cs
Console progress bar. Code is under the MIT License: http://opensource.org/licenses/MIT
using System;
using System.Threading;
static class Program {
static void Main() {
Console.Write("Performing some task... ");
using (var progress = new ProgressBar()) {
for (int i = 0; i <= 100; i++) {
progress.Report((double) i / 100);
@neo125874
neo125874 / Rebundler-with-css-url-rewrite
Last active August 29, 2015 14:17 — forked from spooky/rebundler
bundle files from Dll's content & scripts(For MvcContrib portable area)
public class Rebundler
{
private readonly Assembly assembly;
private readonly string virtualPath;
private readonly HashSet<string> resourceNames = new HashSet<string>();
//constructor
public Rebundler(Assembly assembly, string virtualPath)
{
this.assembly = assembly;