Hỏi/ Thắc mắc - Lệnh CMD trong Office? | VN-Zoom | Cộng đồng Chia Sẻ Kiến Thức Công Nghệ và Phần Mềm Máy Tính

Adblocker detected! Please consider reading this notice.

We've detected that you are using AdBlock Plus or some other adblocking software which is preventing the page from fully loading.

We don't have any banner, Flash, animation, obnoxious sound, or popup ad. We do not implement these annoying types of ads!

We need money to operate the site, and almost all of it comes from our online advertising.

Please add https://vn-z.vn to your ad blocking whitelist or disable your adblocking software.

×

Hỏi/ Thắc mắc Lệnh CMD trong Office?

dungltcd

Lạt Ma
Ai cho em xin một số lệnh cmd với ạ. Em là newbie. Em cám ơn
- Lệnh convert Office 2019 Retail to VL
- Lệnh kiểm tra trạng thái Office
- Lệnh xoá key cũ
- Lệnh nhập key

Hoặc bạn chạy lệnh này trong CMD admin là có tất.

Mã:
cscript “C:\Program Files\Microsoft Office\Office16\ospp.vbs” /?

Nó Đây tôi post luôn.

Office 2016 Client Software License Management Tool

Usage
cscript ospp.vbs /Option:Value ComputerName User Password
ComputerName: Name of remote computer. If a computer name is not passed local computer is used.
User: Account with required privilege on remote computer.
Password: Password for the account. If a User account and password are not passed current credentials are used.
Value: Required for outlined options.


Global /Options Description
/actActivate installed Office product keys.
/inpkey:valueInstall a product key (replaces existing key) with user-provided product key. Value parameter applies.
/unpkey:valueUninstall an installed product key with user-provided partial product key (as displayed by the /dstatus option). Value parameter applies.
/inslic:valueInstall a license with user-provided path to the .xrm-ms license. Value parameter applies.
/dstatusDisplay license information for installed product keys.
/dstatusallDisplay license information for installed licenses.
/dhistoryacterrDisplay MAK/Retail activation failure history.
/dinstidDisplay installation ID for offline activation.
/actcid:valueActivate product with user-provided confirmation ID. Value parameter applies.
/rearmReset the licensing status for all installed Office product keys.
/rearm:valueReset the licensing status for an Office license with user provided SKUID value (as displayed by the /dstatus opton). Value parameter applies.
/ddescr:valueDisplay the description for a user-provided error code. Value parameter applies.
KMS client /Options Description
/dhistorykmsDisplay KMS client activation history.
/dcmidDisplay KMS client machine ID (CMID).
/sethst:valueSet a KMS host name with user-provided host name. Value parameter applies.
/setprt:valueSet a KMS port with user-provided port number. Value parameter applies.
/remhstRemove KMS host name (sets port to default).
/cachst:valuePermit or deny KMS host caching. Value parameter applies (TRUE or FALSE).
/actype:valueSet volume activation type. Value parameter applies. (Windows 8 and above support only)
Values: 1 (for AD) or 2 (for KMS) or 3 (for Token) or 0 (for all).
/skms-domain:valueSet the specific DNS domain in which all KMS SRV records can be found. This setting has no effect if the specific single KMS host is set via /sethst option. Value parameter applies. (Windows 8 and above support only)
Value:FQDN
/ckms-domainClear the specific DNS domain in which all KMS SRV records can be found. The specific KMS host will be used if set via /sethst option. Otherwise default KMS auto-discovery will be used. (Windows 8 and above support only)
Token /Options Description
/dtokilsDisplay installed token-based activation issuance licenses.
/rtokil:valueUninstall an installed token-based activation issuance license with user-provided license id (as displayed by the /dtokils option). Value parameter applies.
/stokflagSet token-based activation only flag. (Windows 7 support only)
/ctokflagClear token-based activation only flag. (Windows 7 support only)
/dtokcertsDisplay token-based activation certificates.
/tokact:value1:value2Token activate with a user-provided thumbprint (as displayed by the /dtokcerts option) and a user-provided PIN (optional). Value parameter applies.
Prior to running ospp.vbs ensure that:

Windows firewall allows WMI traffic on remote computer.

You have or pass credentials with required permissions on remote computer.

Cmd.exe is elevated (right click > Run as administrator).

Sample Usage

cscript ospp.vbs /act 'Activate Office on local computer.

cscript ospp.vbs /act mypc1 'Activate Office on remote computer mypc1 with current credentials.

cscript ospp.vbs /inpkey:MFKXT-F6DT2-THMRV-KDWH2-TCDTC 'Install an Office product key on local computer.

cscript ospp.vbs /inslic:\\myserver\licenses\tail.xrm-ms 'Install license on local computer.

cscript ospp.vbs /inslic:"\\myserver\work licenses\office2016 tail.xrm-ms" mypc1 'Install license on remote computer mypc1. Note the path is enclosed in "" since the value contains spaces.

cscript ospp.vbs /ddescr:0xC004F009 'Display the description for error code.

cscript ospp.vbs /actype:1 'Set volume activation type to Active Directory only.

/Token only

cscript ospp.vbs /rtokil:4476b20e 'Uninstall an issuance license with license ID.

cscript ospp.vbs /tokact:96DE6755ABE0BC7D398E96C3AA3C7BFE8B565248 'Token activate with thumbprint.

cscript ospp.vbs /tokact:56AE6755AAB0BC7D398E96C3AA3C7BFE8B565256:54344 'Token activate with thumbprint & PIN.
 

hoabomby

Gà con

Hoặc bạn chạy lệnh này trong CMD admin là có tất.

Mã:
cscript “C:\Program Files\Microsoft Office\Office16\ospp.vbs” /?

Nó Đây tôi post luôn.

Đã run cmd by admin và gõ cú pháp như hình nhưng báo lỗi
Có phải di chuyển đường dẫn về chỗ Office 16 bằng lệnh cd ko ?
Xem trong folder Office 16 thì có file ospp

Unf23f2titled.png
 

@sec0

Rìu Chiến Vàng Chấm
Đã run cmd by admin và gõ cú pháp như hình nhưng báo lỗi
Có phải di chuyển đường dẫn về chỗ Office 16 bằng lệnh cd ko ?
Xem trong folder Office 16 thì có file ospp

Xem phần đính kèm 15823
Vì office của bạn nó ko nằm trong C :\program file mà nó nằm ở chỗ khác do đó CMD tìm ko thấy .
Bạn xem Office của bạn nó cư ngụ ở đâu thì trỏ đường dẫn cho đúng
 

dungltcd

Lạt Ma
Vì office của bạn nó ko nằm trong C :\program file mà nó nằm ở chỗ khác do đó CMD tìm ko thấy .
Bạn xem Office của bạn nó cư ngụ ở đâu thì trỏ đường dẫn cho đúng
C2R thì ko ở đó thì chỉ có ở đây, vì nó đâu có cho mình chọn directory.
"C:\Program Files (x86)"
 


Top