目次
選択範囲をMSDNで検索
[編集]
dexplore.vbs
1 |
2 |
3 |
4 |
5 |
6 |
7 | Dim helpexe, helpuri
8 |
9 | helpexe = "C:Program FilesCommon FilesMicrosoft SharedHelpdexplore.exe"
10 | helpuri = "ms-help://ms.vscc.2003/"
11 |
12 |
13 | Dim keyword
14 | keyword = Editor.GetSelectedString(0)
15 | If keyword = "" Then
16 | Editor.SelectWord
17 | keyword = Editor.GetSelectedString(0)
18 | End If
19 | If keyword <> "" Then
20 |
21 | On Error Resume Next
22 | Dim help
23 | Set help = GetObject(, "DExplore.AppObj")
24 |
25 | If Err.Number <> 0 Then
26 | On Error Goto 0
27 | Dim sh, e
28 | Set sh = CreateObject("WScript.Shell")
29 | Set e = sh.Exec(helpexe)
30 |
31 | Do Until sh.AppActivate(e.ProcessID)
32 |
33 | Loop
34 |
35 | On Error Resume Next
36 | Dim i
37 | For i = 0 To 100
38 | Set help = GetObject(, "DExplore.AppObj")
39 | If Err.Number = 0 Then Exit For
40 | Next
41 | On Error Goto 0
42 | End If
43 |
44 | help.SetCollection helpuri, ""
45 | help.Contents
46 | help.DisplayTopicFromF1Keyword keyword
47 | help.SyncIndex keyword, 1
48 | help.IndexResults
49 |
50 | End If