This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma comment(lib,"advapi32.lib") | |
#include <Windows.h> | |
#include <WinSvc.h> | |
#include <AccCtrl.h> | |
#include <AclAPI.h> | |
#include <stdio.h> | |
int main( int argc, char* argv[] ) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<!-- | |
@tag hta:application | |
@attribute ApplicationName Sets the name of the HTA. | |
@attribute Border [Thick]|Thin|None | |
@attribute BorderStyle [Normal]|Raised|Sunken|Complex|Static | |
@attribute Caption [Yes]|No |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Text; | |
using System.Collections.Generic; | |
using System.Linq; | |
using Microsoft.VisualStudio.TestTools.UnitTesting; | |
using System.DirectoryServices; | |
using System.DirectoryServices.ActiveDirectory; | |
namespace ActiveDirectoryExTest | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Attribute VB_Name = "Module1" | |
Public Sub Update_Pivot_Tables() | |
On Error GoTo Exception | |
Dim sheet As Worksheet, table As PivotTable | |
For Each sheet In ThisWorkbook.Sheets | |
For Each table In sheet.PivotTables | |
Dim newSource As String, sourceType As XlPivotTableSourceType, version As Variant, i As Long | |
i = InStr(1, StrReverse(table.SourceData), "\", vbTextCompare) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @Author Drew Chapin <[email protected]> | |
* @Date 2013-05-03 | |
* | |
* Lists all members of a group and how many days are left until their password expires. | |
*/ | |
#pragma comment(lib, "ActiveDS.lib") | |
#pragma comment(lib, "Oleaut32.lib") | |
#pragma comment(lib, "ADSIid.lib") | |
#include <Windows.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @File GetScreenRes.cpp | |
* @Author Drew Chapin <[email protected]> | |
* @Date 2014-09-17 | |
* | |
* Gets the screen resolution and dock status of the system. | |
*/ | |
#include <iostream> | |
#include <Windows.h> | |
#include <WinUser.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' | |
'' dcftp - Visual BASIC FTP class module based on WinInet API | |
'' | |
'' Author: Drew Chapin | |
'' Date: 2012-10-29 | |
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' | |
Option Explicit | |
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' | |
' WinInet API - Constants |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@ECHO OFF | |
REM Get IP Address from user | |
SET IPADDR= | |
SET /P IPADDR=Enter IP Address (Default 10.58.39.242): | |
IF /I '%IPADDR%'=='' SET IPADDR="10.58.39.242" | |
ECHO Applying IP Address, Subnet Mask, and Default Gateway... | |
NETSH interface ip set address "Local Area Connection" static %IPADDR% 255.255.255.0 10.58.21.254 > nul |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
REM Change to DHCP setting | |
NETSH int ip set address name = "Local Area Connection" source = dhcp | |
REM Renew IP address | |
IPCONFIG /renew | |
REM Set proxy settings | |
REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /V ProxyEnable /T REG_DWORD /D 0 /F | |
REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Connections" /f /v DefaultConnectionSettings /t REG_BINARY /d 46000000a1010000090000001200000031302e35392e3132352e3232353a383038301d00000031302e35382e32312e2a3b31302e35382e33392e2a3b3c6c6f63616c3e000000000100000000000000f0c1fb7723ccca0100000000000000000000000002000000020000000a3a273c000000000000000001008020010000000000000050b226000e0100000000000014001f6880531c87a0426910a2ea08002b30309df80061800000000068007400740070003a002f002f007700770077002e0067006f006f0067006c0065002e0063006f006d002f0000000000c00000001400efbe13ce2fdf17000000000000000000000000000000000000000000000100000000000000000000000000000000050000000b0000002e00000068007400740070003a002f002f007700770077002e0067006f00 |
NewerOlder