Processing Ajax...

Title

Message

Confirm

Confirm

Confirm

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure?

Remove empty lines

Description
This macro will remove blank lines from the text.
Language
C#.net
Minimum Version
Created By
Keith Lammers (BFS)
Contributors
-
Date Created
Nov 17, 2021
Date Last Modified
Nov 17, 2021

Macro Code

using System;
using System.Collections.Generic;
using System.Text.RegularExpressions;

public static class ClipboardFusionHelper
{
	public static string ProcessText(string text)
	{
		// Replace empty lines (https://stackoverflow.com/a/7647762)
		text = Regex.Replace(text, @"^\s+$[\r\n]*", string.Empty, RegexOptions.Multiline);
		
		// Return the updated text
		return text;
	}
}