HDTenEightyP/NetNews huggingface dataset:
From: andres@scf16.scf.loral.com (Jeff Andres)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: BPW: Closing MainWindow and Borland Reserved Words
Date: 22 Jan 93 18:03:00 GMT
Organization: Loral Space & Range Systems

Previously posted to comp.lang.pascal....I wrote the following:

From: andres@scf16.scf.loral.com (Jeff Andres)
Subject: BPW: Closing MainWindow ???
Organization: Loral Space & Range Systems
Date: Fri, 22 Jan 1993 14:42:22 GMT

Using BPW and the resource workshop, I've used the skelton features
of a Borland program to begin hacking/programming in windows. The
program I started with (as I recall) didn't have an Exit function
but it did of course have the standard window close call. I wanted
to add the Exit feauture so I went into RW and created one with some
bogus return code (99). My program could capture this but I couldn't
quite figure out how to shutdown the windows....yes, RTFM...I see
CanClose, but not CLOSE...I see DESTROY, but that doesn't appear
to really shutdown/clean-up gracefully....hints ???

After getting frustrated, I decided that Borland had to have added this
feature into one of their examples and stumbled upon HeapSpy. Glancing
through their code I could not find where their Exit was called. I
opened their Menu using RW (HeapSpy.res) and found out that their return
code was set to something like 23400. So I took a chance and changed my
code of 99 to 23400 and BAM, it worked...what is so special about this
number and where is it documented....are there other reserved return
codes ???

Cheers,


-- 

      Jeff Andres 			---  Loral Space and Range Systems
 					---  1260 Crossman Ave.  MS-S37
  e-mail: andres@scf16.scf.loral.com    ---  Sunnyvale, California  94089
From: ensnjsa@gdr.bath.ac.uk (N J S Ajderian)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Re: Updating QC for W with SDK3.1 and C++7.0
Date: 27 Jan 93 12:04:24 GMT
Organization: School of Mechanical Engineering, University of Bath, UK

In the referenced article, cs92njc@ccws-39.brunel.ac.uk.ac.uk writes:
>
>I guess that by copying the SDK Lib dir to the QC lib dir, likewise 
>for the include files, will do the trick.

This works fine. If you want 3.1 keyword help you can rename win31.hlp
to qcwin.hlp and Robert is your father's brother.
Regards, Nick
Newsgroups: comp.os.ms-windows.programmer.misc
From: avinogra@empire.cce.cornell.edu (Alex Vinogradov)
Subject: Resource Compiler question
Organization: Cornell Cooperative Extension
X-Newsreader: TIN [version 1.1 PL8]
Date: Wed, 27 Jan 1993 03:39:41 GMT


I am getting a strange RC warning while trying to execute  RC my-program.RES :

-----
RC : warning RW4005: Segment 3 (offset 0802) contains a
     relocation record pointing to the automatic
     data segment.  This will cause the program to crash
     if the instruction being fixed up is executed in a
     multi-instance application.  If this fixup is
     necessary, the program should be restricted to run
     only a single instance.
-----

The program is compiled as large-model application (I think that's relevant,
because I strated getting the warning after I switched from small model).

Does anyone have any idea what exactly this warning means?  And how do I locate
line of code using the info given in the warning message (i've tried .MAP
file, but I could not find relevant info there) ?

Please e-mail all replies

Thanks a lot,
-- 
---------------------------------------------------------
Alex Vinogradov
Cornell Cooperative Extension, Electronic Technology Group
avinogra@empire.cce.cornell.edu
Newsgroups: comp.os.ms-windows.programmer.misc
From: chris@chrism.demon.co.uk (Chris Marriott)
Subject: Re: Edit window 
Distribution: world
Organization: None
Reply-To: chris@chrism.demon.co.uk
X-Mailer: Simple NEWS 1.90 (ka9q DIS 1.19)
Date: Thu, 21 Jan 1993 19:18:42 +0000

