This file contains 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
$header = @("名前", "ほげ", "ふが") | |
$data = @(("name1", "hoge1", "fuga1"), ("name2", "hoge2", "fuga2")) | |
function showindatagrid($data, $header) { | |
Add-Type -AssemblyName PresentationFramework | |
# XAMLからウインドウ作成 | |
[xml]$xaml = @' | |
<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
This file contains 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
function openfolder() { | |
# System.Windows.Formsアセンブリを有効化 | |
[void][System.Reflection.Assembly]::Load("System.Windows.Forms, Version=2.0.0.0, Culture=Neutral, PublicKeyToken=b77a5c561934e089") | |
# OpenFileDialogクラスをインスタンス化し、必要な情報を設定 | |
$dialog = New-Object System.Windows.Forms.OpenFileDialog | |
$dialog.InitialDirectory = "C:\" | |
$dialog.Title = "フォルダを選択してください" | |
$dialog.ValidateNames = 0 # falseに設定 | |
$dialog.CheckFileExists = 0 # falseに設定 |
This file contains 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
<# : | |
@setlocal | |
@set _args_=%* | |
@powershell -noprofile "[ScriptBlock]::Create((${%~f0} | out-string)).Invoke(@(iex('&{$args} ' + $env:_args_)))" | |
@exit /b %errorlevel% | |
#> | |
## 以下スクリプトの内容 ## | |
<# | |
.SYNOPSIS | |
Simple OCR screen capture UI |
This file contains 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
@set args=%* | |
@powershell "iex((@('')*3+(cat '%~f0'|select -skip 3))-join[char]10)" | |
@exit /b %ERRORLEVEL% | |
Try { | |
# 現在時刻取得 (yahoo.co.jp のweb応答Dateヘッダーを利用) | |
#$ret = Invoke-WebRequest "http://www.yahoo.co.jp" -Proxy "x.x.x.x:8080" | |
$ret = Invoke-WebRequest "http://www.yahoo.co.jp" |
This file contains 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 | |
setlocal enabledelayedexpansion | |
echo ■■ パタン1: インターネット(yahoo) | |
set cwd1=%~dp0 | |
set cwd=%cwd1:~0,-1% | |
rem タイムスタンプ YYYYMMDD_hhmmss を取得 |
This file contains 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
import 'package:flutter/material.dart'; | |
//import 'package:flutter/cupertino.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
// This widget is the root of your application. | |
@override |
This file contains 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
<# : by earthdiver1 | |
@echo off | |
cd %~dp0 | |
set BATCH_ARGS=%* | |
setlocal EnableDelayedExpansion | |
set "BATCH_ARGS=!BATCH_ARGS:%%=%%%%!" | |
set "PWSH_ARGS=" & call :quote_args !BATCH_ARGS! | |
Powershell -ExecutionPolicy Bypass -NoProfile -Command "$input|&([ScriptBlock]::Create((gc '%~f0'|Out-String)))" !PWSH_ARGS! | |
endlocal | |
pause & exit/b |
This file contains 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
<# : by earthdiver1 | |
@echo off | |
cd %~dp0 | |
set BATCH_ARGS=%* | |
setlocal EnableDelayedExpansion | |
set "BATCH_ARGS=!BATCH_ARGS:%%=%%%%!" | |
set "PWSH_ARGS=" & call :quote_args !BATCH_ARGS! | |
Powershell -NoProfile -Command "$input|&([ScriptBlock]::Create((gc '%~f0'|Out-String)))" !PWSH_ARGS! | |
endlocal | |
pause & exit/b |
This file contains 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
javascript:(function(){location.href='https://www.google.com/readit?url=%27+encodeURIComponent(location.href)})() |
This file contains 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
## myipcheck.ps1 | |
# グローバルIPをチェックしてメール通知する。 | |
# | |
# globalIPに変化がなくてもメール通知する。 | |
# globalIPに変化があった場合は追加CC先にもメールを送る。 | |
# | |
# このスクリプトを myipcheck.bat から呼び出す場合:: | |
# > powershell -NoProfile -ExecutionPolicy Unrestricted "%~dpn0.ps1" |
NewerOlder