⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 subject_20235.htm

📁 一些关于vc的问答
💻 HTM
字号:
<p>
序号:20235 发表者:小许 发表日期:2002-11-04 19:14:46
<br>主题:如何在打印中设置打印方向
<br>内容:CPrintInfo* pInfo;<BR>DEVMODE* mode;<BR>mode=pInfo-&gt;m_pPD-&gt;GetDevMode();<BR>mode-&gt;dmorientation=DEMORIENT_LANDSCAPE;&nbsp;&nbsp;//现改为横向<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //默认是DMORIENT_PORTAIT<BR>以上代码是放在OnBeginPrinting还是放在OnPreparePrinting里,为何都达不到预期的效果??<BR>就是在第一次打印时还是原样,到第二次打印才改变!!<BR>这是为什么,请各侠大虾帮帮忙...<BR>
<br><a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p>
<hr size=1>
<blockquote><p>
回复者:Norton AntivVirus 回复日期:2002-11-04 19:33:50
<br>内容:CPrintDialog::GetDevMode <BR>LPDEVMODE GetDevMode( ) const;<BR><BR>Return Value<BR><BR>The DEVMODE data structure, which contains information about the device initialization and environment of a print driver. You must unlock the memory taken by this structure with the WindowsGlobalUnlock function, which is described in the Platform SDK.<BR><BR>Remarks<BR><BR>Call this function after calling DoModal to retrieve information about the printing device.<BR><BR><BR><BR>就是要在调用CPrintDialog 的DoModal函数以后,再设置你所需要的信息
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
<font color=red>答案被接受</font><br>回复者:徐景周 回复日期:2002-11-05 10:10:10
<br>内容:参看下面:<BR>http://www.copathway.com/cndevforum/subject_view.asp?subject_id=16408&forum_id=<BR><BR>http://www.copathway.com/cndevforum/subject_view.asp?subject_id=17143&forum_id=
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -