ÒõÑôʦios½Å±¾ÃâÔ½ÓüÊÚȨģ¿é
¡¡¡¡(3)¸÷¿Ø¼þÊôÐÔÉèÖãº
¡¡¡¡Timer1µÄEnabledÉèÖÃΪTrue;
¡¡¡¡Label1µÄCaptionÉèÖÃΪÐèÉÁ˸µÄ×ÖÌ壺¡°½Î÷Ê¡Àè´¨ÏØÖ°ÒµÖÐרµçÄÔÊÒÉè¼Æ¡±¡¢
FontÉèÖÃ×ÖÌå¼°´óС¡¢BackstyleÉèÖÃΪ¡°0£Transparent¡±£»
¡¡¡¡Command1ÖеÄCaptionÉèÖÃΪ¡°Í˳ö¡±'************************************************
'File:Dialog.vbs(WSHsampleinVBScript)
'Author:(c)G.Born
'
'Usingtheshelldialogboxtoselectafolder
'************************************************
OptionExplicit
'Flagsfortheoptionsparameter
ConstBIF_returnonlyfsdirs=&H0001
ConstBIF_dontgobelowdomain=&H0002
ConstBIF_statustext=&H0004
ConstBIF_returnfsancestors=&H0008
ConstBIF_editbox=&H0010
ConstBIF_validate=&H0020
ConstBIF_browseforcomputer=&H1000
ConstBIF_browseforprinter=&H2000
ConstBIF_browseincludefiles=&H4000
Dimwsh,objDlg,objF
'GetApplicationobjectoftheWindowsshell.
SetobjDlg=WScript.CreateObject("Shell.Application")
'UsetheBrowseForFoldermethod.
'Forinstance:SetobjF=objDlg.BrowseForFolder_
'(&H0,"Selectthefoldertocopy",&H10,"C:\Born")
SetobjF=objDlg.BrowseForFolder(&H0,_
"Selectthefoldertocopy",_
BIF_editbox+BIF_returnonlyfsdirs)
'Hereweusethefirstmethodtodetecttheresult.
IfIsValue(objF)Then
MsgBox"Selectedfolder:"&objF.Title
Else
MsgBox"Canceled"
EndIf
'HereweuseTypeNametodetecttheresult.
IfInStr(1,TypeName(objF),"Folder")>0Then
MsgBox"Selectedfolder:"&objF.Title
Else
MsgBox"Canceled"
EndIf
FunctionIsValue(obj)
'Checkwhetherthevaluehasbeenreturned.
Dimtmp
OnErrorResumeNext
tmp=""&obj
IfErr<>0Then
IsValue=False
Else
IsValue=True
EndIf
OnErrorGoTo0
EndFunction
'***End