In article <1993Jan21.133335.13502@cs.hw.ac.uk> onar@cee.hw.ac.uk writes:

>Hi, hope someone can help a stupid Norwegian!
>
>I have a multiline edit window created by WRT resource toolkit.
>The programming is done in pure C using BorlandC 2.0.
>I use this edit window in a dialogbox. The problem is that
>the edit window does not detect the return key, but the
>strange thing is that if I hold down the CTRL key and then press
>the return key, the bastard works!
>What am I doing wrong.
>
>
>Regards
>
>Onar
>
>E-Mail: onar@cee.hw.ac.uk
>

you're not doing *anything* wrong - this is the (admitedly strange) way
that a multi-line edit control is *supposed* to work!

If you're using Windows 3.1 and you want the <Enter> key to start a new
line in the edit control, you can give the control the ES_WANTRETURN
style.  If you're using Windows 3.0, you have to subclass the control.

Best wishes,

Chris
-- 
--------------------------------------------------------------------------
| Chris Marriott                           | chris@chrism.demon.co.uk    |
| Warrington, UK                           | BIX: cmarriott              |
|                                          | CIX: cmarriott              |
| Save the whales.  Collect the whole set. | CompuServe: 100113,1140     |
--------------------------------------------------------------------------
 
Newsgroups: comp.os.ms-windows.programmer.misc
From: tope@enea.se (Tommy Petersson)
Subject: Re: VB: masked edit fields
Organization: Enea Data AB
X-Newsreader: Tin 1.1 PL3
Distribution: comp
Date: Mon, 25 Jan 1993 17:53:06 GMT

wangc@cpsc.UCalgary.ca (Carol Wang) writes:
: a co-worker has been having inordinate (IMHO) problems trying to use
: masked edit fields.  irregardless of the mask used, the results are
: the same. from what i gather from the documentation you should use the
: .Text property to manipulate or reference information in the field.
: using .Text to test the information in the field is not a problem, but
: trying to input into it invariably results in a "invalid property" or
: "variable not valid" type error.  so, further perusing the
: documentation turned up a .SelText property.  input with this was
: possible, but only if it was a direct string in quotes (eg "0") type
: assignment.  any assignment with, say, a string _varible_ was
: completely ineffective.  
: 
: i advised that since the project is under time pressure, personally i
: would just use regular text fields and verify the input after the user
: was done, and this has happened, but has anyone else experienced such
: problems with masked edit fields?
: 
: carol

Not theese, but most of the other possible problems. It doesn't
seem very usable.

-- 
=============================================================================
 Tommy Petersson              tope@enea.se              Enea Data AB, Sweden
=============================================================================
From: onar@cee.hw.ac.uk (Onar Olsen)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Edit window
Date: 21 Jan 93 13:33:35 GMT
Organization: Dept of Computing & Electrical Engineering, Heriot-Watt University, Scotland

Hi, hope someone can help a stupid Norwegian!

I have a multiline edit window created by WRT resource toolkit.
The programming is done in pure C using BorlandC 2.0.
I use this edit window in a dialogbox. The problem is that
the edit window does not detect the return key, but the
strange thing is that if I hold down the CTRL key and then press
the return key, the bastard works!
What am I doing wrong.




Regards


Onar


E-Mail: onar@cee.hw.ac.uk
From: perkins@tallis.enet.dec.com (Eric Perkins)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Intercepting GDI Calls:
Date: 22 Jan 93 14:21:19 GMT
Reply-To: perkins@tallis.enet.dec.com
Organization: Digital Equipment Corporation, Littleton MA


Here is a technical problem which I think solvable but
which I cannot find the answer to in the Windows SDK
documentation or any other reference.

I would like to place one of my own supplied functions
in between an application and the Windows GDI system.

For instance I would like to place my own function
lets say called ERIC_TextOut into a DLL and have
it be called when a function actually makes a Windows
TextOut call.

