标题: [其他] BAT如何从systeminfo命令中截取所需的内容到记事本? [打印本页]
作者: adrien0901 时间: 2013-9-17 22:26 标题: BAT如何从systeminfo命令中截取所需的内容到记事本?
如何从systeminfo命令中截取所需的内容到记事本,谢谢。
作者: DAIC 时间: 2013-9-17 22:39
请把你的systeminfo的结果贴出来看看,并说清楚需要截取哪些内容。
作者: adrien0901 时间: 2013-9-18 09:32
请把你的systeminfo的结果贴出来看看,并说清楚需要截取哪些内容。
DAIC 发表于 2013-9-17 22:39
Host Name: ADRIENCUI
OS Name: Microsoft Windows 8 Enterprise
OS Version: 6.2.9200 N/A Build 9200
OS Manufacturer: Microsoft Corporation
OS Configuration: Standalone Workstation
OS Build Type: Multiprocessor Free
Registered Owner: Adrien.Cui
Registered Organization:
Product ID: 00178-50101-11863-AA765
Original Install Date: 12/1/2012, 1:52:54 PM
System Boot Time: 9/11/2013, 3:23:42 PM
System Manufacturer: Hewlett-Packard
System Model: HP ProBook 4326s
System Type: x64-based PC
Processor(s): 1 Processor(s) Installed.
[01]: AMD64 Family 16 Model 6 Stepping 3 AuthenticAMD ~2300 Mhz
BIOS Version: Hewlett-Packard 68CPO Ver. F.0B, 12/6/2010
Windows Directory: C:\Windows
System Directory: C:\Windows\system32
Boot Device: \Device\HarddiskVolume1
System Locale: zh-cn;Chinese (China)
Input Locale: zh-cn;Chinese (China)
Time Zone: (UTC+08:00) Beijing, Chongqing, Hong Kong, Urumqi
Total Physical Memory: 5,878 MB
Available Physical Memory: 3,787 MB
Virtual Memory: Max Size: 6,838 MB
Virtual Memory: Available: 4,315 MB
Virtual Memory: In Use: 2,523 MB
Page File Location(s): C:\pagefile.sys
Domain: WORKGROUP
Logon Server: \\ADRIENCUI
Hotfix(s): 97 Hotfix(s) Installed.
[01]: KB2712101_Microsoft-Windows-CameraCodec-Package
[02]: KB2727528
[03]: KB2729462
[04]: KB2736693
[05]: KB2737084
[06]: KB2742614
[07]: KB2742616
[08]: KB2750149
[09]: KB2753842
[10]: KB2756872
[11]: KB2756923
[12]: KB2757638
[13]: KB2758246
[14]: KB2761094
[15]: KB2761226
[16]: KB2764870
[17]: KB2768703
[18]: KB2769034
[19]: KB2769165
[20]: KB2769166
[21]: KB2770041
[22]: KB2770660
[23]: KB2770917
[24]: KB2771431
[25]: KB2771744
[26]: KB2771821
[27]: KB2777166
[28]: KB2777294
[29]: KB2778171
[30]: KB2779768
[31]: KB2780342
[32]: KB2780523
[33]: KB2781197
[34]: KB2782419
[35]: KB2783251
[36]: KB2784160
[37]: KB2785094
[38]: KB2785220
[39]: KB2788350
[40]: KB2789649
[41]: KB2789650
[42]: KB2790655
[43]: KB2790920
[44]: KB2792009
[45]: KB2795944
[46]: KB2798162
[47]: KB2800033
[48]: KB2800088
[49]: KB2803821
[50]: KB2804583
[51]: KB2804584
[52]: KB2805222
[53]: KB2805227
[54]: KB2805966
[55]: KB2807986
[56]: KB2808679
[57]: KB2808735
[58]: KB2811660
[59]: KB2812829
[60]: KB2813430
[61]: KB2820197
[62]: KB2820330
[63]: KB2821895
[64]: KB2822241
[65]: KB2823233
[66]: KB2823516
[67]: KB2829254
[68]: KB2829361
[69]: KB2829530
[70]: KB2830290
[71]: KB2832418
[72]: KB2833958
[73]: KB2833959
[74]: KB2835361
[75]: KB2835364
[76]: KB2836187
[77]: KB2836946
[78]: KB2836947
[79]: KB2836988
[80]: KB2837385
[81]: KB2838727
[82]: KB2839894
[83]: KB2840632
[84]: KB2840633
[85]: KB2844289
[86]: KB2845187
[87]: KB2845533
[88]: KB2845690
[89]: KB2846071
[90]: KB2847928
[91]: KB2850674
[92]: KB2850851
[93]: KB2851234
[94]: KB2853915
[95]: KB2856758
[96]: KB2857645
[97]: KB2859541
Network Card(s): 4 NIC(s) Installed.
[01]: Broadcom 802.11n Network Adapter
Connection Name: Wi-Fi
DHCP Enabled: Yes
DHCP Server: 172.16.2.1
IP address(es)
[01]: 172.16.2.27
[02]: Realtek PCIe GBE Family Controller
Connection Name: Ethernet
Status: Media disconnected
[03]: VMware Virtual Ethernet Adapter for VMnet1
Connection Name: VMware Network Adapter VMnet1
DHCP Enabled: No
IP address(es)
[01]: 192.168.25.1
[02]: fe80::45cd:8198:2158:a78
[04]: VMware Virtual Ethernet Adapter for VMnet8
Connection Name: VMware Network Adapter VMnet8
DHCP Enabled: No
IP address(es)
[01]: 192.168.5.1
[02]: fe80::1c31:70e9:48b5:c3ae
Hyper-V Requirements: VM Monitor Mode Extensions: Yes
Virtualization Enabled In Firmware: Yes
Second Level Address Translation: Yes
Data Execution Prevention Available: Yes
需要截取的是计算机名称,IP地址,总的内存大小,谢谢。
作者: adrien0901 时间: 2013-9-18 10:11
systeminfo |findstr /i "host Total Physical">>c:\1.txt
但有些需要截取的字符串有空格,不知道该怎么操作。
作者: adrien0901 时间: 2013-9-18 10:37
systeminfo |findstr /i ""host" "Total Physical"">c:\2.txt
这样也不行
作者: weichenxiehou 时间: 2013-9-18 11:08
回复 5# adrien0901
systeminfo|find "Host Name"或systeminfo|findstr /c:"Host Name"
作者: terse 时间: 2013-9-18 14:16
- systeminfo|findstr /ic:"Total Physical Memory:" /c:"host"
复制代码
欢迎光临 批处理之家 (http://bathome.net./) |
Powered by Discuz! 7.2 |