🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: microsoft.public.vc.language
Article #12

Re: choiceyn: cut down choice command, use of sleep, kbhit and getch

#12
From: Tim Roberts
Date: Wed, 14 Jan 2004 06:56
33 lines
2678 bytes
"Hal Styli" <no_spam@all> wrote:
>
>My version of CHOICE.COM on win98 gives 2 beeps when F1 is pressed, so I
>think  I'll leave it unless you think I should be doing something special
>with the special keys which I could put in as a non-standard extension.
>
>No promises but Im close to a version 0.5 of  a full blown choice command
>and would prefer to add no more features unless absolutely necessary to keep
>maintenance  time to a minimum. I just wanted to port my bat files from 98
>to xp and be confident that I would have the choice command available, as
>well as humour myself with some C.

You could just copy CHOICE.COM from Win98 and carry it with you.  It will
work just fine. in NT/2K/XP.

>How about reducing its size? If I could get it down to a couple of kb I
>would be tempted to stay with C for a final version.
>
>Obvious ideas are:-
>a) rewrite in assembler - which appeals to me since its an opportunity to
>learn more assembler too. I guess I could start with the assembler out put
>you can get from the compiler or keep hunting for an open source file as a
>starting point. Anyway thats for another day and another newsgroup.

If you keep it a Win32 app, going to assembler isn't going to reduce the
size.  There is almost no code in the program: the size is all in the
standard library.

However, if you did it as a 16-bit DOS app in assembler, you could make it
a true .COM and cut the size way down.
-- 
- Tim Roberts, timr@probo.com
  Providenza & Boekelheide, Inc
Technical Details
Message-ID: <6sp90015bohukp4kutbnir462thnfa3jau@4ax.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!t-online.de!TK2MSFTNGP08.phx.gbl!tk2msftngp13.phx.gbl
References: <4002d4eb_5@127.0.0.1> <uIWdnZPEO6ofaJ_dRVn-ig@comcast.com> <4003717f_5@127.0.0.1> <yJOdnaEvW6CsFZ7d4p2dnA@comcast.com> <4003a1fc_5@127.0.0.1>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f8d38,6ae23aa1a5869fb6
X-Google-Attributes: gidf8d38,public
X-Google-Thread: f7a51,6ae23aa1a5869fb6
X-Google-Attributes: gidf7a51,public
X-Google-ArrivalTime: 2004-01-13 22:55:10 PST
From: Tim Roberts <timr@probo.com>
Subject: Re: choiceyn: cut down choice command, use of sleep, kbhit and getch
Date: Tue, 13 Jan 2004 22:56:10 -0800
Organization: Providenza & Boekelheide, Inc.
Message-ID: <6sp90015bohukp4kutbnir462thnfa3jau@4ax.com>
References: <4002d4eb_5@127.0.0.1> <uIWdnZPEO6ofaJ_dRVn-ig@comcast.com> <4003717f_5@127.0.0.1> <yJOdnaEvW6CsFZ7d4p2dnA@comcast.com> <4003a1fc_5@127.0.0.1>
X-Newsreader: Forte Agent 1.93/32.576 English (American)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: microsoft.public.vc.language,borland.public.cpp.language
NNTP-Posting-Host: sub20-190.member.dsl-only.net 63.105.20.190
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!t-online.de!TK2MSFTNGP08.phx.gbl!tk2msftngp13.phx.gbl
Lines: 1