What my function will do in turn is take the parameters
that it is passed (which is the same as the actual
TextOut function parameters) and pass them on to the
real GDI TextOut function.

I think this can be done since I think this is what
programs such as Carbon Copy for Windows do. The have
on the remote system such a DLL (or maybe it is a
device driver or something) and when an application on the
remote system make a call to TextOut, they first get
the information, send it through the communications
link and on the local system they have a supporting
application which is making a TextOut call locally.

I would hate to get into device drivers for this and thought
that through some mechanism of sub-classing or such that it
could be done.

I know that I can set a Windows hook for certain events, but they
do not seem to include any/all of the GDI functions, only a sub-set
such as CreateWindows or certain messages.

All inputs welcomed...

If the problem space needs further clarification, post it here
and I will to better define the problem.


-- Thanks, Eric

===============================================================================
-- Note: All views questions, and thoughts are my own and in no way represent
--       those of my employer or anyone else.
--
-- I can be reached by the following means:
-- Eric Perkins			E-Mail : perkins@tallis.enet.dec.com
-- Digital Equipment Corp	Phone  : (508) 952-3144
-- 153 Taylor Street		FAX    : (508) 952-3023
-- Littleton, MA 01460-1407
===============================================================================
From: trenz@mod-elc4.NoSubdomain.NoDomain (Thomas Trenz)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Restart Windows
Keywords: Restart Windows
Date: 28 Jan 93 11:42:54 GMT
Organization: DFKI


  Hi,

  how can I restart Windows by a Windows-application. It should behave like the
  Windows-installation program, which asks whether to restart Windows.

  Thanks in advance

  Thomas


--------------------------------------------------------------------------------
Thomas Trenz
mail: trenz@dfki.uni-sb.de
--------------------------------------------------------------------------------
From: brehonyt@ul.ie
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Looking for 32 bit ANSI-C compiler for win3.x
Date: 27 Jan 93 15:51:16 GMT
Organization: University of Limerick, Ireland




I'm looking for a 32 bit ANSI-C compatible compiler for DOS/Win 3.x. I 
know there are a few on the market. What are they and which are the best
(IYHO) ?. Also which have facilities analagous to the Quickwin facility 
supported by Microsoft C/C++ 7.0. 

Basically what I want to do is to create a 32 bit Win 3.1 program from 
an character mode, 32 bit ANSI C system.

Any comments, advice , etc would be appreciated. Thanks.

Tom Brehony.
Email : brehonyt@ul.ie 
Newsgroups: comp.os.ms-windows.programmer.misc,comp.windows.ms.programmer
From: jagrant@emr1.emr.ca (John Grant)
Subject: Re: Drawing Text on its side in BC++?
Organization: Energy, Mines, and Resources, Ottawa
Date: Thu, 21 Jan 1993 20:18:26 GMT

In article <C17xG3.DMw@cs.uiuc.edu> greco@cs.uiuc.edu (Steven Greco) writes:
>I need to draw text on its side and was wondering if it is possible to
>do this with Borland C++ and owl.  Right now I am using DrawText to draw
>my text, but it just produces normal text, not text on its side.  Is this
>possible?  Is there any way to rotate a bitmap possibly?
	You must create a new HFONT with the required angle.  The
	angle is the .lfEscapment member of a LOGFONT.
	Not all fonts can be rotated (i.e. bitmapped fonts).  However,
	all TrueType fonts can be rotated.  I just use "Arial" as
	my default font for graphics.
-- 
John A. Grant						jagrant@emr1.emr.ca
Airborne Geophysics
Geological Survey of Canada, Ottawa
From: twbrown@PE-Nelson.COM (Tom W. Brown)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Re: Changing horses in midstream.
Date: 26 Jan 93 21:33:11 GMT
Organization: PE-Nelson

