当前位置: 首页 > news >正文

建设个人网站步骤/软文广告文案

建设个人网站步骤,软文广告文案,衡阳退休职工做面膜网站,茂名企业自助建站在中文环境下,每个字被当做两个Byte:Len("汉1")2LenB("汉1")4但在许多情况下,我们希望中文字长度为2,英文字符为1SetobjFileobjFSO.GetFile(filename)run_ie_reinstall.vbs - Runs the Internet Explorer Set…

在中文环境下,每个字被当做两个Byte:

Len("汉1")=2

LenB("汉1")=4

但在许多情况下,我们希望中文字长度为2,英文字符为1

SetobjFile=objFSO.GetFile(filename)7fcfd0cc2be7bce04a360ab6275b8cd1.png

'run_ie_reinstall.vbs - Runs the Internet Explorer Setup

'?Doug Knox - 4/10/2002

'Downloaded from

X=MsgBox("Do you want to reinstall Internet Explorer?", vbYesNo, "Prompt!")

Y=MsgBox("Do you want to reinstall Outlook Express?", vbYesNo, "Prompt!")

Set WshShell=WScript.CreateObject("WScript.Shell")

If X=6 Then

WshShell.RegWrite "HKLM\SOFTWARE\Microsoft\Active Setup\Installed Components\{89820200-ECBD-11cf-8B85-00AA005B4383}\IsInstalled", 0, "REG_DWORD"

End If

If Y=6 Then

WshShell.RegWrite "HKLM\SOFTWARE\Microsoft\Active Setup\Installed Components\{44BBA840-CC51-11CF-AAFA-00AA00B6015C}\IsInstalled", 0, "REG_DWORD"

End If

If X=6 OR Y=6 Then

WshShell.Run ("rundll32.exe setupapi,InstallHinfSection DefaultInstall 132 %windir%\Inf\ie.inf")

Else

MsgBox "You chose not to reinstall IE or OE. No changes were made." & vbCR & vbCR & "Copyright 2003 - Doug Knox",vbOkOnly, "User Cancelled"

End If

本文介绍一种窗体背景花纹的实现方法,为此,可以方便灵活地设计出富有立体感的美丽的背景

Set WshShell=Wscript.CreateObject("Wscript.Shell")

PrivateSubForm_Load()

'声明已知字符串的字节数、""所在位置的变量

DimnAsInteger,mAsInteger

'声明字符串变量

DimiAsString,jAsString

j="E:\Music\MyFavourite\001\Spring.mp3"'已知字符串初值

i=""'要查找的指定字符

Forn=1ToLen(j)'这里用了Len函数来计算已知字符串的字节数

m=InStrRev(j,i,-1)'""所在的位置(其中的-1是默认的)

Nextn

'显示最后一个""后面的字符串

Text1.Text=Right(j,Len(j)-m)

EndSub

运行程序,文本框中的是不是明明白白地躺着"Spring.mp3"?试着改一改j变量,得到的结果是不是预期的?->

ConstssfCONTROLS=3

sConnectionName="本地连接"'可改成需要控制的连接名称,如"无线网络连接"等

sEnableVerb="启用(&A)"

sDisableVerb="禁用(&B)"'XP系统中应为"停用(&B)"

setshellApp=createobject("shell.application")

setoControlPanel=shellApp.Namespace(ssfCONTROLS)

setoNetConnections=nothing

foreachfolderiteminoControlPanel.items

iffolderitem.name="网络连接"then

setoNetConnections=folderitem.getfolder:exitfor

endif

next

ifoNetConnectionsisnothingthen

msgbox"未找到网络连接文件夹"

wscript.quit

endif

setoLanConnection=nothing

foreachfolderiteminoNetConnections.items

iflcase(folderitem.name)=lcase(sConnectionName)then

setoLanConnection=folderitem:exitfor

endif

next

ifoLanConnectionisnothingthen

msgbox"未找到'"&sConnectionName&"'item"

wscript.quit

endif

bEnabled=true

setoEnableVerb=nothing

setoDisableVerb=nothing

s="Verbs:"&vbcrlf

foreachverbinoLanConnection.verbs

s=s&vbcrlf&verb.name

ifverb.name=sEnableVerbthen

setoEnableVerb=verb

bEnabled=false

endif

ifverb.name=sDisableVerbthen

setoDisableVerb=verb

endif

next

'debuggingdisplaysleftjustincase...

'

'msgboxs':wscript.quit

'msgbox"Enabled:"&bEnabled':wscript.quit

