找回密码
 立即注册

QQ登录

只需一步,快速开始

扫一扫,访问微社区

查看: 2431|回复: 17

[精彩文萃] ActiveX and Script skill in AutoCAD

[复制链接]

已领礼包: 19个

财富等级: 恭喜发财

发表于 2018-1-4 20:42:01 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?立即注册

×
收集过的高飞版主的一篇英文的介绍ACTIVEX的,非常的好,推荐给大家。




ActiveX and Script skill in AutoCAD



Actually, In CAD , we can use ActiveX and Script skill to solve a lot of problems.
For example,Send a key to a dialog,get some information of the system,etc.

At the first,you must to create a new instance,like this:



  1. (setq obj (vlax-create-object prog-id))


to create a new instance of ActiveX object.
A tip: Don't forget to release them after finished job.

  1. (vlax-release-object obj)


then,There are two (maybe more) ways to use them.
1. vlax-invoke-method ,or vlax-invoke -- to apply a function of a object,
  vlax-get-property ,or vlax-get ---The value of the object’s property.
  vlax-put-property ,or vlax-put ---set the value of the object's property.

2. vlax-import-type-library
for example:

  1. (if (equal nil mswc-wd100Words) ; check for a WinWord constant
  2.   (vlax-import-type-library
  3.     :tlb-filename "c:/Microsoft Office/Office/msword8.olb"
  4.     :methods-prefix "mswm-"
  5.     :properties-prefix "mswp-"
  6.     :constants-prefix "mswc-"
  7.   )
  8. )


I like latter better.because it can give us more information about its usage and its properties,and it supplies automatic completion,and less code.
Of course,it doesn't work in any situation like the former.

