Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!cs.utexas.edu!samsung!uunet!lupine!rfg From: rfg@NCD.COM (Ron Guilmette) Newsgroups: comp.lang.c++ Subject: Re: Passing variable #arguments through method Message-ID: <1084@lupine.NCD.COM> Date: 4 Aug 90 17:59:33 GMT References: <1990Aug3.165607.2292@maverick.ksu.ksu.edu> Distribution: usa Organization: Network Computing Devices, Inc., Mt. View, CA Lines: 32 In article <1990Aug3.165607.2292@maverick.ksu.ksu.edu> jxf@procyon.cis.ksu.edu (Jerry Frain) writes: >Please pardon my ignorance, but is there a simple way to do the following: > >class foo { >public: > print(char *fmt, ...) { fprintf(a_file, fmt, ...); } >} > >Where the (...) in the fprintf would be the same arguments as passes >to the foo::print() method? You should get a copy of the ANSI C standard and look at the descriptions of the include file (and what it does for you) and also at the description of the vfprintf() function. i n e w s b i t e s -- // Ron Guilmette // C++ Entomologist // Internet: rfg@ncd.com uucp: ...uunet!lupine!rfg // Motto: If it sticks, force it. If it breaks, it needed replacing anyway.