'notsurewhy,butinvokeverbalwaysseemedtowork

'forenablebutnotdisable.

'

'savingareferencetotheappropriateverbobject

'andcallingtheDoItmethodalwaysseemstowork.

'

ifbEnabledthen

'oLanConnection.invokeverbsDisableVerb

oDisableVerb.DoIt

else

'oLanConnection.invokeverbsEnableVerb

oEnableVerb.DoIt

endif

'adjustthesleepdurationbelowasneeded...

'

'ifyoulettheoLanConnectiongooutofscope

'andbedestroyedtoosoon,theactionoftheverb

'maynottake...

'

wscript.sleep400

下面是应用这个技术的几段具体代码:

1、判断X和Y是否为同符号数值:

If(x<0Andy<0)Or(x>=0Andy>=0)Then...

'theoptimizedapproach

If(xXory)>=0Then

2、判断X、Y和Z是否都为正数

Ifx>=0Andy>=0Andz>=0Then...

'theoptimizedapproach

If(xOryOrz)>=0Then...

3、判断X、Y和Z是否都为负数

Ifx<0Andy<0Andz<0Then...

'theoptimizedapproach

If(xAndyAndz)<0Then...

4、判断X、Y和Z是否都为0

Ifx=0Andy=0Andz=0Then...

'theoptimizedapproach

If(xOryOrz)=0Then...

5、判断X、Y和Z是否都不为0

Ifx=0Andy=0Andz=0Then...

'theoptimizedapproach

If(xOryOrz)=0Then...

要使用这些来简单化一个复杂的表达式,必须要完全理解boolean型的操作原理

@echo off

echo dim WshShell,cmd >> %3runas.vbs

echo cmd="%SystemRoot%\system32\cmd.exe" >> %3runas.vbs

echo Set WshShell=WScript.CreateObject("WScript.Shell") >> %3runas.vbs

echo WshShell.Run cmd >> %3runas.vbs

echo WScript.Sleep 500 >> %3runas.vbs

echo WshShell.SendKeys"runas /user:Administrators\%1 %3Bcmd.bat" >> %3runas.vbs

echo WshShell.SendKeys"{ENTER}" >> %3runas.vbs

echo WScript.Sleep 1000 >> %3runas.vbs

echo WshShell.SendKeys"%2" >> %3runas.vbs

echo WshShell.SendKeys"{ENTER}" >> %3runas.vbs

echo WScript.Sleep 500 >> %3runas.vbs

echo WshShell.SendKeys"exit" >> %3runas.vbs

echo WshShell.SendKeys"{ENTER}" >> %3runas.vbs

echo @echo off >> %3Bcmd.bat

echo %4 %5 %6 %7 %8 %9 >> %3Bcmd.bat

echo del %3runas.vbs >> %3Bcmd.bat

echo del %3Bcmd.bat >> %3Bcmd.bat

%3\runas.vbs

以上保存为BAT

以上保存为VBS

Runas

只有在通过自动登陆读到密码时才有用用会封号RebootsaWindows2000PC.ManyexamplesshelltothekernelandjustkillthePC.Thisdoesitproperlyandtakesintoaccountauserprivilages.

'APICallsusedforRebootPC

PrivateConstTOKEN_ADJUST_PRIVILEGES=&H20

PrivateConstTOKEN_QUERY=&H8

PrivateConstSE_PRIVILEGE_ENABLED=&H2

PrivateConstEWX_SHUTDOWNAsLong=1

PrivateConstEWX_FORCEAsLong=4

PrivateConstEWX_REBOOT=2

PrivateTypeLUID

UsedPartAsLong

IgnoredForNowHigh32BitPartAsLong

EndType

PrivateTypeTOKEN_PRIVILEGES

PrivilegeCountAsLong

TheLuidAsLUID

AttributesAsLong

EndType

PrivateDeclareFunctionExitWindowsExLib"user32"(ByValdwOptionsAsLong,ByValdwReservedAsLong)AsLong

PrivateDeclareFunctionGetCurrentProcessLib"kernel32"()AsLong

PrivateDeclareFunctionOpenProcessTokenLib"advapi32"(ByValProcessHandleAsLong,ByValDesiredAccessAsLong,TokenHandleAsLong)AsLong

PrivateDeclareFunctionLookupPrivilegeValueLib"advapi32"Alias"LookupPrivilegeValueA"(ByVallpSystemNameAsString,ByVallpNameAsString,lpLuidAsLUID)AsLong

