Skip to content

Instantly share code, notes, and snippets.

@conrjac
conrjac / Split string
Created April 15, 2013 11:12
C++ Split String and store in vector
int main()
{
std::string input = "abc,def,ghi";
std::istringstream ss(input);
std::string token;
vector<string> playerInfoVector;
while(std::getline(ss, token, ',')) {
playerInfoVector.push_back(token);
std::cout << token << '\n';
@the-nose-knows
the-nose-knows / MessageBoxEx.cs
Last active June 6, 2018 08:45
RogerB's MessageBoxEx from CODEPROJECT; an include-only extension for MessageBox, supporting a timeout timer
/*
* From author RogerB: https://www.codeproject.com/script/membership/view.aspx?mid=716667
* Code source article: https://www.codeproject.com/articles/7968/messagebox-with-a-timeout-for-net
* Licensing: https://www.codeproject.com/info/cpol10.aspx
*/
using System;
using System.Text;
using System.Runtime.InteropServices;
using System.Security.Permissions;