香港新浪網 MySinaBlog
Emily | 29th Sep 2006, 11:08 AM | WB & WS | (1760 Reads)

更改 Excel Codename

Sub RenameSheetCodeName()
On Error GoTo ErrChg
With ActiveSheet
    '.Name = "Sheet1"
    .Parent.VBProject.vbComponents(.CodeName).Properties("_CodeName") = "Sheet1"
End With
Exit Sub
ErrChg:
MsgBox Err.Number & ":=" & Err.Description, vbCritical
End Sub

CodeName


Emily | 25th Sep 2006, 10:53 AM | General | (2598 Reads)

SHUTDOWN-Windows Command

SHUTDOWN

Syntax        SHUTDOWN [logoff_option]  [/m \\Computer] [optionslogoff_option:

/i         Display the GUI (must be the first option)
/l         Log off. This cannot be used with /m or /d option
/s         Shutdown
/r         Shutdown and Restart
/a         Abort a system shutdown. 
            (only during the time-out period)

/p         Turn off the local computer with no time-out or warning
               (only with /d)
/h         Hibernate the local computer (only with /f )
/e         Document the reason for an unexpected shutdown of a computer 

options:
/m \\Computer : A remote computer to shutdown.
/t:xxx         : Time until system shutdown in seconds. 
The valid range is xxx=0-600 seconds. [default=30]
/c "Msg"       : An optional shutdown message [Max 127 chars]
/f             : Force running applications to close.
                 This will not prompt for File-Save in any open applications.
                 so will result in a loss of all unsaved data!!!
/d u:xx:yy     : List a USER reason code for the shutdown.
/d P:xx:yy     : List a PLANNED reason code for the shutdown. 
                   xx Specifies the major reason code (0-255)
                   yy Specifies the minor reason code (0-65536)
Options in bold are for Windows 2003 only
mySinaBlog 不支援斜線,斜線現用全形\取代 ,請改回。

Details: http://webtools.live2support.com/windows/shutdown.php

 


Emily | 23rd Sep 2006, 08:47 AM | General | (2239 Reads)
SUMPRODUCT is one of the most versatile functions provided in Excel. In its most basic form, SUMPRODUCT multiplies corresponding members in given arrays, and returns the sum of those products. This page discusses the classic use of SUMPRODUCT, how creativity and inbuilt flexibility has enabled it to evolve into a far more useful function, and explains some of the techniques being deployed. Finally, some examples of SUMPRODUCT show its versatility.

http://www.xldynamic.com/source/xld.SUMPRODUCT.html