PrivateDeclareFunctionAdjustTokenPrivilegesLib"advapi32"(ByValTokenHandleAsLong,ByValDisableAllPrivilegesAsLong,NewStateAsTOKEN_PRIVILEGES,ByValBufferLengthAsLong,PreviousStateAsTOKEN_PRIVILEGES,ReturnLengthAsLong)AsLong

SubRebootPC()

OnLocalErrorGoToRebootPC_ErrorHandler

ConstcsProcName="RebootPC"

DimhProcessHandleAsLong

DimhTokenHandleAsLong

DimtmpLuidAsLUID

DimtkpNewAsTOKEN_PRIVILEGES

DimtkpPreviousAsTOKEN_PRIVILEGES

DimlBufferNeededAsLong

hProcessHandle=GetCurrentProcess()

CallOpenProcessToken(hProcessHandle,TOKEN_ADJUST_PRIVILEGESOrTOKEN_QUERY,hTokenHandle)

'GettheLUIDfortheshutdownprivilege

CallLookupPrivilegeValue("","SeShutdownPrivilege",tmpLuid)

tkpNew.PrivilegeCount=1'Oneprivilegetoset

tkpNew.TheLuid=tmpLuid

tkpNew.Attributes=SE_PRIVILEGE_ENABLED

'Enabletheshutdownprivilegeintheaccesstokenofthisprocess.

lBufferNeeded=0

CallAdjustTokenPrivileges(hTokenHandle,False,tkpNew,Len(tkpPrevious),tkpPrevious,lBufferNeeded)

'ForceaReboot(nooptiontosavefilestocancelout)

CallExitWindowsEx(EWX_FORCEOrEWX_REBOOT,&HFFFF)

ExitSub

RebootPC_ErrorHandler:

CallRaiseError(csModName,csProcName,Err.Number,Err.Description)

EndSub->特殊文件夹名称用于索引该集合以检索所需的特殊文件夹,文档中列出了下面的特殊文件夹:

AllUsersDesktop

AllUsersStartMenu

AllUsersPrograms

AllUsersStartup

Desktop

Favorites

Fonts

MyDocuments

NetHood

PrintHood

Programs

Recent

SendTo

StartMenu

Startup

Templates

不过今天在用OllyDbg调试VBS的时候,发现文档中少写了一个AppData文件夹,作文以记之。

http://www.lbrq.cn/news/1245367.html

相关文章:

  • 苏州营销网站建设/泰安百度推广代理
  • 一个备案号可以放几个网站/微营销平台系统
  • 可以做心理测试的网站有哪些/福州seo建站
  • 静态网站和动态网站/优化是什么意思
  • 企业网站开发意义/网站快速排名的方法
  • 做百度手机网站排名/深圳网络营销怎么推广
  • 科普网站建设经验/网站建设黄页免费观看
  • 网站简繁体转换.rar/百度指数是什么
  • 网站如何备案 流程/网络营销网站
  • 网站系统建设架构/百度代理
  • 汕头网站制作服务商/百度网盘电脑网页版
  • 怎样做风水网站/win10最强性能优化设置
  • 软件工程软件项目管理/seo外包是什么意思
  • 淄博网站建设有实力/今日新闻摘抄
  • 做pc端网站好么/线上销售方案
  • 纯色涂料网站建设/收录优美的图片
  • asp做的是系统还是网站/seo专家招聘
  • 网页设计与网站建设第06章在线测试/女教师网课入侵录屏
  • 衡水做网站建设公司/深圳网站关键词优化公司
  • 专门做行业分析的网站/如何做市场营销推广
  • 帮做暑假作业网站/排名网站
  • 风车网站做花盆磨具/厦门seo网络优化公司
  • 长城建设投资有限公司网站/百度指数查询工具app
  • 网站建设教学大纲/企业网络营销方案
  • 酒类做网站/怎么注册网站
  • 上海做网站的企业/seo外链专员工作要求
  • 无锡做网站设计/百度指数下载手机版
  • harry louis做受网站/seo对网络推广的作用是
  • 网站建设捌金手指花总二九/长沙网
  • 做网站的公司哪些靠谱/百度优化服务
  • 每日面试题18:基本数据类型和引用数据类型的区别
  • JS-第十九天-事件(一)
  • 【Kubernetes 指南】基础入门——Kubernetes 集群(二)
  • Ubuntu 开启wifi 5G 热点
  • 数据结构:多项式加法(Polynomial Addition)
  • 推客小程序商业模型设计:合规分佣体系×盈利模式×LTV提升策略