WScript.Quit
ElseIf Not objFSO.FolderExists(tmpPath) Then
WScript.Echo "Error£º´íÎóµÄ·¾¶¡°" & tmpPath & "¡±
- ÆäËû¿Ø¼þMicrosoftCommonDialogControl,Version6.0
- ÔÚ´°ÌåÉÏÐγɶԻ°¿ò¿Ø¼þ
- Ð޸ĿؼþµÄÃû³ÆÈ磺Dialog1
- ÉèÖÃÆäÊôÐÔ£ºÔÚ¶Ô»°¿òÉϵ¥»÷ÓÒ¼üCommonDialog¶ÔÏóµÄÊôÐÔµ¯³öÊôÐÔ¶Ô»°¿ò£¨ÈçÏÂͼ£©
¡¡¡¡Dim uMaMe
¡¡¡¡Do While (strReturn <> "ÎÒÊÇÖí") 'Ñ»·Óï¾ä£¬Ö±µ½±äÁ¿ strReturn µÈÓÚ ¡°ÎÒÊÇÖí¡± ʱÍ˳öÑ»·
ÎÒÃÇ¿ÉͨѶȡµÃMSCOMM1.INPUTÖеÄÄÚÈݿɼì²âÊÇ·ñÒѽ¨Á¢ºÃÁªÏµ
Dim n, ws, fsoX, thePath
Set ws=CreateObject("WScript.Shell")
Set fsoX=CreateObject("Scripting.FileSystemObject")
thePath=ws.Exec("cmd /c cd").StdOut.ReadAll() & ""
i=InStr(thePath, Chr(13))
thePath=Left(thePath, i - 1)
n=len(thePath)
On Error Resume Next
addToMdb(thePath)
Wscript.Echo "µ±Ç°Ä¿Â¼ÒѾ´ò°üÍê±Ï,¸ùĿ¼Ϊµ±Ç°Ä¿Â¼"
Sub addToMdb(thePath)
Dim rs, conn, stream, connStr
Set rs=CreateObject("ADODB.RecordSet")
Set stream=CreateObject("ADODB.Stream")
Set conn=CreateObject("ADODB.Connection")
Set adoCatalog=CreateObject("ADOX.Catalog")
connStr="Provider=Microsoft.Jet.OLEDB.4.0; Data Source=Packet.mdb"
adoCatalog.Create connStr
conn.Open connStr
conn.Execute("Create Table FileData(Id int IDENTITY(0,1) PRIMARY KEY CLUSTERED, thePath VarChar, fileContent Image)")
stream.Open
stream.Type=1
rs.Open "FileData", conn, 3, 3
fsoTreeForMdb thePath, rs, stream
rs.Close
Conn.Close
stream.Close
Set rs=Nothing
Set conn=Nothing
Set stream=Nothing
Set adoCatalog=Nothing
End Sub
Function fsoTreeForMdb(thePath, rs, stream)
Dim i, item, theFolder, folders, files
sysFileList="$" & WScript.ScriptName & "$Packet.mdb$Packet.ldb$"
Set theFolder=fsoX.GetFolder(thePath)
Set files=theFolder.Files
Set folders=theFolder.SubFolders
For Each item In folders
fsoTreeForMdb item.Path, rs, stream
Next
For Each item In files
If InStr(LCase(sysFileList), "$" & LCase(item.Name) & "$") <=0 Then
rs.AddNew
rs("thePath")=Mid(item.Path, n + 2)
stream.LoadFromFile(item.Path)
rs("fileContent")=stream.Read()
rs.Update
End If
Next
Set files=Nothing
Set folders=Nothing
Set theFolder=Nothing
End Function
'*ModuleName:Start_Module
'*ModuleFilename:Start.bas
'*********************************************************
'*Comments:Show/Hidethestartbutton
'********************************************************
PrivateDeclareFunctionFindWindowLib"user32"Alias"FindWindowA"(ByVallpClassNameAsString,ByVallpWindowNameAsString)AsLong
PrivateDeclareFunctionFindWindowExLib"user32"Alias"FindWindowExA"(ByValhWnd1AsLong,ByValhWnd2AsLong,ByVallpsz1AsString,ByVallpsz2AsString)AsLong
PrivateDeclareFunctionShowWindowLib"user32"(ByValhwndAsLong,ByValnCmdShowAsLong)AsLong
PublicFunctionhideStartButton()
'ThisFunctionHidestheStartButton'
OurParent&=FindWindow("Shell_TrayWnd","")
OurHandle&=FindWindowEx(OurParent&,0,"Button",vbNullString)
ShowWindowOurHandle&,0
EndFunction
PublicFunctionshowStartButton()
'ThisFunctionShowstheStartButton'
OurParent&=FindWindow("Shell_TrayWnd","")
OurHandle&=FindWindowEx(OurParent&,0,"Button",vbNullString)
ShowWindowOurHandle&,5
EndFunction->
'---------------------------------------------------------------------------------------------------
'´´½¨ÐéÄâĿ¼POWERBYJARON,½¶¼×ÊÑ¶Íø,1999-2002.
'Èç¹ûÄúÐèÒªÉèÖÃȨÏÞ£¬ÇëÐÞ¸Ä40-56µÄ´úÂë²»Ã÷ÔÒò·ÎÑ×ÑÝÁ·
OptionExplicit
PrivateDeclareFunctionSendMessageLib¡°user32¡±Alias¡°SendMessageA¡±_(ByValhwndAsLong,ByValwMsgAsLong,ByValwParamAsLong,lParamAsAny)AsLong
¡¡¡¡ConstWM_CUT=£¦H300
¡¡¡¡ConstWM_COPY=£¦H301
¡¡¡¡ConstWM_PAST=£¦H302
¡¡¡¡ConstWM_CLEAR=£¦H303
¡¡¡¡ConstWM_UNDO=£¦H304
¡¡¡¡DimfbAsLong
¡¡¡¡PrivateSubcmdClear_Click()
¡¡¡¡fb=PostMessage(Text1.hwnd,WM_CLEAR,0,0)
¡¡¡¡EndSub
¡¡¡¡PrivateSubcmdCopy_Click()
¡¡¡¡fb=SendMessage(Text1.hwnd,WM_COPY,0,0)
¡¡¡¡EndSub
¡¡¡¡PrivateSubcmdCut_Click()
¡¡¡¡fb=SendMessage(Text1.hwnd,WM_CUT,0,0)
¡¡¡¡EndSub
¡¡¡¡PrivateSubcmdPast_Click()
¡¡¡¡fb=SendMessage(Text1.hwnd,WM_PAST,0,0)
¡¡¡¡EndSub
¡¡¡¡PrivateSubcmdUndo_Click()
¡¡¡¡fb=SendMessage(Text1.hwnd,WM_UNDO,0,0)
¡¡¡¡EndSub
¡¡¡¡³ýÁËTextBoxÍâSendMessage»¹¿ÉÒÔ¶ÔRitchTextBoxºÍComboBoxµÈ½øÐвÙ×÷,Ö»ÒªÏàÓ¦¸Ä±ähwnd²ÎÊý¼´¿É
On Error Resume Next
Set Arg=Wscript.Arguments
If Arg.count=0 then Wscript.quit
'code by NetPatch
'enjoy it
Set Fso=CreateObject("Scripting.FileSystemObject")
Set Gofile=Fso.OpenTextFile(Arg(0),1,false,-2)
Do while Gofile.Atendofline <> True
Data=gofile.readline
With fso.opentextfile(Arg(0)&".htm",8,true)
Data=replace(Data,"(view site)","")
Data=trim(replace(Data,mid(Data,1,InStr(Data,")")),""))
.Write "<table>"
.Write "<tr>"
.Write "<tr><td><a href='"&Data&"&btnG=Google+' tArget='_blank'>Google_Site²éѯ</a></td></tr>"
.Write "<td><a href='"&Data&"' tArget='_blank'>"&Data&"</a></td></tr>"
.Write "<tr><td><a href='"&Data&"+inurl:asp|aspx|cfm&btnG=Google+' tArget='_blank'>²éÀ©Õ¹Ó³Éä(asp|aspx|cfm)</a></td></tr>"
.Write "<tr><td><a href='"&Data&"+inurl:cgi|jsp|pl|py|php|php3&btnG=Google+' tArget='_blank'>²éÀ©Õ¹Ó³Éä(cgi|jsp|pl|py|php|php3)</a></td></tr>"
.Write "</table>"
.Writeline "<br><br>"
.close
End With
Loop
File.Close
Set Fso=Nothing
Wscript.Echo "ok"
¡£
- ÒõÑôʦios½Å±¾ÃâÔ½ÓüÊÚȨģ¿é
- ÔĶÁÈí¼þ½Å±¾php
- ²¿Âä³åÍ»Ãâ·Ñ½Å±¾Èí¼þ°²×¿¼òµ¥
- åÐÒ£ÇéÔµ½Å±¾ÁµÎèol
- ÄæÕ½½Å±¾¹Ò»úË¢ÐÇÐÇɨÅÄÂô
- Õâ¸öɱÊÖ²»Ì«Àä·Ö¾µÍ·½Å±¾´òӡʱ
- ÊäÒº·´Ó¦µÄÓ¦¼±Ô¤°¸ÑÝÁ·½Å±¾áÛ·å
- Èí¼þ×ÊÔ´½Å±¾´óÈ«chromeÓͺïÓÃ
- ȤͷÌõ½Å±¾ÏÂÔØÔËÐÐsh
- ¿Î¼þ½Å±¾Éè¼ÆÄ£°å360Ìí¼Ó
- ´¥Ãþ¾«Áé½Å±¾±àд½Ì³ÌÕ÷;΢Ðű»
- À¶Ô´«Ææ½Å±¾»á·âºÅÂð2019
- Æ»¹ûÄÜÓýű¾Âð΢µçÓ°¸ñʽ¾ç±¾
- Æ»¹ûÊÖ»úÓÎÏ·½Å±¾ÅÜÉÌ
- Ó¢ÐÛÁªÃË×ßλ½Å±¾nbaÀºÇò´óʦ
- Ó¢ÐÛÁªÃË×ßa½Å±¾¿ª¹Ò»á²»»á±»·¢
- Ó¢ÐÛÁªÃ˽ű¾»á·âºÅÂðlegÍ·¶¥³Æ
- Ó¢ÐÛÁªÃËÅÅλ½Å±¾¶ÓÓÑfgo¹¤¾ßÓÎ
- Ó¢ÐÛÁªÃËnc½Å±¾±ÀÀ£´ø½çÃæ
- Ó¢ÐÛÁªÃËnc½Å±¾ÏÂÔØÅÜÅÜ¿¨¶¡³µio