[comp.windows.ms.programmer] DOS to Windows

ssriniva@Teknowledge.COM (Shankar Srinivasan) (04/18/91)

Anybody have any references to books or articles that address the
issues and steps involved in moving DOS applications to Windows? 

I've looked at all the regular references (Petzold, SDK manuals) and 
don't see anything that specifically addresses this issue. I suppose
one could infer a set of things to do based on the material there, but
being new to the wonderful world of MS Windows, I'm just afraid that I 
may neglect something important.

I'm most concerned about memory (of course), since the application we're
working with is large (in size and mem model). Can any 
net.windows.experts give me references or maybe a list of things to do,
do's and don't, gotchas, recommendations? Any info is appreciated.

Email or post to c.w.m.p is fine. Thanks in advance.

- Shankar 					ssriniva@Teknowledge.Com

ebergman@isis.cs.du.edu (Eric Bergman-Terrell) (04/20/91)

Well I'm right in the middle of a port of a DOS application to Windows 3.0.

My program has a lot of code, but few large data structures, so I don't have
much advice that isn't already said better in Petzold - actually I do - if
you have static data structures that aren't too big (maybe < 32k) consider
making them RCDATA or user-defined resources (then you don't have to write
much code to load them from disk).

BTW the best part of a Windows port is throwing away all the @#$@#$ hand-
crafted menu & dialog box management code as well as the @#$@$ home-grown
printer drivers!

Also:  I am beginning to believe that the complexity of Windows application
development is rather exaggerated.  The time I've spent learning Windows
& the message passing paradigm is much less than I'd spend writing all the
things already built into Windows (e.g. on-line help)...


My $0.02


Terrell

srw@cci632.cci.com (Steve Windsor) (04/22/91)

In article <13728@alfred.Teknowledge.COM> ssriniva@Teknowledge.COM (Shankar Srinivasan) writes:
>Anybody have any references to books or articles that address the
>issues and steps involved in moving DOS applications to Windows? 
>
Well...............

 There are just too many steps.  You are NOT simply porting C code to
 windows.  You must make some conceptual leaps (that is, if you have
 not used a GUI before).

 The best way to think of it, is that you will most likely have to rewrite
 50-100% of the code, particulary if it deals with a graphics interface
 or memory allocation.

>I've looked at all the regular references (Petzold, SDK manuals) and 
>don't see anything that specifically addresses this issue. I suppose
>one could infer a set of things to do based on the material there, but
>being new to the wonderful world of MS Windows, I'm just afraid that I 
>may neglect something important.

 Your fears are well founded.  Welcome to Windows.  Let me give you a hint:
 you don't even use the MSC library anymore!

>I'm most concerned about memory (of course), since the application we're
>working with is large (in size and mem model). Can any 
>net.windows.experts give me references or maybe a list of things to do,
>do's and don't, gotchas, recommendations? Any info is appreciated.

Yes./

1)  Don't use large model, use medium.

2)  Take (TAKE IT) Microsoft University's windows classes.  Take the
    first one, Windows Programming Environment.  This is an excellent
    class and will give you a LOT more background into what and how to
    do things.

3)  The list is simply too large.  Only a neural network would work 8-).
    If this is a project that your boss or company has you on and
    they think it is a simple matter to port the application, let me
    tell you here and now that IT IS NOT!!!  So, be forewarned.

I'm not trying at all to scare you away from Windows, it can be a 
*wonderful* package, but in the hands of the uninformed, it will
be your worst nightmare.  Take the class.  It will be the best
$1500 your company ever spent.  

cheers,

stephen windsor    srw@op632.cci.com

demillo@porter.geo.brown.edu (Rob DeMillo) (04/26/91)

In article <1991Apr20.024602.29466@mnemosyne.cs.du.edu> ebergman@isis.UUCP (Eric Bergman-Terrell) writes:
>Also:  I am beginning to believe that the complexity of Windows application
>development is rather exaggerated.  The time I've spent learning Windows
>& the message passing paradigm is much less than I'd spend writing all the
>things already built into Windows (e.g. on-line help)...
>
>
>My $0.02
>

A good two cents....

Its not exagerated...it takes a large learning curve to be able
to effectively use about 400 function calls...however, I have been
programming professionally in X Windows for a few years now,
and I have finally reached that point in MS Windows 3.0 where I 
think I'm as competent in Windows as I am in X....and you know
what? I *almost* like Windows better than X! (Gasp!  Heathen!) 
My personal jury is still out on this, but it has a *lot* 
of nice features that are relatively easy to use. (DDE, for one.)
Plus, to the user, the applications look just as sexy as they
do in OpenWindows 2.0. (Although I *still* like the look of
the OpenWindows slider bars better....)

My $0.04


 - Rob DeMillo			     | Internet: demillo@juliet.ll.mit.edu
   Mass Inst of Tech/Lincoln Lab     | Also:     demillo@porter.geo.brown.edu
   Weather Sensing Project-Group 43  | Reality:  401-273-0804 (home)
"I say you *are* the Messiah, Lord! And I ought to know, I've followed a few!"