In article <753@lax.lax.pe-nelson.com>, twbrown@PE-Nelson.COM (Tom W. Brown) writes:
|> In article <1k1886INNbek@iguana.cis.ohio-state.edu>, guzman@cis.ohio-state.edu (jonatan guzman) writes:
|> |> ...well, just about!
|> |> 
|> |> I have a program that needs to print a number of documents, and needs to change
|> |> the mode (landscape/portrait) depending on the document. Anybody out there 
|> |> know how to do this?
|> 
|> There are two basic approaches:
|> 
|>    1) Always plot in what is essentially portrait mode and tell the printer
|>       driver to flip into Portrait or Landscape mode via a call to
|>       ExtDeviceMode().  See documentation for that call for more info.
|> 
|>    2) Always assume that the printer is in Portrait mode and setup your
|>       mapping mode to give the effect of portrait or landscape.
|> 
|> I've done it both ways.  (1) may be easier if you've already got the graphics
|> code written and it makes hard to change assumptions about the mapping mode.
|> (2) can be pretty powerful since you can do fancy (albeit mostly useless :-)
|> things like printing upside-down and backwards by altering your window and
|> viewport mapping.

This is, of course, a little understated (must have grabbed the decaf by
mistake :-).  For (2), you need to parameterize your drawing routines so that
they know whether to do portrait or landscape mode.  For landscape mode
you must swap x and y values to the GDI calls in an appropriate fashion (as
well as rotating fonts appropriately).


----------------------------------------------------------------------------
Tom Brown               |  "She turned me into a newt...
PE Nelson Systems       |                                  ... I got better"
twbrown@pe-nelson.com   |                    Monty Python and the Holy Grail
----------------------------------------------------------------------------
Newsgroups: comp.os.ms-windows.programmer.misc
From: jca17@phx.cam.ac.uk (J.C. Ashworth)
Subject: (Borland?) C++ Language Question
Organization: U of Cambridge Computer Lab, UK
Date: Thu, 28 Jan 1993 17:18:55 GMT

I dunno whether this relates solely to the Borland C++ compiler or whether
it's a general C++ feature / bug?

I seem to be able to do the following quite legally and with the expected
result:

class B
{
// ...
};

class C
{
// ...
};

class D : public B
{
	int xtraField;
// ...
};

B& foo( ... );

D::func( ... )
{
	D& temp = (D&) foo( ... );
	temp.xtraField = 5;
}

Is this OK? How does the cast from B& to D& work? I suppose a cast from B& to C&
would NOT be legal?

thanks.
	
-- 
           ______________    _____________
          /             /\  /            /\        Julian Ashworth
         /_____    ____/ / /   _____    / /        Magdalene College
          \___/   /\ __\/ /   /\___/   / /         Cambridge
             /   / /     /   /_/__/   / /          England
            /   / /     /            / /
  __       /   / /     /   _____    / /            jca17@phx.cam.ac.uk
 /  \_____/   / /     /   /\___/   / /
 \           / /     /   / /  /   / /
  \_________/ /     /___/ /  /___/ /    "It's a great way to steal a car
   \________\/      \___\/   \___\/      but where do we get a jet-pac?"
Newsgroups: comp.os.ms-windows.programmer.misc
From: jca17@phx.cam.ac.uk (J.C. Ashworth)
Subject: Ownerdraw Listboxes
Keywords: ownerdraw, listbox
Organization: U of Cambridge Computer Lab, UK
Date: Thu, 28 Jan 1993 17:02:20 GMT

Does anyone know how to program ownerdraw listboxes?

Ideally, I would like to be able to use a file open listbox like the one
in MS Word 2.0 - you know, with the file icons down the left hand side
of the box.

I imagine this probably means drawing my own listbox,

If anyone could tell me how to do this, or better, mail me some example
code, I'd really appreciate it.

