2010年2月28日日曜日
VBScript:テキスト処理
読み込み
---------------------
Option Explicit
Dim objFS
Dim objText
Dim strData
Set objFS = CreateObject("Scripting.FileSystemObject")
Set objText = objFS.OpenTextFile("d:\work\flatindata.txt")
If objText.AtEndOfStream = False Then
strData = objText.ReadAll
WScript.Echo strData
End If
objText.Close
Set objText = Nothing
Set objFS = Nothing
書き込み
---------------------
Option Explicit
Dim objFS
Dim objText
Dim strData
Set objFS = CreateObject("Scripting.FileSystemObject")
Set objText = objFS.CreateTextFile("d:\work\ren013d.txt")
objText.WriteLine "書き込み内容1"
objText.WriteLine "書き込み内容2"
objText.Close
WScript.Echo "2行書き込みました"
Set objText = Nothing
Set objFS = Nothing
---------------------
Option Explicit
Dim objFS
Dim objText
Dim strData
Set objFS = CreateObject("Scripting.FileSystemObject")
Set objText = objFS.OpenTextFile("d:\work\flatindata.txt")
If objText.AtEndOfStream = False Then
strData = objText.ReadAll
WScript.Echo strData
End If
objText.Close
Set objText = Nothing
Set objFS = Nothing
書き込み
---------------------
Option Explicit
Dim objFS
Dim objText
Dim strData
Set objFS = CreateObject("Scripting.FileSystemObject")
Set objText = objFS.CreateTextFile("d:\work\ren013d.txt")
objText.WriteLine "書き込み内容1"
objText.WriteLine "書き込み内容2"
objText.Close
WScript.Echo "2行書き込みました"
Set objText = Nothing
Set objFS = Nothing
VBScript:カレントディレクトリの表示
Option Explicit
Dim objWShell
Set objWShell = CreateObject("WScript.Shell")
WScript.Echo "カレントディレクトリ= " & objWShell.CurrentDirectory
Set objWShell = Nothing
Dim objWShell
Set objWShell = CreateObject("WScript.Shell")
WScript.Echo "カレントディレクトリ= " & objWShell.CurrentDirectory
Set objWShell = Nothing
VBScript:EXcelシートのデータの読み出し
Set objExcel = CreateObject("Excel.Application")
objExcel.Visible = False
Set objWorkbook = objExcel.Workbooks.Open ("C:\Book1.xlsx")
Set objWorksheet = objWorkbook.sheets(1)
intRow = 1
Do Until objWorksheet.Cells(intRow,1).Value = ""
data = objExcel.Cells(intRow,1)
intRow = intRow + 1
WScript.Echo data
Loop
objExcel.Quit
objExcel.Visible = False
Set objWorkbook = objExcel.Workbooks.Open ("C:\Book1.xlsx")
Set objWorksheet = objWorkbook.sheets(1)
intRow = 1
Do Until objWorksheet.Cells(intRow,1).Value = ""
data = objExcel.Cells(intRow,1)
intRow = intRow + 1
WScript.Echo data
Loop
objExcel.Quit
2010年2月14日日曜日
Google App Engine Datastoreオブジェクト保存場所
Windows
C:\Documents and Settings\ユーザ名\Local Settings\Temp\dev_appserver.datastore
C:\Documents and Settings\ユーザ名\Local Settings\Temp\dev_appserver.datastore
登録:
投稿 (Atom)