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
Name Value | |
---- ----- | |
PSVersion 5.1.17134.165 | |
PSEdition Desktop | |
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...} | |
BuildVersion 10.0.17134.165 | |
CLRVersion 4.0.30319.42000 | |
WSManStackVersion 3.0 | |
PSRemotingProtocolVersion 2.3 | |
SerializationVersion 1.1.0.1 |
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
private string GetSenderSMTPAddress(Outlook.MailItem mail) | |
{ | |
string PR_SMTP_ADDRESS = | |
@"http://schemas.microsoft.com/mapi/proptag/0x39FE001E"; | |
if (mail == null) | |
{ | |
throw new ArgumentNullException(); | |
} | |
if (mail.SenderEmailType == "EX") | |
{ |
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
// ルートオブジェクト内変数列挙 | |
// => WScript と WSH が表示される | |
(function(o){ | |
for ( var k in o ) | |
WSH.Echo(k); | |
})(this); | |
// 同じ物か判定 | |
WSH.Echo( | |
WSH === WScript ? |
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
\.(?:csv|ods|xla|xlam|XLL|xls|xlsb|xlsm|xlsx|xlt|xltm|xltx) |
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
Officeの色の16進数表記 | |
__BBGGRR | |
一般的な色の16進数表記 | |
__RRGGBB |
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
R : 85 | |
G : 197 | |
B : 0 | |
A : 255 | |
IsKnownColor : False | |
IsEmpty : False | |
IsNamedColor : False | |
IsSystemColor : False | |
Name : ff55c500 |
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
Sub VariableSaveTest() | |
Dim tmpPath As String | |
tmpPath = Environ$("tmp") & "\vba_temp.bin" | |
Dim saveData As Variant | |
saveData = Array(1024, "abc", Now) | |
'保存 | |
SaveVariable tmpPath, saveData |
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
'Instance JScript Function object | |
'e.g. | |
'Dim adder As Object: Set adder = JSFunc("a,b", "a+b") 'autoReturn = True | |
'Debug.Print adder(2, 6) '->8 | |
'Dim inRange As Object | |
'Set inRange = JSFunc("range,min,max", "v=range.Value;return min<=v&&v<=max;", False) 'autoReturn = False | |
'Excel.ActiveCell.Value() = 150 | |
'Debug.Print inRange(Excel.ActiveCell, 100, 200) '->True |
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
ActiveCell.Value = Split("001", "") '->String(0 To 0) |
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
''' <summary> | |
''' srcTableの各行を見出しをKeyとするDictionaryへ変換し | |
''' Collectionへ格納します。 | |
''' </summary> | |
''' <param name="srcTable">変換するテーブル。</param> | |
''' <returns>Scripting.Dictionaryを要素とするVBA.Collection</returns> | |
Function TableToDictionaries(ByVal srcTable As Excel.ListObject) As VBA.Collection | |
'テーブルからデータをメモリ上にロード |