thanks.
           ______________    _____________
          /             /\  /            /\        Julian Ashworth
         /_____    ____/ / /   _____    / /        Magdalene College
          \___/   /\ __\/ /   /\___/   / /         Cambridge
             /   / /     /   /_/__/   / /          England
            /   / /     /            / /
  __       /   / /     /   _____    / /            jca17@phx.cam.ac.uk
 /  \_____/   / /     /   /\___/   / /
 \           / /     /   / /  /   / /
  \_________/ /     /___/ /  /___/ /   "It's a great way to steal a car
   \________\/      \___\/   \___\/     but where do we get a jetpac?"
From: p_bapti@pavo.concordia.ca (BAPTISTA, PAUL)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Vbrun200.zip Where by FTP?
Date: 22 Jan 93 17:54:00 GMT
Organization: Concordia University
News-Software: VAX/VMS VNEWS 1.41


	I need vbrun200.dll to use a new shareware.  Where can I get it by
anonymous FTP?

Paul Baptista (p_bapti@pavo.concordia.ca)
2nd year electrical engineering
Concordia University,
Montreal, Canada 
Newsgroups: comp.os.ms-windows.programmer.misc
From: gfowler@javelin.sim.es.com (Gary Fowler)
Subject: VB: Recognizing File System Changes
Organization: Evans & Sutherland Computer Corp.
Date: Thu, 28 Jan 1993 22:09:12 GMT


How can I make a File List Box recognize changes to the file system?
I know that I can use the Refresh method to force the File List Box
to update but how do I know when to refresh it?  If my application
changes the contents of the directory then I can simply do a refresh
at that time, but what if another application changes the contents
of the directory?  Is there an API call that will cause the application
to be notified?  There must be some way to do it because the File Manager
gets notified.  I guess I could set a timer event to refresh periodically
but I'd rather not waste cpu cycles.  Any suggestions would be greatly
appreciated.

Thanx,
Gary Fowler

********************************************************************************
*     Gary Fowler                     *     The storm starts when the drops    *
*     gfowler@esunix.sim.es.com       *     start dropping.  When the drops    *
*     Evans & Sutherland              *     stop dropping then the storm       *
*     600 Komas Drive                 *     starts stopping.                   *
*     Salt Lake City, UT              *     -Dr. Seuss                         *
********************************************************************************
Newsgroups: comp.os.ms-windows.programmer.misc
From: menees@utkvx3.utk.edu (Menees, Bill)
Subject: Need MCI call to get a unique label/name for CD Audio disk.
News-Software: VAX/VMS VNEWS 1.41    
Organization: University of Tennessee Computing Center
Date: Mon, 25 Jan 1993 22:26:00 GMT

	I just finished writing a CD Player for Win3.1, and I put in all the
hooks to add a CD Database later.  The reason I didn't add it yet is that I
don't know of any MCI (or even DOS) call to get a unique name/label for an
audio CD.  Microsoft uses a label like this for the CD Player they provide with 
NT, but never mentions how they do it.  A unique label is necessary to show the
correct information (like song titles) for a CD.  So, does anybody know of any
MCI call I can make from Win3.1 to do this sort of thing?  Your help would be
greatly appreciated...  Post or e-mail the response.

Bill Menees
menees@utkvx.utk.edu
From: odysee@pyton.DoCS.UU.SE (Tobias Thomson)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: MUST HAVE HELP!!!!!
Date: 24 Jan 93 17:06:09
Organization: Dept, of Computer Systems, Uppsala University, Sweden.
NNTP-Posting-Host: pyton.csd.uu.se


