🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.ms.programmer
Article #3206

Replacing standard library functions

#3206
From: Phong Co
Date: Wed, 12 Jun 1991 18:03
42 lines
2217 bytes
Hi there,

I notice that the SDK functions include analogs of functions in the
standard Microsoft library, such as lstrcmp(), _lopen(), wsprintf(),
and so forth.  While these are not identical to their DOS
counterparts, they perform pretty much the same tasks, and in a
Windows-friendly way.  The Guide to Programming also says that if you
don't use (and link in) the DOS runtime libraries your application
will be much smaller.  While I cannot argue this, it seems to me that
the SDK functions don't come close to fulfilling the needs of an
average Windows app.  For example, many string functions are missing.
Although many (such as strchr()) are not hard to implement, this is
the reason libraries were invented in the first place.  And there are
some that I can't seem to find Win functions for, such as:

- testing for the existence of a directory (such as using access()).
	OpenFile() only seems to work on files.  Any one have any 
	suggestions?
- floating point I/O.  While my program does not use floating point
	for calculation, I do read and display them in an edit
	control.  I currently use atof() to read the numbers, and
	sprintf() to print them.  Windows seem not to support
	floating point numbers at all.  Does Microsoft think that graphics
	programs have no need for fractions?

Like most people, I jumped headfirst into Windows programming, and
wrote messy code, which I would now like to clean up bit by bit.  My
question is, is it really feasible to write a Windows app without
resorting to runtime library calls?


Phong.


-- 

=========================================================================
Phong T. Co		|
chryses@xurilka.UUCP	|	Nice girls don't explode.
dada Indugu Inc.	|			-- Dave Sim (Cerebus #110)
Montreal, CANADA	|
Technical Details
Message-ID: <285661fe@xurilka.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!ucbvax!xurilka.UUCP!chryses

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!ucbvax!xurilka.UUCP!chryses
From: chryses@xurilka.UUCP (Phong Co)
Newsgroups: comp.windows.ms.programmer
Subject: Replacing standard library functions
Message-ID: <285661fe@xurilka.UUCP>
Date: 12 Jun 91 18:03:42 GMT
Sender: daemon@ucbvax.BERKELEY.EDU
Organization: dada Indugu Inc.
Lines: 42