Skip to content

Instantly share code, notes, and snippets.

@robertchong
robertchong / ReadWriteCsv.cs
Created June 4, 2014 12:27
Reading and Writing CSV Files in C#
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
namespace ReadWriteCsv
{
/// <summary>
/// Class to store one CSV row
/// Source: http://www.codeproject.com/Articles/415732/Reading-and-Writing-CSV-Files-in-Csharp
@robertchong
robertchong / Get-LoggedOnUsers.ps1
Created December 13, 2014 06:02
This script will use the Sysinternals PsLoggedon.exe tool to get the list of users logged onto a workstation or server.The script has a check built in to validate that the computer name belongs to your domain. It will also get the full name of the logged on user back in the result. See https://gallery.technet.microsoft.com/scriptcenter/Get-Logge…
<#
.Synopsis
This script will use the Sysinternals PsLoggedon.exe tool to get the list of users logged onto a workstation or computer
.Description
The script has a check built in to validate that the computer name belongs to your domain. It will also get the full name of the logged on user back in the results.
There is a built in check to ask the operator if they would like to rerun the script.
The script can be used with the parameter PathToPSLoggedon to specify the location of PsLoggedon.exe. Or this can be set to always default to this location.
'* Script name: List All Atributes.vbs
'* Created on: 01/28/2009
'* Author: Andrew J Healey
'* Purpose: Exports all attributes from the user object type within
'* the Active Directory schema.
'* Schema: cscript /nologo "list all attribtues.vbs" > Attributes.csv
'* History: Andrew J Healey 01/28/2009
'* - Created script
'
Option Explicit