1. Trang chủ
  2. » Công Nghệ Thông Tin

Excel Add-in Development in C/C++ Applications in Finance phần 1 ppt

40 378 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 40
Dung lượng 446,95 KB

Nội dung

[...]... 98 98 99 99 10 0 10 1 10 2 10 3 10 5 10 5 10 5 10 6 10 7 11 1 11 8 11 8 11 9 12 1 12 1 12 6 12 6 12 7 13 0 13 1 13 2 13 5 13 8 14 0 14 2 14 5 15 0 15 5 15 7 Contents 6.9 6 .10 Initialising xlopers Missing arguments ix 15 7 16 0 7 Memory Management 7 .1 Excel stack space limitations 7.2 Static add -in memory and multiple Excel instances 7.3 Getting Excel to free memory allocated by Excel 7.3 .1 Freeing xloper memory within the DLL call... 17 3 17 4 17 6 17 8 17 8 18 0 18 2 18 3 18 5 18 6 18 8 18 9 18 9 19 0 19 1 19 1 19 1 19 4 19 5 19 6 19 8 19 9 19 9 19 9 x Contents 8.7.2 8.7.3 8.7.4 8.7.5 8.7.6 8.7.7 8.8 8.9 8 .10 Getting the available stack space: xlStack Converting one xloper type to another: xlCoerce Setting cell values from a command: xlSet Getting the internal ID of a named sheet: xlSheetId Getting a sheet name from its internal ID: xlSheetNm Yielding... 8 .10 .7 Getting the defined name of a range of cells: xlfGetDef 8 .10 .8 Getting a list of named ranges: xlfNames 2 01 2 01 203 204 205 206 207 207 208 209 210 210 211 212 213 213 214 214 215 215 215 217 2 21 2 21 222 225 227 233 234 234 235 236 237 239 239 2 41 2 41 242 244 245 247 248 Contents 8 .11 8 .12 8 .13 8 .14 Working with Excel menus 8 .11 .1 Menu bars and ID numbers and menu and command specifiers 8 .11 .2... 10 .7 Building and reading discount curves 10 .8 Building trees and lattices 10 .9 Quasi-random number sequences 10 .10 Generating correlated random samples 10 .11 Monte Carlo simulation 10 .11 .1 Using Excel and VBA only 10 .11 .2 Using Excel and C/C++ only 10 .11 .3 Using worksheet functions only 10 .12 Calibration 335 335 344 3 51 353 357 363 3 71 374 374 375 376 377 379 3 81 3 81 References 383 Web Links and Other... 4 .11 4 .12 Accessing DLL functions from VB Accessing DLL functions from Excel 5 Turning DLLs into XLLs: The Add -in Manager Interface 5 .1 Adding the Excel library and header files to a DLL project 5.2 What does the Add -in Manager do? 5.2 .1 Loading and unloading installed add-ins 5.2.2 Active and inactive add-ins 5.2.3 Deleted add-ins and loading of inactivate add-ins 5.3 Creating an XLL: The xlAuto interface... xlfEnableCommand 8 .11 .10 Changing a menu command name: xlfRenameCommand 8 .11 .11 Deleting a command from a menu: xlfDeleteCommand 8 .11 .12 Deleting a custom menu: xlfDeleteMenu 8 .11 .13 Deleting a custom menu bar: xlfDeleteBar Working with toolbars 8 .12 .1 Getting information about a toolbar: xlfGetToolbar 8 .12 .2 Getting information about a tool button on a toolbar: xlfGetTool 8 .12 .3 Creating a new toolbar:... function 9 .10 .5 Organising the task list 9 .10 .6 Creating, deleting, suspending, resuming the thread 9 .10 .7 The task processing loop 9 .10 .8 The task interface and main functions 9 .10 .9 The polling command 9 .10 .10 Configuring and controlling the background thread 2 81 282 282 282 283 283 283 285 285 289 293 293 294 295 297 299 300 302 303 303 305 307 309 310 311 313 315 316 316 318 320 320 3 21 322 322 323 324... 330 3 31 Contents 9 .11 9 .10 .11 Other possible background thread applications and strategies How to crash Excel xiii 3 31 332 10 Example Add-ins and Financial Applications 10 .1 String functions 10 .2 Statistical functions 10 .3 Matrix functions – eigenvalues and eigenvectors 10 .4 Interpolation functions: lines, curves and splines 10 .5 Lookup and search functions 10 .6 Financial markets date functions 10 .7... 8.5 .10 Managing the data needed to register exported functions 8.5 .11 Getting and using the function’s register ID 8.5 .12 Un-registering a DLL function 8.6 Registering and un-registering DLL (XLL) commands 8.6 .1 Accessing XLL commands 8.6.2 Breaking execution of an XLL command 8.7 Functions defined for the C API only 8.7 .1 Freeing Excel- allocated memory within the DLL: xlFree 16 9 16 9 17 0 17 1 17 1 17 1 17 3... (context) menu groups 8 .11 .3 Getting information about a menu bar: xlfGetBar 8 .11 .4 Creating a new menu bar or restoring a default bar: xlfAddBar 8 .11 .5 Adding a menu or sub-menu: xlfAddMenu 8 .11 .6 Adding a command to a menu: xlfAddCommand 8 .11 .7 Displaying a custom menu bar: xlfShowBar 8 .11 .8 Adding/removing a check mark on a menu command: xlfCheckCommand 8 .11 .9 Enabling/disabling a custom command or . 376 10 .11 .1 Using Excel and VBA only 377 10 .11 .2 Using Excel and C/C++ only 379 10 .11 .3 Using worksheet functions only 3 81 10 .12 Calibration 3 81 References 383 Web Links and Other Resources 385 Index. and add -in functions 29 2 .11 .6 Data Table recalculation 31 2 .12 The Add -in Manager 32 2 .13 Loading and unloading add-ins 32 2 .13 .1 Add -in information 33 2 .14 Paste Function dialog 33 2 .14 .1 Function. y0 w0 h0" alt="" Excel Add -in Development in C/C++ Applications in Finance Steve Dalton Excel Add -in Development in C/C++ Wiley Finance Series For other titles in the Wiley Finance Series please