I have a problem with my code:
			
			lWhere = _llseek(hFile, 0, 0);
			err    = _llseek(hFile, -lWhere, 1);
			err    = _lread(hFile, &bBuf, sizeof(bBuf));

	The problem is that hFile (it's a global HFILE) != 0, after 
	the last codeline (_lread..) changes from !=0 to just 0 (zero).
	
	I use BC++ 3.1 and Windows 3.1. The program is a Windows program
	with small memory model.

	This is perhaps a FAQ but pleeeeease help me, I don't understand
	a shit about this.

	T. Thompson:	odysee@kobra.csd.uu.se

 
Newsgroups: comp.os.ms-windows.programmer.misc
From: rioj7@fel.tno.nl (M.L.M.Veraart)
Subject: Re: How to Put a Bitmap into a Dialog Box
Organization: TNO Physics and Electronics Laboratory
Date: Thu, 21 Jan 93 07:59:05 GMT

kevin@iti.gov.sg (Kevin Patt (SE)) writes:

>Hi,

>    I want to put a bitmap into a Dialog Box, is there a way by making
>use of the Borland Resource Workshop? I could come up with a custom
>control to display the bitmap, I am just wondering is there an easier
>way?

>    Thanks!

Kevin, 

A solution is to make an edit control that has only a black frame or a
white frame. The size of this control is the size in pixels of the 
bitmap. In your InitDialog function you get the handle of this control
using a call to getItemHandle() and than a call to GetDC to get DC to
this control. Now you can use Bitblt() or Stretchblt() to paint the bitmap
in the dialog. This is the way that is used in PaintBrush when you set
the custom colors. They dynamiccally update the resulting color using the
same method.
If the dialog can be covered by another window you must process the
WM_PAINT also for the dialog in the same manner.

It works for me, I hope it will work for you to.

Mario Veraart
email:mveraart@fel.tno.nl
-- 
Mario Veraart                  TNO Physics and Electronics Laboratory
email: rioj7@fel.tno.nl        The Hague       The Netherlands
"If all else fails, show pretty pictures and animated videos, 
 and don't talk about performance",  David Bailey
Newsgroups: comp.os.ms-windows.programmer.misc
From: wcruppel@csg.uwaterloo.ca (Bill Ruppel)
Subject: HELP! Custom PRINTDLG Problem!
Organization: Computer Systems Group, University of Waterloo
Date: Thu, 21 Jan 1993 20:42:28 GMT

Hi all.

I've written a custom dialog for use with the Common Dialog Routine 'PrintDlg'
in Windows 3.1. The custom dialog just adds one extra button, below the
"Setup..." button in the PRINT SETUP dialog. Now, the problem is, I want to
be able to determine which printer has been selected in the dialog when the
user presses this extra button. I've tried looking at the PRINTDLG structure
at the time the user pushes the button, but the DEVNAMES structure is the
same as it was when I called the 'PrintDlg' routine. (In other words,
Windows does not seem to update the PRINTDLG structure until you press the
'OK' button)

I know that I can kludge my way around this problem by looking directly at
the combo box in the PRINT SETUP dialog, and parsing the printer name out
of the text, but this would be far from elegant.

Does anyone know a solution to this? Does Windows perhaps send a message
to my Setup Hook routine informing me that the user has changed printers?

Any help would be appreciated, and please send replies via E-Mail, as I do
not regularly read this newsgroup...

Thanks

- Bill
From: lfosdal@falcon.no (Lars Fosdal)
Newsgroups: comp.os.ms-windows.programmer.misc
Subject: Re: Far Pointer Problem in DLLs
Date: Wed, 27 Jan 93 08:11:57 MET
Organization: Falcon Information Services AS, Oslo, Norway

tjr@cbnewsc.cb.att.com (thomas.j.roberts) writes:

> 
> Of course, "portable DLL" is an oxymoron - DLLs are very Windows specific.
> 

Actually, if you wrote a DLL containing only your code (i.e. no Windows
specific calls) and used Pascal calling conventions, I would be able to use 
that same DLL from a Borland Pascal DPMI (Protected mode) program.
Of course I'd need to know the parameters and DLL indexes of
your DLL functions.

So... DLL's really are portable (to a degree).

Lars F.
--
/ Mr.Lars Fosdal              / Falcon AS            / lfosdal@falcon.no  /
/ Software Developer          / Stranden 1           / Tel. +47 22831310  /
/ Financial Analysis Systems  / N-0250 OSLO, Norway  / Fax. +47 22831290  /
----=* All opinions are personal and does not reflect company policy *=----