荔园在线

荔园之美,在春之萌芽,在夏之绽放,在秋之收获,在冬之沉淀

[回到开始] [上一篇][下一篇]


发信人: tang (独孤九剑〖玄铁重剑〗), 信区: Program
标  题: [转载]  MSVC Digest - 17 Jan 1999 to 18 Jan 1999 (#1999-18)
发信站: BBS 荔园晨风站 (Tue Jan 19 16:45:21 1999), 站内信件

【 以下文字转载自 tang 的信箱 】
【 原文由 Automatic 所发表 】
There are 13 messages totalling 524 lines in this issue.

Topics of the day:

  1. regarding GetFieldValue() function
  2. Bit mask question
  3. CTabCtrl
  4. <No subject given> (3)
  5. Printing in Z-Fold
  6. SetViewportExtEx
  7. Creating EXCEL Documents in VC (3)
  8. DOC file format (2)

--------------------------------------------------------------------------
The MSVC list is hosted on a Windows NT(TM) machine running L-Soft
international's LISTSERV(R) software.  For subscription/signoff info
and archives, see http://peach.ease.lsoft.com/archives/msvc.html .

----------------------------------------------------------------------

Date:    Mon, 18 Jan 1999 03:42:36 -0500
From:    Online -- Goa <info@OPSPL.COM>
Subject: regarding GetFieldValue() function

hi all,

I am developing a Database application in VC++ 5.0(SP 3), SQL Server 6.5,
Win 95, Win NT 4.0 (SP 3). I am trying to get the filed values from the
Table(s) stored in the SQL Server by using the GetFieldValue() of the
CRecordset class. It displays a error INVALID COLUMN NUMBER.
what could be the possible problem ?

waiting for an answer ....
Thanks in Advance ..

Priya Ghate,
(from the VCPP Team at)
Online -- Goa.

------------------------------

Date:    Mon, 18 Jan 1999 10:05:38 +0100
From:    =?iso-8859-1?Q?Anders_W=E5hlin?= <wahlin@ERV.ERICSSON.SE>
Subject: Bit mask question

Hello.

I have a LPARAM value and I need to get the value between bit 2 and 4. The
bit mask looks like this:

        0110100110.....

The value of bit 2-4 is: 5 (101).

I know how to test each bit for its boolean value, but is there a function
that can do what I want? I have created a function that seems to work, but I
don't know if this is thte way to do it:

int GetValue(LPARAM lParam, int nStartPos, int nEndPos) {
        int nCount=nStartPos, nValue;

        nValue = 2 ^ nStartPos;
        while (nCount != nEndPos) {
                nCount++;
                if (!(!(lParam & (1L << nCount)))) {
                        nValue += 2 ^ nCount;
                }
        }

        return (nValue);
}

Can anyone please help me?

/Anders W

--
Anders Wahlin
System Manager
IT Operations
Ericsson Mobile Data Design AB

Phone: +46 31 7036394
Fax: +46 31 7036033
E-mail: Anders.Wahlin@erv.ericsson.se

------------------------------

Date:    Mon, 18 Jan 1999 11:29:28 +0100
From:    Marek Grolms <Marek.Grolms@UL.DS.MFCR.CZ>
Subject: CTabCtrl

Hello ,
sorry for my bad English.I have trouble with create CTabCtrl.I in the
resource create object Tab Control.How I associated with button , CEdit
, etc. ? And how is create this object  vertikalne ?

thanx
                                marek grolms

------------------------------

Date:    Mon, 18 Jan 1999 20:41:16 -0000
From:    =?iso-8859-1?Q?Jos=E9_Afonso?= <jafonso@MICROFIL.PT>
Subject: <No subject given>

I'm trying to add a string to a ComboBox inside a Dialog , i call this
dialog in a  formview and i can=B4t add a string to this combobox

CDialog *x;

     x=3D new CDialog;
  x->m_combo.addstring("xxx");
i hope anibody can help me

thanks

---------------------------
Jos=E9 Afonso
Jafonso@microfil.pt <mailto:Jafonso@microfil.pt>=20
---------------------------

------------------------------

Date:    Tue, 19 Jan 1999 10:26:07 +1300
From:    Rimu Atkinson <rimu1@XTRA.CO.NZ>
Subject: <No subject given>

This is a multi-part message in MIME format.

------=_NextPart_000_0016_01BE4396.205A5960
Content-Type: text/plain;
        charset="iso-8859-1"
Content-Transfer-Encoding: 8bit

I am not sure, but you may have to call UpdateData to actually see the
results of adding the string to the combobox.

Rimu Atkinson
http://www.fortunecity.com/campus/economics/700/index.html
ICQ # 26458113
-----Original Message-----
From: Jos? Afonso <jafonso@MICROFIL.PT>
To: MSVC@PEACH.EASE.LSOFT.COM <MSVC@PEACH.EASE.LSOFT.COM>
Date: Tuesday, 19 January 1999 09:43


I'm trying to add a string to a ComboBox inside a Dialog , i call this
dialog in a  formview and i can磘 add a string to this combobox

CDialog *x;

     x= new CDialog;
  x->m_combo.addstring("xxx");
i hope anibody can help me

thanks

---------------------------
Jos? Afonso
Jafonso@microfil.pt <mailto:Jafonso@microfil.pt>
---------------------------

--------------------------------------------------------------------------
The MSVC list is hosted on a Windows NT(TM) machine running L-Soft
international's LISTSERV(R) software.  For subscription/signoff info
and archives, see http://peach.ease.lsoft.com/archives/msvc.html .


------=_NextPart_000_0016_01BE4396.205A5960
Content-Type: text/x-vcard;
        name="Rimu Atkinson.vcf"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
        filename="Rimu Atkinson.vcf"

BEGIN:VCARD
VERSION:2.1
N:Atkinson;Rimu
FN:Rimu Atkinson
TEL;HOME;VOICE:64 06 8783507
TEL;HOME;FAX:64 06 8783507
ADR;HOME:;;708 Fitzroy Ave;Hastings;;;New Zealand
LABEL;HOME;ENCODING=3DQUOTED-PRINTABLE:708 Fitzroy =
Ave=3D0D=3D0AHastings=3D0D=3D0ANew Zealand
URL:http://www.fortunecity.com/campus/economics/700/index.html
EMAIL;PREF;INTERNET:rimu@thenet.co.nz
REV:19990118T212606Z
END:VCARD

------=_NextPart_000_0016_01BE4396.205A5960--

------------------------------

Date:    Mon, 18 Jan 1999 13:44:11 -0800
From:    Shanmuga S <s_shanmuganathan@YAHOO.COM>
Subject: Printing in Z-Fold

Dear Gurus,

Somebody help me pleeeeeeeaaasse.

I have tried many things, but I can't get a printer (HP Deskjet 695C)
that supposedly supports banner printing to print
continuously beyond the dimensions of a single page.  In my Print
dialog, given that a "Z-fold" check box is checked, I
set the maxpages in the CPrintInfo object to 1.  Then I obtain a
pointer to the DEVMODE structure and set the
dmPaperLength as follows:
/////////////////////////////////////////////////////////////////////////////
   long paperlength = 254 * m_TotalPrintInches; //in tenths of a
millimeter
                        // 1 inch x 2.54 cm/inch x 10 mm/cm x 10
   if(paperlength > 32767)
  {CString astr;
   astr.Format("Houston...We gotta problem, dmPaperLength is %d",
paperlength);
   AfxMessageBox( astr);
  }
  else
  { pdv->dmPaperLength = paperlength;
  }
/////////////////////////////////////////////////////////////////////////////
m_TotalPrintInches is calculated just above this code.  My tests
involve a print
job of about 20 inches.  The printer seems to be clipping the print
job right
just before the perforations.  I have set the CDC::m_ClipBox to zero,
but this does not help. (note: I haven't made any
further modifications to the DEVMODE structure)
I'm hoping somebody out there can think of something else for me to try.
Thanks in advance.

Cheers,
-Shanmuga




_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com

------------------------------

Date:    Tue, 19 Jan 1999 11:02:28 +1100
From:    David Roe <dud@SYDNEY.NET>
Subject: <No subject given>

i would guess that it is because the dialog has not been created at this
point, therefore it's child windows (including the combobox) has not been
created. Try calling DoModal() first and add the string in OnInitDialog().

/david

-----Original Message-----
From: Jos=E9 Afonso <jafonso@MICROFIL.PT>
To: MSVC@PEACH.EASE.LSOFT.COM <MSVC@PEACH.EASE.LSOFT.COM>
Date: Tuesday, January 19, 1999 7:42 AM


I'm trying to add a string to a ComboBox inside a Dialog , i call this
dialog in a  formview and i can=B4t add a string to this combobox

CDialog *x;

     x=3D new CDialog;
  x->m_combo.addstring("xxx");
i hope anibody can help me

thanks

---------------------------
Jos=E9 Afonso
Jafonso@microfil.pt <mailto:Jafonso@microfil.pt>
---------------------------

-------------------------------------------------------------------------=
-
The MSVC list is hosted on a Windows NT(TM) machine running L-Soft
international's LISTSERV(R) software.  For subscription/signoff info
and archives, see http://peach.ease.lsoft.com/archives/msvc.html .

------------------------------

Date:    Tue, 19 Jan 1999 09:12:55 +0800
From:    Rick Zhang <otv_zhang@163.NET>
Subject: SetViewportExtEx

Hi everybody:

I want to know how to get the scope of the viewport. I used the function
"GetViewportExtEx(HWND
hWnd, LPSIZE
lpsize)". The function worked fine, but the value it returned is: lpsize->cx =
1, lpsize->cy =
1. It seems not right.
I wonder if there are some mistake in my code:
--------------------------------------------------------------------------------
----
HDC hDC;
LPSIZE pwRet;
..

   if (GetMapMode(hDC) != MM_TEXT) SetMapMode(hDC,MM_TEXT);
   if (GetViewportExtEx(hDC,pwRet))
   {
      xClient = wRet.cx;
      yClient = pwRet->cy;

..

Thanks in advance.

------------------------------

Date:    Tue, 19 Jan 1999 09:42:53 +0800
From:    Jonathan Richie Yap <jryap@MAGINETPHI.COM>
Subject: Creating EXCEL Documents in VC

Hi!  I am just curious if you can create
EXCEL or Word Documents in Visual
C++ v. 5 and vice versa (reading EXCEL
documents back in VC++ 5)?  Thanks in
advance!!

Jonathan

P.S.  If possible, how??



Nadia Boulanger
       The essential conditions of everything you do must be choice,
love, passion.

============================
JONATHAN RICHIE YAP
Corporate Software Developer
Management Information Services Department
Headquarters

MagiNet Corporation
e-mail: jryap@maginetphi.com

------------------------------

Date:    Tue, 19 Jan 1999 12:50:12 +1100
From:    David Roe <dud@SYDNEY.NET>
Subject: Re: Creating EXCEL Documents in VC

http://www.codeguru.com/misc/excel_automation.shtml

this shows how to automate excel from a VC++ application.

HTH,
/david

-----Original Message-----
From: Jonathan Richie Yap <jryap@MAGINETPHI.COM>
To: MSVC@PEACH.EASE.LSOFT.COM <MSVC@PEACH.EASE.LSOFT.COM>
Date: Tuesday, January 19, 1999 12:43 PM
Subject: Creating EXCEL Documents in VC


>Hi!  I am just curious if you can create
>EXCEL or Word Documents in Visual
>C++ v. 5 and vice versa (reading EXCEL
>documents back in VC++ 5)?  Thanks in
>advance!!
>
>Jonathan
>
>P.S.  If possible, how??
>
>
>
>Nadia Boulanger
>       The essential conditions of everything you do must be choice,
>love, passion.
>
>============================
>JONATHAN RICHIE YAP
>Corporate Software Developer
>Management Information Services Department
>Headquarters
>
>MagiNet Corporation
>e-mail: jryap@maginetphi.com
>
>--------------------------------------------------------------------------
>The MSVC list is hosted on a Windows NT(TM) machine running L-Soft
>international's LISTSERV(R) software.  For subscription/signoff info
>and archives, see http://peach.ease.lsoft.com/archives/msvc.html .
>

------------------------------

Date:    Tue, 19 Jan 1999 14:52:32 +1300
From:    Rimu Atkinson <rimu1@XTRA.CO.NZ>
Subject: Re: Creating EXCEL Documents in VC

This is a multi-part message in MIME format.

------=_NextPart_000_0043_01BE43BB.581A0C40
Content-Type: text/plain;
        charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

Using OLE you could. I don't know how to do that in vc++ though...

Rimu Atkinson
http://www.fortunecity.com/campus/economics/700/index.html
ICQ # 26458113
-----Original Message-----
From: Jonathan Richie Yap <jryap@MAGINETPHI.COM>
To: MSVC@PEACH.EASE.LSOFT.COM <MSVC@PEACH.EASE.LSOFT.COM>
Date: Tuesday, 19 January 1999 14:43
Subject: Creating EXCEL Documents in VC


>Hi!  I am just curious if you can create
>EXCEL or Word Documents in Visual
>C++ v. 5 and vice versa (reading EXCEL
>documents back in VC++ 5)?  Thanks in
>advance!!
>
>Jonathan
>
>P.S.  If possible, how??
>
>
>
>Nadia Boulanger
>       The essential conditions of everything you do must be choice,
>love, passion.
>
>============================
>JONATHAN RICHIE YAP
>Corporate Software Developer
>Management Information Services Department
>Headquarters
>
>MagiNet Corporation
>e-mail: jryap@maginetphi.com
>
>--------------------------------------------------------------------------
>The MSVC list is hosted on a Windows NT(TM) machine running L-Soft
>international's LISTSERV(R) software.  For subscription/signoff info
>and archives, see http://peach.ease.lsoft.com/archives/msvc.html .

------=_NextPart_000_0043_01BE43BB.581A0C40
Content-Type: text/x-vcard;
        name="Rimu Atkinson.vcf"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
        filename="Rimu Atkinson.vcf"

BEGIN:VCARD
VERSION:2.1
N:Atkinson;Rimu
FN:Rimu Atkinson
NOTE;ENCODING=3DQUOTED-PRINTABLE:computer programmer, web site =
developer, hardware technician, software troub=3D
leshooter. cheap.=3D0D=3D0A
TEL;HOME;VOICE:64 06 8783507
TEL;HOME;FAX:64 06 8783507
ADR;HOME:;;708 Fitzroy Ave;Hastings;;;New Zealand
LABEL;HOME;ENCODING=3DQUOTED-PRINTABLE:708 Fitzroy =
Ave=3D0D=3D0AHastings=3D0D=3D0ANew Zealand
URL:http://www.fortunecity.com/campus/economics/700/index.html
EMAIL;PREF;INTERNET:rimu@xtra.co.nz
REV:19990119T015231Z
END:VCARD

------=_NextPart_000_0043_01BE43BB.581A0C40--

------------------------------

Date:    Mon, 18 Jan 1999 23:08:19 -0500
From:    Toan Nguyen Ngoc <toannguyenngoc@HOTMAIL.COM>
Subject: DOC file format

Hi!
I am converting from *.doc file to *.rtf file. I have used the DOC Object of
Microsoft, but DOC Object is too big. Can you help me with finding out format
of *.doc file? (or only header of *.doc file)
Thanks.

------------------------------

Date:    Tue, 19 Jan 1999 15:39:14 +1100
From:    David Roe <dud@SYDNEY.NET>
Subject: Re: DOC file format

you may want to try www.wotsit.org - the largest collection of file formats
on the net, apparently.

> -----Original Message-----
> From: Microsoft Visual C++ programmers list
> [mailto:MSVC@PEACH.EASE.LSOFT.COM]On Behalf Of Toan Nguyen Ngoc
> Sent: Tuesday, 19 January 1999 15:08
> To: MSVC@PEACH.EASE.LSOFT.COM
> Subject: DOC file format
>
>
> Hi!
> I am converting from *.doc file to *.rtf file. I have used the
> DOC Object of Microsoft, but DOC Object is too big. Can you help
> me with finding out format of *.doc file? (or only header of *.doc file)
> Thanks.
>
> --------------------------------------------------------------------------
> The MSVC list is hosted on a Windows NT(TM) machine running L-Soft
> international's LISTSERV(R) software.  For subscription/signoff info
> and archives, see http://peach.ease.lsoft.com/archives/msvc.html .
>

------------------------------

End of MSVC Digest - 17 Jan 1999 to 18 Jan 1999 (#1999-18)
**********************************************************
--
※ 转载:.BBS 荔园晨风站 bbs.szu.edu.cn.[FROM: 192.168.0.4]


[回到开始] [上一篇][下一篇]

荔园在线首页 友情链接:深圳大学 深大招生 荔园晨风BBS S-Term软件 网络书店