cwprintocx.cpp
上传用户:smsj_tj
上传日期:2022-05-05
资源大小:187k
文件大小:5k
源码类别:

打印编程

开发平台:

Visual C++

  1. // Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
  2. // NOTE: Do not modify the contents of this file.  If this class is regenerated by
  3. //  Microsoft Visual C++, your modifications will be overwritten.
  4. #include "stdafx.h"
  5. #include "cwprintocx.h"
  6. /////////////////////////////////////////////////////////////////////////////
  7. // CCWPrintOcx
  8. IMPLEMENT_DYNCREATE(CCWPrintOcx, CWnd)
  9. /////////////////////////////////////////////////////////////////////////////
  10. // CCWPrintOcx properties
  11. /////////////////////////////////////////////////////////////////////////////
  12. // CCWPrintOcx operations
  13. short CCWPrintOcx::SetActiva()
  14. {
  15. short result;
  16. InvokeHelper(0x1, DISPATCH_METHOD, VT_I2, (void*)&result, NULL);
  17. return result;
  18. }
  19. void CCWPrintOcx::SetListCtrlBodyFont(VARIANT* logfont)
  20. {
  21. static BYTE parms[] =
  22. VTS_PVARIANT;
  23. InvokeHelper(0x2, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  24.  logfont);
  25. }
  26. void CCWPrintOcx::SetSpan(short sSpan)
  27. {
  28. static BYTE parms[] =
  29. VTS_I2;
  30. InvokeHelper(0x3, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  31.  sSpan);
  32. }
  33. void CCWPrintOcx::AddHeadTitle(short sFontSize, LPCTSTR lFontName, LPCTSTR lChangeLine, LPCTSTR lFontB, short sX, LPCTSTR lTitleHead)
  34. {
  35. static BYTE parms[] =
  36. VTS_I2 VTS_BSTR VTS_BSTR VTS_BSTR VTS_I2 VTS_BSTR;
  37. InvokeHelper(0x4, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  38.  sFontSize, lFontName, lChangeLine, lFontB, sX, lTitleHead);
  39. }
  40. void CCWPrintOcx::SetReportColHead(short sFontSize, LPCTSTR lFontB, LPCTSTR lFontName)
  41. {
  42. static BYTE parms[] =
  43. VTS_I2 VTS_BSTR VTS_BSTR;
  44. InvokeHelper(0x5, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  45.  sFontSize, lFontB, lFontName);
  46. }
  47. void CCWPrintOcx::SetReportColBody(short sFontSize, LPCTSTR lFontB, LPCTSTR lFontName)
  48. {
  49. static BYTE parms[] =
  50. VTS_I2 VTS_BSTR VTS_BSTR;
  51. InvokeHelper(0x6, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  52.  sFontSize, lFontB, lFontName);
  53. }
  54. BOOL CCWPrintOcx::AddColInfo(short sFontWidth, LPCTSTR lAlign, BOOL bDisplay, BOOL bPrint, LPCTSTR lTotalType, LPCTSTR lColType, LPCTSTR lColName, LPCTSTR lFieldName, short sDecWidth)
  55. {
  56. BOOL result;
  57. static BYTE parms[] =
  58. VTS_I2 VTS_BSTR VTS_BOOL VTS_BOOL VTS_BSTR VTS_BSTR VTS_BSTR VTS_BSTR VTS_I2;
  59. InvokeHelper(0x7, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
  60. sFontWidth, lAlign, bDisplay, bPrint, lTotalType, lColType, lColName, lFieldName, sDecWidth);
  61. return result;
  62. }
  63. short CCWPrintOcx::CreateAndOpen()
  64. {
  65. short result;
  66. InvokeHelper(0x8, DISPATCH_METHOD, VT_I2, (void*)&result, NULL);
  67. return result;
  68. }
  69. short CCWPrintOcx::AddFieldValue(LPCTSTR lFieldValue)
  70. {
  71. short result;
  72. static BYTE parms[] =
  73. VTS_BSTR;
  74. InvokeHelper(0x9, DISPATCH_METHOD, VT_I2, (void*)&result, parms,
  75. lFieldValue);
  76. return result;
  77. }
  78. long CCWPrintOcx::ShowModal()
  79. {
  80. long result;
  81. InvokeHelper(0xa, DISPATCH_METHOD, VT_I4, (void*)&result, NULL);
  82. return result;
  83. }
  84. void CCWPrintOcx::SetBottomHeight(short sBottomHeight)
  85. {
  86. static BYTE parms[] =
  87. VTS_I2;
  88. InvokeHelper(0xb, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  89.  sBottomHeight);
  90. }
  91. void CCWPrintOcx::SetLineSpace(short sLineSpace)
  92. {
  93. static BYTE parms[] =
  94. VTS_I2;
  95. InvokeHelper(0xc, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  96.  sLineSpace);
  97. }
  98. void CCWPrintOcx::SetColSpace(short sColSpace)
  99. {
  100. static BYTE parms[] =
  101. VTS_I2;
  102. InvokeHelper(0xd, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  103.  sColSpace);
  104. }
  105. void CCWPrintOcx::SetLeftSpace(short sLeftSpace)
  106. {
  107. static BYTE parms[] =
  108. VTS_I2;
  109. InvokeHelper(0xe, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  110.  sLeftSpace);
  111. }
  112. void CCWPrintOcx::AddHeadTitleEx(long iWidth, long iHeight, LPCTSTR lFontName, LPCTSTR cFlags, LPCTSTR cWeight, long lx, LPCTSTR lTitleName)
  113. {
  114. static BYTE parms[] =
  115. VTS_I4 VTS_I4 VTS_BSTR VTS_BSTR VTS_BSTR VTS_I4 VTS_BSTR;
  116. InvokeHelper(0xf, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  117.  iWidth, iHeight, lFontName, cFlags, cWeight, lx, lTitleName);
  118. }
  119. short CCWPrintOcx::BeginCx()
  120. {
  121. short result;
  122. InvokeHelper(0x10, DISPATCH_METHOD, VT_I2, (void*)&result, NULL);
  123. return result;
  124. }
  125. void CCWPrintOcx::SetReportHeadFontWeight(LPCTSTR sWeight)
  126. {
  127. static BYTE parms[] =
  128. VTS_BSTR;
  129. InvokeHelper(0x11, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  130.  sWeight);
  131. }
  132. void CCWPrintOcx::SetReportBodyFontWeight(LPCTSTR sWeight)
  133. {
  134. static BYTE parms[] =
  135. VTS_BSTR;
  136. InvokeHelper(0x12, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  137.  sWeight);
  138. }
  139. void CCWPrintOcx::SetPaperSize(short sPaperSize)
  140. {
  141. static BYTE parms[] =
  142. VTS_I2;
  143. InvokeHelper(0x13, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
  144.  sPaperSize);
  145. }
  146. void CCWPrintOcx::AboutBox()
  147. {
  148. InvokeHelper(0xfffffdd8, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
  149. }