SystemFunctionList.cpp 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. // SystemFunctionList.cpp : implementation file
  2. //
  3. #include "stdafx.h"
  4. #include "icredit.h"
  5. #include "SystemFunctionList.h"
  6. #ifdef _DEBUG
  7. #define new DEBUG_NEW
  8. #undef THIS_FILE
  9. static char THIS_FILE[] = __FILE__;
  10. #endif
  11. /////////////////////////////////////////////////////////////////////////////
  12. // CSystemFunctionList dialog
  13. CSystemFunctionList::CSystemFunctionList(CWnd* pParent /*=NULL*/)
  14. : CDialog(CSystemFunctionList::IDD, pParent)
  15. {
  16. //{{AFX_DATA_INIT(CSystemFunctionList)
  17. // NOTE: the ClassWizard will add member initialization here
  18. //}}AFX_DATA_INIT
  19. }
  20. void CSystemFunctionList::DoDataExchange(CDataExchange* pDX)
  21. {
  22. CDialog::DoDataExchange(pDX);
  23. //{{AFX_DATA_MAP(CSystemFunctionList)
  24. DDX_Control(pDX, IDC_FUNCTIONLIST, m_ctrlFunctionList);
  25. //}}AFX_DATA_MAP
  26. }
  27. BEGIN_MESSAGE_MAP(CSystemFunctionList, CDialog)
  28. //{{AFX_MSG_MAP(CSystemFunctionList)
  29. //}}AFX_MSG_MAP
  30. END_MESSAGE_MAP()
  31. /////////////////////////////////////////////////////////////////////////////
  32. // CSystemFunctionList message handlers
  33. BOOL CSystemFunctionList::OnInitDialog()
  34. {
  35. CDialog::OnInitDialog();
  36. // TODO: Add extra initialization here
  37. const LPSTR NzbFunctionName[] = {
  38. "Array",
  39. "Asc",
  40. "Atn",
  41. "CBool",
  42. "CByte",
  43. "CCur",
  44. "CDate",
  45. "CDbl",
  46. "Chr",
  47. "CInt",
  48. "CLng",
  49. "Cos",
  50. "CreateObject",
  51. "CSng",
  52. "CStr",
  53. "Date",
  54. "DateAdd",
  55. "DateDiff",
  56. "DatePart",
  57. "DateSerial",
  58. "DateValue",
  59. "Day",
  60. "Exp",
  61. "Filter",
  62. "Fix",
  63. "FormatCurrency",
  64. "FormatDateTime",
  65. "FormatNumber",
  66. "FormatPercent",
  67. "GetObject",
  68. "Hex",
  69. "Hour",
  70. "InputBox",
  71. "InStr",
  72. "InStrRev",
  73. "Int",
  74. "IsArray",
  75. "IsDate",
  76. "IsEmpty",
  77. "IsNull",
  78. "IsNumeric",
  79. "IsObject",
  80. "Join",
  81. "LBound",
  82. "LCase",
  83. "Left",
  84. "Len",
  85. "LoadPicture",
  86. "Log",
  87. "LTrim",
  88. "Mid",
  89. "Minute",
  90. "Month",
  91. "MonthName",
  92. "MsgBox",
  93. "Now",
  94. "Oct",
  95. "Replace",
  96. "RGB",
  97. "Right",
  98. "Rnd",
  99. "Round",
  100. "RTrim",
  101. "Second",
  102. "Sgn",
  103. "Sin",
  104. "Sleeps",
  105. "Space",
  106. "Split",
  107. "Sqr",
  108. "StrComp",
  109. "StrReverse",
  110. "String",
  111. "Tan",
  112. "Time",
  113. "TimeSerial",
  114. "TimeValue",
  115. "Trim",
  116. "TypeName",
  117. "UBound",
  118. "UCase",
  119. "VarType",
  120. "Weekday",
  121. "WeekdayName",
  122. "Year"
  123. };
  124. for(int i=0;i<85;i++)
  125. m_ctrlFunctionList.AddString(NzbFunctionName[i]);
  126. return TRUE; // return TRUE unless you set the focus to a control
  127. // EXCEPTION: OCX Property Pages should return FALSE
  128. }
  129. void CSystemFunctionList::OnOK()
  130. {
  131. // TODO: Add extra validation here
  132. m_ctrlFunctionList.GetText(m_ctrlFunctionList.GetCurSel(),m_strFunction);
  133. CDialog::OnOK();
  134. }