Skip to content
David Kittell
David Kittell

Application & System: Development / Integration / Orchestration

  • Services
    • Application Development
    • Online Application Integration
  • Code
  • Online Tools
  • Tech Support
David Kittell

Application & System: Development / Integration / Orchestration

FixedSplit

Posted on February 21, 2013October 26, 2015 By David Kittell
public static string FixedSplit(string s, int len, string delim)
	{
		StringBuilder sb = new StringBuilder(s.Length + (int)(s.Length / len) + 1);
		int start = 0;
		for (start = 0; start < s.Length - len; start += len)
		{
			sb.Append(s.Substring(start, len));
			sb.Append(delim);
		}
		sb.Append(s.Substring(start));
		return sb.ToString();
	}
Originally Posted on February 21, 2013
Last Updated on October 26, 2015
All information on this site is shared with the intention to help. Before any source code or program is ran on a production (non-development) system it is suggested you test it and fully understand what it is doing not just what it appears it is doing. I accept no responsibility for any damage you may do with this code.

Related

Code CSharp

Post navigation

Previous post
Next post

Related Posts

Debian/Ubuntu LAMP Setup

Posted on January 18, 2018January 31, 2019

The following code is for Debian 9 Stretch but should work on older Debian with minor changes Originally Posted on January 18, 2018Last Updated on January 31, 2019 All information on this site is shared with the intention to help. Before any source code or program is ran on a…

Read More

BASH – Picture / Video File Name Manipulation

Posted on August 19, 2023August 17, 2024

Often there are needs to rename a picture or video to help with organizing the files on a computer or in cloud storage. The code below can help to make some organization easier. For those that are not use to the date format used below, it is specifically chosen to…

Read More

Android Contacts – Remove Websites

Posted on March 2, 2014October 26, 2015

DELETE FROM data WHERE mimetype_id IN ( SELECT _id FROM mimetypes WHERE mimetype LIKE "%web%" ) AND data1 LIKE ‘%facebook.com%’; Originally Posted on March 2, 2014Last Updated on October 26, 2015 All information on this site is shared with the intention to help. Before any source code or program is…

Read More

Code

Top Posts & Pages

  • PowerShell - Rename Pictures to Image Taken
  • Front Page
  • C# - Start/Stop/Restart Services
  • MacPorts / HomeBrew - Rip CD tracks from terminal
  • PowerShell - Show File Extensions

Recent Posts

  • Javascript – Digital Clock with Style
  • BASH – Web Ping Log
  • BASH – Picture / Video File Name Manipulation
  • Mac OSX Terminal – Create SSH Key
  • Bash – Rename Picture

Top Posts

  • PowerShell - Rename Pictures to Image Taken
  • C# - Start/Stop/Restart Services
  • MacPorts / HomeBrew - Rip CD tracks from terminal
  • PowerShell - Show File Extensions
  • Open On Screen Keyboard (OSK)
  • SQLite - Auto-Increment / Auto Generate GUID
©2025 David Kittell | WordPress Theme by SuperbThemes