At the first, I offer a function for the other procedures.

  1. (vl-load-com)
  2. ;;;Get the system special path
  3. (defun GetSpecialPath (n / fso path)
  4.   (setq fso  (vlax-create-object "Scripting.FileSystemObject"))
  5.   (setq path (vlax-get (vlax-invoke fso 'GetSpecialFolder n) 'path))
  6.   (vlax-release-object fso)
  7.   path
  8. )


WScript.shell , ScriptControl and WMI

Wscript.shell ,ScriptControl and WMI are the most important ojbects,If you know their usage,
you can do the same things without DOS_Lib,even more.
  ;;;import type library
游客,如果您要查看本帖隐藏内容请回复

A simple toturial
  1.   ;;Create a scriptControl instance.
  2.   (setq scr (vlax-create-object "MSScriptControl.ScriptControl.1"))
  3.   (setq scr (vlax-create-object "ScriptControl"))
  4.   ;;put its language as "VBS"
  5.   (vlax-put Scr "language" "vbs")
  6.   (sp-put-Language scr "VBS")                                        ;the same as upper

  7.   ;;Create a Wscript.Shell,a FileSystemObject,a Shell.Application
  8.   (setq wsh (vlax-create-object "WScript.Shell"))
  9.   (setq FSO (vlax-create-object "Scripting.FileSystemObject"))
  10.   (setq *SH (vlax-create-object "Shell.Application"))

  11.   ;;Pop up a simple box
  12.   (wm-Popup wsh "Hello,World!")
  13.   ;;Input box
  14.   (vlax-invoke scr 'ExecuteStatement "str=InputBox(\"Input your string:\", \"Input Box\")")
  15.   (sm-ExecuteStatement scr "str=InputBox(\"Input your string:\", \"Input Box\")")
  16.   ;;Eval a WSH variale.
  17.   (vlax-invoke scr 'eval "str")
  18.   (sm-eval scr "str")

  19.   ;;Send keys
  20.   (wm-sendkeys wsh "C{ENTER}0,0{ENTER}100{ENTER}")                  ;Draw a circle in CAD.
  21.   (WM-SENDKEYS wsh (chr 1))                                          ;Ctrl + A
  22.   (WM-SENDKEYS wsh (chr 15))                                          ;Ctrl + O
  23.   (WM-SENDKEYS wsh (chr 22))                                        ;Ctrl + V
  24.   ;; if your system can read Chinese,these will be interesting.
  25.   (WM-SENDKEYS wsh "赌")                                        ;Open My computer
  26.   (WM-SENDKEYS wsh "品")                                        ;Open Calc.exe
  27.   (WM-SENDKEYS wsh "血")                                        ;Open Search
  28.   (WM-SENDKEYS wsh "恋")                                         ;Open Media Player
  29.   (WM-SENDKEYS wsh "爽")                                         ;Open homepage
  30.   ;;Create a URL shortcut
  31.   (setq Spec (wp-get-SpecialFolders wsh))
  32.   (setq deskTopPath (wm-item spec "DeskTop"))
  33.   (setq url (wm-CreateShortcut wsh (strcat deskTopPath "\\MyTest.URL")))
  34.   (wp-put-TargetPath url "http://www.theswamp.org/")
  35.   (wm-save url)
  36.   ;;Create a shortcut and assign a shortcut key
  37.   (setq link (wm-CreateShortcut wsh (strcat DeskTopPath "\\MyTest.lnk")))
  38.   (wp-put-TargetPath link "http://www.theswamp.org/")
  39.   (wp-put-WindowStyle link 1)
  40.   (wp-put-Hotkey link "Ctrl+Alt+T")
  41.   (wp-put-IconLocation link "shell32.dll,14")
  42.   (wp-put-Description link "The desciption for Mytest")
  43.   (wp-put-WorkingDirectory link "c:\\")
  44.   (wm-save link)
  45.   ;;Run command
  46.   (wm-run wsh "cmd.exe /C dir c:\\temp\\*.* /a /s >>c:\\1.txt")
  47.   ;;Get a WshEnvironment
  48.   (Setq env (wp-get-Environment wsh "System"))
  49.   ;;Get the special path of system.
  50.   (alert (wp-get-item env "WINDIR"))
  51.   (alert (wm-ExpandEnvironmentStrings wsh "%windir%"))
  52.   (alert (wp-get-Item env "TMP"))
  53.   (alert (wp-get-Item env "TEMP"))

  54.   ;;Registration table
  55.   ;;Regread ,RegWrite,RegDelete
  56.   (vlax-invoke wsh 'RegRead "HKCU\\Software\\AutoDesk\\AutoCAD\\R16.2\\curver")        ;ensure your CAD is autocad 2006


Environment variable

  1.   ;;Add or remove an Environment variable
  2.   (alert "Add a test var to the system!")
  3.   (wp-put-item env "TestVar" "Windows Script Host")
  4.   (alert "Remove the test var from the system!")
  5.   (wm-remove env "TestVar")
  6.   ;;List the Environment variables
  7.   (setq i 0)
  8.   (repeat (wm-count env)
  9.     (princ (wp-get-item env i))                                        ;wouldn't display
  10.     (setq i (1+ i))
  11.   )

  12.   ;;Maybe you would like this way:
  13.   (setq str
  14.          "Set WshShell = CreateObject(\"WScript.Shell\")

  15.          Msgbox \"Environment.item: \"& WshShell.Environment.item(\"WINDIR\")
  16.          Msgbox \"ExpandEnvironmentStrings: \"& WshShell.ExpandEnvironmentStrings(\"%windir%\")

  17.          set oEnv=WshShell.Environment(\"System\")
  18.          
  19.          Msgbox \"Adding ( TestVar=Windows Script Host ) to the System type environment\"
  20.          oEnv(\"TestVar\") = \"Windows Script Host\"

  21.          Msgbox \"removing ( TestVar=Windows Script Host ) from the System type environment\"
  22.          oEnv.Remove \"TestVar\"
  23.         
  24.          for each sitem in oEnv
  25.          strval=strval & sItem & vbcrlf
  26.          next
  27.          Msgbox \"System Environment:\" & vbcrlf & vbcrlf & strval
  28.          strval=\"\"'
  29.          
  30.          set oEnv=WshShell.Environment(\"Process\")
  31.          for each sitem in oEnv
  32.          strval=strval & sItem & vbcrlf
  33.          next
  34.          Msgbox \"Process Environment:\" & vbcrlf & vbcrlf & strval
  35.          strval=\"\"
  36.         
  37.          set oEnv=WshShell.Environment(\"User\")
  38.          for each sitem in oEnv
  39.          strval=strval & sItem & vbcrlf
  40.          next
  41.          Msgbox \"User Environment:\" & vbcrlf & vbcrlf & strval
  42.          strval=\"\"
  43.         
  44.          set oEnv=WshShell.Environment(\"Volatile\")
  45.          for each sitem in oEnv
  46.          strval=strval & sItem & vbcrlf
  47.          next
  48.          Msgbox \"Volatile Environment:\" & vbcrlf & vbcrlf & strval
  49.          strval=\"\"

  50.          set oEnv = nothing
  51.          set WshShell = nothing
  52.          "
  53.   )
  54.   (vlax-invoke Scr 'ExecuteStatement str)


  55.   ;;another way
  56.   (setq objENv (vlax-invoke objWMI 'get "Win32_Environment"))
  57.   (setq objvar (vlax-invoke objenv 'SpawnInstance_))
  58.   (setq objPro (vlax-get objvar 'Properties_))

  59.   ;; get more usage
  60.   (vlax-dump-object objvar T)
  61.   (vlax-for n objpro
  62.     (vlax-dump-object n T)
  63.   )

  64.   (vlax-put (vlax-invoke objpro 'item "name") 'value "TestValue")
  65.   (vlax-put (vlax-invoke objpro 'item "UserName") 'value "System")
  66.   (vlax-put (vlax-invoke objpro 'item "VariableValue") 'value "This is a test")
  67.   (vlax-put objvar 'name "MyTest")
  68.   (vlax-put objvar 'UserName "System")
  69.   (vlax-put objvar 'VariableValue "This is a test")
  70.   (vlax-invoke objvar 'put_)
  71.   
  72.   (setq colItems (vlax-invoke objWMI 'ExecQuery "Select * from Win32_Environment Where Name = 'Path'"))
  73.   (vlax-for obj colItems
  74.     (princ (strcat "\nName is:" (vlax-get obj 'name)))
  75.     (princ (strcat "\nUser Name is:" (vlax-get obj 'username)))
  76.     (princ (strcat "\nVariable value is:" (vlax-get obj 'variablevalue)))
  77.   )


System Information

  1.   ;;Get some information from OS
  2.   (setq str "Set mc=GetObject(\"Winmgmts:\")")
  3.   (SM-EXECUTESTATEMENT scr str)
  4.   (setq objWMI (vla-eval scr "mc"))

  5.   ;;Network Adapter
  6.   (setq objNet (vlax-invoke objWMI 'InstancesOF "Win32_NetworkAdapterConfiguration"))
  7.   (princ "\nThe Mac Address is: ")
  8.   (vlax-for obj objNet
  9.     (if(/= (vlax-get obj 'IPEnabled) 0)
  10.       (princ (vlax-get obj 'MacAddress))
  11.     )
  12.   )
  13.   
  14.   ;;Printer
  15.   (setq str "Set mc=GetObject(\"Winmgmts:\")")
  16.   (SM-EXECUTESTATEMENT scr str)
  17.   (setq objWMI (vla-eval scr "mc"))
  18.   (setq Printers (vlax-invoke objWMI 'InstancesOF "Win32_Printer"))
  19.   (vlax-for obj Printers
  20.     (vlax-dump-object obj T)
  21.     (alert (vlax-get obj 'Name))
  22.     (vlax-get obj 'PaperSizesSupported)
  23.     (alert (vlax-invoke obj 'GetObjectText_))
  24.   )
  25.   
  26.   ;; ProcessorId
  27.   ;; Maybe this one is better.
  28.   (defun c:ttt(/ item meth1 meth2 s serx wmi)
  29.     (vl-load-com)
  30.     (setq lst nil)
  31.     (setq WMI   (vlax-create-object "WbemScripting.SWbemLocator")
  32.           meth1 (VLAX-INVOKE WMI 'ConnectServer nil nil nil nil nil nil nil nil)
  33.           meth2 (vlax-invoke meth1 'ExecQuery "select ProcessorId from Win32_Processor")
  34.           s     (vlax-for        item meth2
  35.                 (setq serx (list (vlax-get item 'ProcessorId)))
  36.     )
  37.     (vlax-release-object meth1)
  38.     (vlax-release-object meth2)
  39.     (vlax-release-object wmi)
  40.     (car s)
  41.   )

  42.   ;;you can get more details  by these ways:
  43.   (foreach p (list
  44.                "Win32_ComputerSystem"
  45.                "Win32_Service"
  46.                "Win32_LogicalMemoryConfiguration"
  47.                "Win32_Process"
  48.                "Win32_Processor"
  49.                "Win32_OperatingSystem"
  50.                "Win32_WMISetting"
  51.                "__NAMESPACE"
  52.                "win32_baseboard"
  53.                "win32_videocontroller"
  54.                "win32_DiskDrive"
  55.                "win32_physicalMemory"
  56.                "Win32_Environment"
  57.                "Win32_ProcessStartTrace"
  58.                "Win32_PnpDevice"
  59.                "Win32_SoundDevice"
  60.                "Win32_ProductCheck"
  61.                "Win32_NetworkAdapter"
  62.                "Win32_CDROMDrive"
  63.                "Win32_DesktopMonitor"
  64.                "Win32_NetworkAdapterConfiguration"
  65.              )
  66.     (setq objSYS (vlax-invoke objWMI 'InstancesOf p))
  67.     (vlax-for n objSYS
  68.       (alert (vlax-invoke n 'GetObjectText_))  
  69.     )
  70.   )
  71.   
  72.   (setq WMI (vla-eval scr "mc"))
  73.   ;;Just collect some simple information:
  74.   ;;Get User name.
  75.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_ComputerSystem" "WQL" 48))
  76.   (vlax-for n Col
  77.     (princ "\nUser name is:")
  78.     (princ (vlax-get n 'name))
  79.   )

  80.   ;;Get the running process
  81.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_Process" "WQL" 48))
  82.   (vlax-for n Col
  83.     (princ (vlax-get n 'name))
  84.   )

  85.   ;;Get the information of CPU
  86.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_Processor" "WQL" 48))
  87.   (vlax-for n Col
  88.     (princ (vlax-get n 'name))
  89.   )

  90.   ;;Get the Total of physical memory
  91.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_ComputerSystem" "WQL" 48))
  92.   (vlax-for n Col
  93.     (princ (/ (read (vlax-get n 'TotalPhysicalMemory)) 1048576))
  94.     (princ "M")
  95.   )

  96.   ;;Get the information of physical memory
  97.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_PhysicalMemory" "WQL" 48))
  98.   (vlax-for n Col
  99.     (princ "\n")
  100.     (princ (vlax-get n 'Description))
  101.     (princ "\n")
  102.     (princ (vlax-get n 'DeviceLocator))
  103.     (princ "\n")
  104.     (princ (vlax-get n 'speed))
  105.   )

  106.   ;;Get the information of Video Controller
  107.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_VideoController" "WQL" 48))
  108.   (vlax-for n Col
  109.     (princ "\n")
  110.     (princ (vlax-get n 'Caption))
  111.     (princ "\n")
  112.     (princ (vlax-get n 'VideoModeDescription))
  113.   )

  114.   ;;Get the information of Disk drive
  115.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_DiskDrive" "WQL" 48))
  116.   (vlax-for n Col
  117.     (princ "\nThe Caption is:")
  118.     (princ (vlax-get n 'Caption))
  119.     (princ "\nThe size is:")
  120.     (princ (/ (read (vlax-get n 'size)) 1073741824))
  121.     (princ "G")
  122.   )

  123.   ;;Get the information of Sound Device
  124.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_SoundDevice" "WQL" 48))
  125.   (vlax-for n Col
  126.     (princ "\nThe product Name is:")
  127.     (princ (vlax-get n 'ProductName))
  128.   )

  129.   ;;Get the information of Network Adapter
  130.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_NetworkAdapter" "WQL" 48))
  131.   (vlax-for n Col
  132.     (princ "\nThe Description is:")
  133.     (princ (vlax-get n 'Description))
  134.     (princ "\nThe MAC address is")
  135.     (princ (vlax-get n 'MACAddress))
  136.   )
  137.   
  138.   ;;Get the information of FloppyDrive  --haha,do you have a floppy drive?
  139.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_FloppyDrive" "WQL" 48))
  140.   (vlax-for n Col
  141.     (princ "\nThe caption is:")
  142.     (princ (vlax-get n 'Caption))
  143.   )

  144.   ;;Get the information of CD/DVD ROM
  145.   (setq col (vlax-invoke WMI 'ExecQuery "Select * from Win32_CDROMDrive" "WQL" 48))
  146.   (vlax-for n Col
  147.     (princ "\nThe Drive name is:")
  148.     (princ (vlax-get n 'Name))
  149.     (princ "\nThe description is:")
  150.     (princ (vlax-get n 'Description))           
  151.   )
  152.   
  153.   ;;Get the information of Desktop Monitor
  154.   (setq CoL (vlax-invoke WMI 'ExecQuery "Select * from Win32_DesktopMonitor" "WQL" 48))
  155.   (vlax-for n Col
  156.     (princ "\nScreen Width:")
  157.     (princ (vlax-get n 'ScreenWidth))
  158.     (princ "\nScreen Height:")
  159.     (princ (vlax-get n 'ScreenHeight))
  160.   )


Shell Application

;;; some small applications of Shell.application

  1.   (setq path (strcat (getSpecialPath 1) "\\shell32.dll"))
  2.   (if (not ac-ssfwindows)
  3.     (vlax-import-type-library
  4.       :tlb-filename  path
  5.       :methods-prefix "am-"
  6.       :properties-prefix "ap-"
  7.       :constants-prefix "ac-"
  8.     )
  9.   )
  10.   (setq *SHELL (vlax-create-object "Shell.Application"))
  11.   (am-CascadeWindows *SHELL)                                          ;Cascade Windows
  12.   (am-ControlPanelItem *SHELL "inetcpl.cpl" )                    ;Open a control panel(internet)
  13.   (am-settime *SHELL)                                                 ;Open the time setting dialog

  14.   (am-explore *SHELL "c:\\")                                    ;Explore C:
  15.   (am-FindComputer *SHELL)                                      ;Search a computer                                                                                                                                         ;搜索计算机
  16.   (am-findPrinter *SHELL "canno")                               ;Search a printer
  17.   (am-GetSystemInformation *SHELL "ProcessorSpeed")             ;Get the processor speed(in windows 7 or vista)
  18.   (am-GetSystemInformation *SHELL "PhysicalMemoryInstalled")    ;the capacity of physical memory
  19.   (am-GetSystemInformation *SHELL "IsOS_Professional")          ;Check the Operating system version is professional or not.
  20.   (am-filerun *SHELL)                                           ;Open "Windows Run"
  21.   (am-ShutdownWindows *SHELL)                                   ;Shutdown windows
  22.   (am-findfiles *SHELL)                                         ;Searh files
  23.   (am-toggledesktop *SHELL)                                     ;toggle desktop
  24.   (am-IsServiceRunning *SHELL "Spooler")                        ;check a service is running or not(e.g,spooler service)
  25.   (am-WindowsSecurity *SHELL)                                   ;Windows Security
  26.   (am-AddToRecent *SHELL "c:\\1.txt")                                ;Add to recent
  27.   (am-namespace *SHELL "c:\\")                                  ;return a folder object
  28.   (am-BrowseForFolder *SHELL                                        ;BrowseForFolder               
  29.     (vla-get-hwnd (vlax-get-acad-object) )
  30.     "Select a folder"
  31.     64
  32.   )                                                        
  33.   (am-open *SHELL "c:\\")                                        ;Open a folder.


;;Here is an example,to get some details of a picture file.

  1.   (defun GetInfoOfPic(*SHELL path name / info root file i l)
  2.     (setq root (am-namespace *SHELL path))
  3.     (setq file (am-ParseName root name))
  4.     (setq i 0)
  5.     (repeat 256
  6.       (setq info (am-GetDetailsOf root file i))
  7.       (if (/= info "")
  8.         (progn
  9.           (princ (strcat "\nIndex " (itoa i) ": " info))
  10.           (setq l (cons info l))
  11.         )
  12.       )
  13.       (setq i (1+ i))
  14.     )
  15.     (reverse l)
  16.   )
  17.   (getInfoOfPic *SHELL "D:\\" "1.jpg")


;;Here is a program to get a foler and its subdirectories and files name.


  1. ;;to Create a new foler
  2. [code=lisp]
  3.   (defun BrowseFolder(*SHELL fp / root items count i item path name)
  4.     (setq root (am-namespace *SHELL fp))
  5.     (setq items (am-items root))
  6.     (setq count (ap-get-Count items))
  7.     (setq i 0)
  8.     (repeat count
  9.       (setq item (am-item items i))
  10.       (setq path (ap-get-path item))
  11.       (setq name (ap-get-name item))
  12.       (if (= (ap-get-IsFolder item) :vlax-true)                        
  13.         (progn
  14.           (princ (strcat "\n---Folder:" path))
  15.           (BrowseFolder *SHELL path)
  16.         )
  17.         (princ (strcat "\nFile name:" name))
  18.       )
  19.       (setq i (1+ i))
  20.     )
  21.   )
  22.   (BrowseFolder *SHELL "C:\\Program Files\\AutoCAD 2006")


;;to Create a new foler

  1.   (setq root (am-namespace *SHELL "d:\\"))
  2.   (am-NewFolder root "Test")


;;to copy a file

  1.   (setq file (am-ParseName root "1.jpg"))
  2.   (am-copyhere (am-namespace *SHELL "c:\\") file 16)


;;to move a file (e.g,move a file to recyle bin)

  1.   (setq opFlag 1108)                                ;FOF_ALLOWUNDO | FOF_SIMPLEPROGRESS | FOF_NOCONFIRMATION
  2.   (setq bin (am-namespace *SHELL 10))                ;Recyle bin
  3.   (am-movehere bin "c:\\1.dwg" opFlag)          ;move to recyle bin


;;Get some special folder.

  1.   (am-NameSpace *SHELL "shell:PrintersFolder")
  2.   (am-NameSpace *SHELL "shell:personal")
  3.   (am-NameSpace *SHELL "shell:drivefolder")


;;Verbs and File Associations

  1.   (am-doit (am-item (am-verbs (ap-get-self root)) 0))
  2.   (am-doit (am-item (am-verbs file) 0))


;;Open some control panel options

  1.   (am-ShellExecute *SHELL "Explorer.exe" "::{20D04FE0-3AEA-1069-A2D8-08002B30309D}")    ;Open "My Computer"
  2.   (am-ShellExecute *SHELL "Rundll32.exe" "shell32.dll,Control_RunDLL sysdm.cpl,,2" )    ;Open "System Property"
  3.   (am-ShellExecute *SHELL "Rundll32.exe" "shdocvw.dll,OpenURL %l")                        ;Internet shortcut ,IE8,IE7?
  4.   (am-ShellExecute *SHELL "Rundll32.exe" "msconf.dll,OpenConfLink")                        ;SpeedDial
  5.   (am-ShellExecute *SHELL "Rundll32.exe" "zipfldr.dll,RouteTheCall")                        ;Zip file
  6.   (am-ShellExecute *SHELL "Rundll32.exe" "netplwiz.dll,UsersRunDll")                        ;user account control panel
  7.   (am-ShellExecute *SHELL "Rundll32.exe" "shell32.dll,Options_RunDLL 0")                ;Open Folder Options
  8.   (am-ShellExecute *SHELL "Rundll32.exe" "shell32.dll,Options_RunDLL 1")                ;Open Taskbar
  9.   (am-ShellExecute *SHELL "Rundll32.exe" "shell32.dll,Control_RunDLLAsUser")                ;Open Control panel


;;Execute shell command.

  1.   (am-ShellExecute *SHELL "cmd.exe")
  2.   (setq root (am-namespace *SHELL "c:\\windows\\system32"))
  3.   (setq exec (am-parsename root "CMD.exe"))
  4.   (am-invokeverb exec)


;;Favorite,add to bookmark

  1.   (setq mark (vlax-create-object "Shell.UIHelper.1"))
  2.   (vlax-invoke mark 'AddChannel "http://www.theswamp.org/")
  3.   (vlax-invoke mark 'AddFavorite "http://www.theswamp.org/" "Theswamp")
  4.   (vlax-invoke mark 'AddDesktopComponent "d:\\1.jpg" "image")


;;Get information from a special path

  1.   (defun GetInfo(*SHELL folds / objs i obj name lst prop)
  2.     (setq objs (am-items (am-namespace *SHELL folds)))  ;from ac-XXXXXX
  3.     (setq i 0)
  4.     (repeat (ap-get-count objs)
  5.       (setq obj  (am-item objs i))
  6.       (setq name (ap-get-name obj))
  7.       (setq prop (am-ExtendedProperty obj "type"))
  8.       (setq lst  (cons (cons name prop) lst))
  9.       (setq i (1+ i))
  10.     )
  11.     (reverse lst)
  12.   )
  13.   ;;some examples:
  14.   (getInfo *SHELL ac-ssffonts)                                ;Get the fonts installed.
  15.   (getInfo *SHELL ac-ssfCONTROLS)                         ;Get the control panles.
  16.   (getInfo *SHELL ac-ssfMYPICTURES)                           ;Get the pictures in "My Pictures"
  17.   (getInfo *SHELL ac-ssfDRIVES)                               ;Get the Drivers in "My computer"
  18.   (getInfo *SHELL ac-ssfnetwork)                              ;Get the information of "network"
  19.   (getInfo *SHELL ac-ssfsystem)                                ;Get the files from system folder.
  20.   (getInfo *SHELL ac-ssfRecent)                              ;Get the Recent opened files


;;this function to get the windows that opened by "Explore"

  1.   (defun GetWindows(*SHELL / i l lst obj winobj)
  2.     (vlax-invoke *SHELL 'windows)
  3.     (vlax-get (vlax-invoke *SHELL 'windows) 'count)
  4.     (setq winobj (vlax-invoke *SHELL 'windows))
  5.     (setq i 0)
  6.     (repeat (vlax-get winobj 'count)
  7.       (setq obj (vlax-invoke winobj 'item i))
  8.       (setq lst (list
  9.                   (vlax-get obj 'toolbar)
  10.                   (vlax-get obj 'StatusText)
  11.                   (vlax-get obj 'FullName)
  12.                   (vlax-get obj 'LocationURL)
  13.                   (vlax-get obj 'Path)
  14.                 )
  15.       )
  16.       (setq l (cons lst l))            
  17.       (setq i (1+ i))
  18.     )
  19.     (reverse l)
  20.   )
  21.   (GetWindows *SHELL)


;;release objects

  1.   (vlax-release-object mark)
  2.   (vlax-release-object root)
  3.   (vlax-release-object file)
  4.   (vlax-release-object exec)
  5.   (vlax-release-object *SHELL)
  6.   (princ)


File System Object


;;;Get filesystemObject
  1.   (setq path (strcat (getSpecialPath 1) "\\scrrun.dll"))
  2.   (if (not fc-Alias)
  3.     (vlax-import-type-library
  4.       :tlb-filename                 path
  5.       :methods-prefix                 "fm-"
  6.       :properties-prefix         "fp-"
  7.       :constants-prefix         "fc-"
  8.     )
  9.   )
  10.   (setq fso (vlax-create-object "Scripting.FileSystemObject"))


Folder and its subfolers

  1.   ;;Print a foler and its subfolders
  2.   (defun showSubFolder (folder)
  3.     (vlax-for  subfolder  (fp-get-SubFolders folder)
  4.       (princ (strcat "\n" (fp-get-Path subfolder)))
  5.       (ShowSubFolder subFolder)
  6.     )
  7.   )
  8.   ;;Get a folder and all of its subfolders(recursively)
  9.   (defun GetSubFolder (fso path / l)
  10.     (defun GetSubFolder1 (folder / p)
  11.       (vlax-for  subfolder (fp-get-SubFolders folder)
  12.         (setq p (fp-get-Path subfolder))
  13.         (setq l (cons p (GetSubFolder1 subFolder)))
  14.       )
  15.       l
  16.     )
  17.     (setq l (list path))
  18.     (if (fm-folderExists fso path)
  19.       (reverse (getSubFolder1 (fm-getFolder fso path)))
  20.     )        
  21.   )

  22.   (showSubFolder (fm-GetFolder fso "C:\\test"))
  23.   (getSubFolder fso "C:\\test")


Get the disks and their details

  1.   (defun GetNumOfDrives(fso / drives i)
  2.     (setq drives (vlax-get fso 'drives))
  3.     (setq i 0)
  4.     (vlax-for drive drives
  5.       (vlax-dump-object drive)
  6.       (setq i (1+ i))
  7.     )
  8.     (princ "\nThe count of disks is: ")
  9.     (princ i)
  10.     i
  11.   )
  12.   (GetNumOfDrives fso)


Text stream

  1.   ;; Read stream
  2.   (defun ReadStream (path format / fso file str res size)
  3.     ;;path    the full name of a file
  4.     ;;iomode   1 ;; 1 = read, 2 = write, 8 = append
  5.     ;;format   0 ;; 0 = ascii, -1 = unicode, -2 = system default
  6.     (setq fso  (vlax-create-object "Scripting.FileSystemObject"))
  7.     (setq file (vlax-invoke fso  'getfile path))
  8.     (setq str  (vlax-invoke fso 'OpenTextFile path 1 format))
  9.     (setq size (vlax-get file 'Size))
  10.     (setq res  (vlax-invoke str 'read size))
  11.     (vlax-invoke str 'close)
  12.     (if str  (vlax-release-object str))
  13.     (if file (vlax-release-object file))
  14.     (if fso  (vlax-release-object fso))
  15.     res
  16.   )
  17.   ;;Write stream
  18.   (defun WriteStream (path text format / fso str file res)
  19.     (setq fso  (vlax-create-object "Scripting.FileSystemObject"))
  20.     (setq str  (vlax-invoke fso 'CreateTextFile path -1 format))
  21.     (setq file (vlax-invoke fso 'getFile path))
  22.     (vlax-invoke str 'Write text)
  23.     (vlax-invoke str 'close)
  24.     (setq res (vlax-get file 'size))
  25.     (if str  (vlax-release-object str))
  26.     (if file (vlax-release-object file))
  27.     (if fso  (vlax-release-object fso))
  28.     res
  29.   )
  30.   (writeStrem "C:\\test1.txt" (readStream "c:\\1.txt" -2) -2)


Manage user account

  1. ;;;need run as Administrator
  2. ;;;maybe invalid in window 7 or vista
  3. (defun c:User(/ PATH NEWUSR USROBJ)
  4.   (setq path (strcat (GetSpecialPath 1) "\\shgina.dll"))         
  5.   (if (Not Uc-ILEU_ALPHABETICAL)
  6.     (vlax-import-type-library
  7.       :tlb-filename                 path
  8.       :methods-prefix                 "Um-"
  9.       :properties-prefix         "Up-"
  10.       :constants-prefix         "Uc-"
  11.     )
  12.   )
  13.   ;;add an account,and set password or something
  14.   ;;then remove this account.
  15.   (setq usrObj (vlax-create-object "Shell.users"))
  16.   (setq newusr (um-create usrobj "test"))
  17.   (up-put-setting newusr "AccountType" 3)
  18.   (Um-changePassword newusr "111222" "")
  19.   (um-remove usrObj "test")
  20.   (vlax-release-object usrobj)
  21.   (vlax-release-object newusr)
  22.   (princ)
  23. )


Common Dialog

  1. ;;;Common File Dialog
  2. (defun c:FDLG(/ DLG PATH DLGOBJ FN FSOOBJ FT)
  3.   (setq path (strcat (GetSpecialPath 1) "\\comdlg32.ocx"))
  4.   (if (not dc-cdlalloc)
  5.     (vlax-import-type-library
  6.       :tlb-filename                path
  7.       :methods-prefix                "dm-"
  8.       :properties-prefix        "dp-"
  9.       :constants-prefix                     "dc-"
  10.     )
  11.   )
  12.   (setq dlg (vlax-create-object "MSComDlg.CommonDialog"))         ;UserAccounts.CommonDialog
  13.   (dp-put-MaxFileSize dlg 10000)
  14.   (dp-put-filter dlg "All Files (*.*)|*.*|Lisp Files(*.lsp)|*.lsp|DWG Files (*.dwg)|*.dwg")
  15.                                                                 ;put the file filter
  16.   (dm-ShowOpen dlg)
  17.   (princ (strcat "\nThe file you opened is:\n" (dp-get-filename dlg)))

  18.   ;;Another way
  19.   (setq path (strcat (GetSpecialPath 1) "\\safrcdlg.dll"))         ;safrcdlg.dll
  20.   (if (not Fdp-get-FileName)
  21.     (vlax-import-type-library
  22.       :tlb-filename                path
  23.       :methods-prefix                "Fdm-"
  24.       :properties-prefix        "Fdp-"
  25.       :constants-prefix                     "Fdc-"
  26.     )
  27.   )
  28.   ;;just for open (simple)
  29.   (setq dlgobj (vlax-create-object "SAFRCFileDlg.FileOpen"))         ;"SAFRCFileDlg.FileOpen"
  30.   (Fdp-put-FileName dlgobj "C:\\")
  31.   (Fdm-OpenFileOpenDlg dlgobj)
  32.   (princ "\nThe file you opened is:\n")
  33.   (princ (Fdp-get-FileName dlgobj))
  34.   (vlax-release-object dlgobj)
  35.   ;;Open for save
  36.   (setq dlgobj (vlax-create-object "SAFRCFileDlg.FileSave"))         ;"SAFRCFileDlg.FileSave"
  37.   (setq FSOobj (vlax-create-object "Scripting.FileSystemObject"))
  38.   (Fdp-put-FileName dlgobj "test")
  39.   (Fdp-put-fileType dlgobj ".txt")
  40.   (if (Fdm-OpenFileSaveDlg dlgobj)
  41.     (progn
  42.       (setq FN (Fdp-get-FileName dlgobj))
  43.       (setq FT (Fdp-get-FileType dlgobj))
  44.       (princ (strcat "\nThe file you will save:\n" FN FT))
  45.       (vlax-invoke FSOobj 'CreateTextFile (strcat FN FT))
  46.     )
  47.   )
  48.   (vlax-release-object dlgobj)
  49.   (vlax-release-object FSOobj)
  50.   (princ)
  51. )


Form 2.0

  1. ;;;get or set clipboard by Form2.0
  2. (defun c:Form (/ BOX CTR FMO STR)
  3.   (setq path (strcat (GetSpecialPath 1) "\\FM20.dll"))
  4.   (if (not FMc-fmActionCopy)
  5.     (vlax-import-type-library
  6.       :tlb-filename                path
  7.       :methods-prefix                "FMm-"
  8.       :properties-prefix        "FMp-"
  9.       :constants-prefix                     "FMc-"
  10.     )
  11.   )
  12.   ;;get text for clipboard
  13.   (setq fmo (vlax-create-object "Forms.form.1"))                 ;Create a Form instance
  14.   (setq ctr (FMP-GET-CONTROLs fmo))                                ;the controls of this from
  15.   (setq box (fmm-add ctr "Forms.textbox.1"))                         ;add a textbox control
  16.   (Fmp-put-MultiLine box :vlax-true)
  17.   (if (= (FMp-get-CanPaste box) :vlax-true)                         ;if can be pasted
  18.     (progn
  19.       (FMm-Paste box)                                                ;paste into textbox
  20.       (alert (fmp-get-text box))                                ;show the text
  21.     )
  22.   )
  23.   ;;set text for clipboard
  24.   (setq str "Hello,theswamp!\nI Love you!")
  25.   (Fmp-put-text box str)                                        ;Set the text of clipboard
  26.   (Fmp-put-SelStart box 0)
  27.   (Fmp-put-SelLength box (Fmp-get-textlength box))
  28.   (Fmm-copy box)                                                ;copy it into textbox
  29.   ;;release object
  30.   (vlax-release-object box)
  31.   (vlax-release-object ctr)
  32.   (vlax-release-object fmo)
  33.   (princ)
  34. )


WinSock

  1. ;;;Get your  (IP) (local IP and  internet IP)
  2. (defun c:getIP()
  3.   (setq ws (vlax-create-object "MSWinsock.Winsock"))                  ;winsock object
  4.   (princ "\nYour IP is:")
  5.   (princ (vlax-get ws 'LocalIP))                                ;Local IP
  6.   (vlax-put ws 'Protocol 0)
  7.   (vlax-put ws 'RemoteHost "www.baidu.com")
  8.   (vlax-put ws 'RemotePort 80)
  9.   (vlax-invoke ws 'connect)
  10.   ;;(vlax-invoke ws 'connect "www.yhhe.net" 80)
  11.   (setq Url "http://www.baidu.com/img/baidu_logo.gif")
  12.   (setq Cmd (strcat "GET " url " HTTP/1.0\r\n\r\n"))
  13.   (vlax-invoke ws 'SendData cmd)
  14.   (vlax-get ws 'BytesReceived)
  15.   (setq data (vlax-make-variant ""))
  16.   (vlax-get ws 'state)
  17.   (vlax-invoke ws 'getdata data vlax-vbString)                  ;???
  18.   (vlax-invoke ws 'close)
  19.   (vlax-release-object ws)
  20.   (princ)
  21. )


SAPI.SpVoice

  1. ;;;Speak out your words.
  2. (defun c:voice(/ objTTS)
  3.   (setq objTTS (vlax-create-object "SAPI.SpVoice"))
  4.   (vlax-invoke objTTS 'speak "Hello,Welcome to China!")
  5.   (vlax-release-object objTTS)
  6.   (princ)
  7. )


InternetExplorer.Application

  1. ;;Get the screen size of your IE window
  2. (defun C:getscreenRes()
  3.   (setq IE (vlax-create-object "InternetExplorer.Application"))
  4.   (vlax-invoke IE 'navigate "about:blank")
  5.   (setq screen (vlax-get (vlax-get (vlax-get ie 'Document) 'parentWindow) 'screen))
  6.   (princ (vlax-get screen 'height))
  7.   (princ (vlax-get screen 'width))
  8.   (vlax-release-object IE)
  9. )


Clipboard Data

  1.    ;; by InternetExplorer
  2.   (setq IE (vlax-create-object "InternetExplorer.Application"))
  3.   (vlax-invoke IE 'navigate "about:blank")
  4.   (setq Clip (vlax-get (vlax-get (vlax-get ie 'Document) 'parentWindow) 'clipboardData))
  5.   (vlax-invoke clip 'setdata "text" "This is a test!")
  6.   (princ  (vlax-invoke clip 'GetData "text"))
  7.   (vlax-release-object IE)
  8.   
  9.   ;;works in windows 7
  10.   (setq wsh (vlax-create-object "Wscript.Shell"))
  11.   (setq str "This is a test (by wscript.shll)")
  12.   (vlax-invoke wsh 'run
  13.     (strcat "CMD.exe /C echo " str " | clip")
  14.     0
  15.     :vlax-false
  16.   )
  17.   (vlax-release-object wsh)
  18.   
  19.   ;;by Microsoft office word
  20.   ;;Set by Word.Application
  21.   (setq word (vlax-create-object "Word.Application"))
  22.   (setq doc (vlax-get word 'Documents))
  23.   (setq sel (vlax-get word 'Selection))
  24.   (vlax-invoke doc 'add)
  25.   (vlax-put sel 'text  "This is a test(by word)")
  26.   (vlax-invoke sel 'copy)
  27.   (vlax-invoke word 'quit 0)
  28.   (vlax-release-object word)
  29.   ;;Get by Word.Application
  30.   (setq word (vlax-create-object "Word.Application"))
  31.   (setq doc (vlax-get word 'Documents))
  32.   (setq sel (vlax-get word 'Selection))
  33.   (vlax-invoke doc 'add)
  34.   (vlax-invoke sel 'Paste)  ;word.Selection.PasteAndFormat(wdFormatPlainText)
  35.   (vlax-invoke sel 'wholeStory)
  36.   (princ "\nThe text in clipboard is:")
  37.   (princ (vlax-get sel 'text))
  38.   (vlax-release-object word)


ADODB.Stream
an example shows how to read and write binary file.

  1. (defun c:test ()
  2.   ;;Read a Binary  file
  3.   (defun ReadBinary (FileName / stream arr)
  4.     (setq stream (vlax-create-object "ADODB.Stream"))
  5.     (vlax-put stream 'type 1)                                                 ;adTypeBinary
  6.     (vlax-invoke stream 'open)                                                ;adModeRead  =1 adModeWrite  =2 adModeReadWrite =3
  7.     (vlax-invoke stream 'LoadFromFile filename)
  8.     (setq Arr (vlax-invoke-method stream 'read (vlax-get stream 'SIZE)));read stream
  9.     (vlax-invoke stream 'close)
  10.     (vlax-release-object stream)
  11.     (vlax-safearray->list (vlax-variant-value arr))                        ;if a large size file ,it will take a long time in this step
  12.   )
  13.   ;;Write to a Binary  file from a text stream
  14.   (defun WriteBinary (FileName Array / stream)
  15.     (setq stream (vlax-create-object "ADODB.Stream"))
  16.     (vlax-put stream 'type 1)                                                 ;adTypeBinary
  17.     (vlax-invoke stream 'open)                                                ;adModeRead  =1 adModeWrite  =2 adModeReadWrite =3
  18.     (vlax-invoke-method stream 'Write array)                                ;write stream
  19.     (vlax-invoke stream 'saveToFile fileName 2)                                ;save
  20.     (vlax-invoke stream 'close)
  21.     (vlax-release-object stream)
  22.   )
  23.         
  24.   (setq path (getfiled "Please select a binary file:" "c:/" "" 8 ))     ;get file path
  25.   (setq f (open "C:\\test.txt" "W"))
  26.   (setq data (readBinary path))
  27.   (princ data f)
  28.   (close F)

  29.   ;;(setq stream (vl-get-resource "test"))                              ;we can wrap this text file into .vlx file
  30.   (setq f (open "C:\\test.txt" "R"))                                           ;open for read
  31.   (setq l "")
  32.   (while (setq s (read-line f))
  33.     (setq l (strcat l s))
  34.   )
  35.   (setq array (read l))
  36.   (close f)
  37.   
  38.   (setq dat (vlax-make-safearray 17 (cons 0 (1- (length array)))))             ;17 for unsigned char
  39.   (vlax-safearray-fill dat array)
  40.   (setq bin (vlax-make-variant dat))
  41.   (writeBinary "C:\\test.jpg" bin)                                        ;write binary file.
  42. )


XMLHTTP
An example shows how to Get your IP and get text from an URL

  1. ;;;
  2. (defun C:getIp (/ path http url web objXML file str s1 s2)
  3.   (setq path (strcat (getSpecialPath 1) "\\msxml6.dll"))
  4.   (if (not xc-NODE_TEXT)
  5.     (vlax-import-type-library
  6.       :tlb-filename  path
  7.       :methods-prefix "xm-"
  8.       :properties-prefix "xp-"
  9.       :constants-prefix "xc-"
  10.     )
  11.   )
  12.   (setq http (vlax-create-object "Msxml2.XMLHTTP"))        ;Microsoft.XMLHTTP or MSXML2.ServerXMLHTTP
  13.   (setq url " http://www.ip138.com/ip2city.asp")         ;the link of URL
  14.   (xm-open http "GET" url :vlax-false)                        ;the open method
  15.   (xm-send http)

  16.   
  17.   (setq str (xp-get-responseText http))                        ;get text from URL
  18.   (setq s1  (vl-string-position (ascii "[") str))
  19.   (setq s2  (vl-string-position (ascii "]") str))
  20.   (princ "\nYour IP Address is:")
  21.   (princ (substr str (+ s1 2) (- s2 s1 1)))
  22.   (vlax-release-object http)

  23.   ;;Get text from a Link
  24.   (setq web (getstring "\nPlease enter URL:"))
  25.   (setq objXML (vlax-create-object "MSXML2.ServerXMLHTTP"))
  26.   (xm-open objXML "GET" web :vlax-false)
  27.   (xm-send objXML)
  28.   (setq str (XP-GET-RESPONSETEXT objXML))                ;(xp-get-respon**ML http)
  29.                                                         ;(xp-get-responseStream http)
  30.                                                         ;(xp-get-responseBody http)
  31.   (setq file (vl-filename-mktemp "c:\\1.html"))
  32.   (setq file (open file "W"))
  33.   (princ str file)
  34.   (close file)
  35.   (vlax-release-object objXML)
  36.   (princ)
  37. )


WIA
An example shows how to change a picture file

  1. (defun c:img(/ path Img IPr vec cnt col old val fil i new)
  2.   (setq path (strcat (getSpecialPath 1) "\\wiaaut.dll"))
  3.   (if (not ic-actionEvent)
  4.     (vlax-import-type-library
  5.       :tlb-filename  path
  6.       :methods-prefix "im-"
  7.       :properties-prefix "ip-"
  8.       :constants-prefix "ic-"
  9.     )
  10.   )
  11.   (setq Img (vlax-create-object "WIA.ImageFile"))
  12.   (setq IPr  (vlax-create-object "WIA.ImageProcess"))
  13.   (im-loadfile Img "C:\\1.bmp")
  14.   (setq vec (ip-get-ARGBData Img))
  15.   (setq cnt (ip-get-count vec))
  16.   (setq col (vlax-make-variant -2147418367))         ;-2147418368 &HFFFF00FF
  17.                                                   ;'opaque pink (A=255,R=255,G=0,B=255)
  18.   (setq i 1)
  19.   (repeat (/ cnt 3)
  20.     (setq old (ip-get-item vec i))
  21.     (setq val (vlax-variant-value old))
  22.     (setq val (- val))
  23.     (ip-put-item vec i val)                          ;4294967295
  24.     (setq i (+ i 3))
  25.   )
  26.   (setq fil (ip-get-Filters IPr))
  27.   (im-add fil (ip-get-filterID (ip-get-item (ip-get-filterinfos IPr) "ARGB")) 0)
  28.   (ip-put-value (ip-get-item (ip-get-Properties (ip-get-item fil 1)) "ARGBData") vec)
  29.   (setq new (im-apply  IPr Img))
  30.   (im-savefile new "C:\\2.bmp")

  31.   (vlax-release-object Img)
  32.   (vlax-release-object IPr)
  33.   (vlax-release-object vec)
  34.   (vlax-release-object fil)
  35.   (vlax-release-object new)
  36. )


Scriptlet.TypeLib

;;;Generate a GUID

  1. (defun C:GUID (/ objSLTL str)
  2.   (setq objSLTL (vlax-create-object "Scriptlet.TypeLib"))
  3.   (setq str (vlax-get objSLTL 'GUID))
  4.   (vlax-release-object objSLTL)
  5.   str
  6. )

评分

参与人数 1D豆 +5 收起 理由
newer + 5 很给力!经验;技术要点;资料分享奖!

查看全部评分

论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!

已领礼包: 2963个

财富等级: 家财万贯

发表于 2018-1-4 22:44:26 | 显示全部楼层
好东西,谢谢分享!
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 25个

财富等级: 恭喜发财

发表于 2018-1-4 23:41:57 | 显示全部楼层
我发现我不懂英语
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 19个

财富等级: 恭喜发财

 楼主| 发表于 2018-1-4 23:43:01 | 显示全部楼层

也没几行英语,看代码就是了。
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 6468个

财富等级: 富甲天下

发表于 2018-1-5 00:00:56 | 显示全部楼层
谢谢分享。
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复

使用道具 举报

已领礼包: 23个

财富等级: 恭喜发财

发表于 2018-1-5 00:06:54 来自手机 | 显示全部楼层
来看看飞鸟大神的文章
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

发表于 2018-1-5 09:15:42 | 显示全部楼层
向高手学习
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 1393个

财富等级: 财源广进

发表于 2018-1-5 09:43:56 | 显示全部楼层
谢谢分享。
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复

使用道具 举报

已领礼包: 5586个

财富等级: 富甲天下

发表于 2018-1-5 15:33:10 | 显示全部楼层
感谢楼主分享!
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

发表于 2018-4-16 17:15:10 | 显示全部楼层
感謝樓主分享~~正需要這類訊息
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 166个

财富等级: 日进斗金

发表于 2018-12-13 14:53:53 | 显示全部楼层
来学习一下
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

发表于 2020-9-11 23:21:55 | 显示全部楼层
so good,3Q very much
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 195个

财富等级: 日进斗金

发表于 2021-10-15 16:17:25 | 显示全部楼层
kkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 57个

财富等级: 招财进宝

发表于 2021-10-19 09:10:57 | 显示全部楼层
淘这些老的贴子就跟淘宝一样啊
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 1999个

财富等级: 堆金积玉

发表于 2023-2-27 13:46:52 | 显示全部楼层
dear sir,

thanks for sharing
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|申请友链|Archiver|手机版|小黑屋|辽公网安备|晓东CAD家园 ( 辽ICP备15016793号 )

GMT+8, 2024-4-26 20:13 , Processed in 0.233548 second(s), 57 queries , Gzip On.

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表