Ngày đăng: 05/08/2014, 10:21

Nguồn tham khảo

Tài liệu tham khảo Loại Chi tiết
2.6.7 Conversion of single-cell referencesExcel will convert a single-cell reference to the value of the cell referred to, unless it is being passed to a function that expects a reference as its parameter rather than a value.(Later chapters go into detail on such functions, but a simple example is ROW() , which extracts and returns the row number of a cell reference.) If an operator or function using the reference requires a different data type than that of the reference’s value, then Excel will also attempt to convert to the required type. (See next section for more detail.) For example, if a cell contains the formula =SUM(A1,B1) , with A1 containing the number 123 and B2 the string "456" , Excel will convert the reference A1 to the value of that cell, 123, and the reference B1 to the string "456" and then to the argument type expected by SUM() , the number 456 , leading finally to a result of 579 Sách, tạp chí
Tiêu đề: 456", Excel will convert the referenceA1to the value of that cell, 123,and the referenceB1to the string"456
2.6.9 Conversion of defined range namesWhere a cell formula contains a token that cannot be interpreted as a constant (either numeric or string within double-quotes) or a cell reference, Excel searches for a named range on the current sheet and then the current workbook. (See below for an explanation of the term current.) Sách, tạp chí
Tiêu đề: current
2.6.12 Operator evaluation precedence Table 2.9 Operator evaluation precedenceOperators (operation) NotesName lookup and substitutionReference-to-value and type conversion() and worksheet functions Evaluated left to right%, unary –ˆ =4^50% evaluates to 2*/Binary +−& =4+2&1+5="66" evaluates to TRUE Binary = , < , > , <= , >= , <> Evaluated left to right Sách, tạp chí
Tiêu đề: 66
2.7 EXCEL TERMINOLOGY: ACTIVE AND CURRENTExcel functions that provide information about a cell, a range of cells or a sheet in a workbook often make a distinction between the workbook, sheet or cell that the user is currently looking at, and the workbook, sheet or cell from which the function was called. 1 The same is true of commands that affect a workbook or one of its constituents. The terms active and current are used to make the distinction, which can be quite confusing. Here is a clear definition Sách, tạp chí
Tiêu đề: active"and "current
2.8 COMMANDS VERSUS FUNCTIONS IN EXCELThere is an important distinction in Excel between functions, represented by formulae in worksheet cells that may or may not take arguments but always return a value, and commands which are equivalent to a user doing something. For example, NOW() is a function: it returns a number representing the date and time right now. In contrast, the action taken by Excel to format a cell when a user presses a formatting icon on a toolbar is a command.1 There are other components that can be active, e.g., components of a chart that have been selected, which are not covered here Sách, tạp chí
Tiêu đề: always
2.6.8 Conversion of multi-cell range referencesSome functions will work equally well with single cell references and range references, for example, SUM(A1,B1,C1) gives the same result as SUM(A1:C1) . In the latter case, the SUM() function converts the range A1:C1 to a mixed type array of values and then iterates through that converting and summing values where possible. The work of handling the range argument is done within the code of the SUM() function Khác
2.6.10 Explicit type conversion functions: N() , T() , TEXT() , VALUE()Explicit type conversion is possible with the functions VALUE() and TEXT() with the advan- tage that TEXT() provides control over the text format where an implicit conversion does not. Type conversion can also be constrained with the functions N() and T() . Table 2.7 summarises the action of these functions on the basic data types Khác
2.6.11 Worksheet function argument type conversionExcel will attempt to convert arguments being passed to functions, regardless of whether they are Excel’s built-in worksheet functions, a third party’s add-in functions or user-defined VB functions. Worksheet functions can take as arguments any combination of the following Khác

TỪ KHÓA LIÊN QUAN