| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Starting a dosbox by 16-bits calls |
EH> Is there anybody who knows (from the old times :-) how
EH> I can startup a dosbox in 16-bit-API?
I modified an old program with the new session type values, and it seems
to work fine. Note the new /dos and /doswin parameters:
// msc 6
#define INCL_NOPM
#define INCL_DOS
#define INCL_DOSERRORS
#include
#include
#include
#include
#include
void showuse(void)
{
printf("XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX\n");
printf("X DSS (DosStartSession) (C) P.Fitzsimmons
91/09/02 X\n");
printf("X Version
0.00 X\n");
printf("X Usage: DSS [options] [program
arguments] X\n");
printf("X Purpose: Start a new session.
X\n");
printf("X Options: /F - Switch program to foreground.
X\n");
printf("X /WIN - Run in a VIO window session.
X\n");
printf("X /FS - Run in a full screen session.
X\n");
printf("X /PM - Run as a PM program.
X\n");
printf("X /WAIT - Wait for program to complete (default
X\n");
printf("X is asynchronus)
X\n");
// printf("X
X\n");
printf("XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX\n");
}
typedef struct _qstart {
USHORT pidSession;
USHORT pidProcess;
USHORT pidParentSession;
USHORT pidParentProcess;
}QSTART;
typedef struct _qdie {
USHORT pidSession;
USHORT retcode;
}QDIE;
void cdecl main(int argc, char **argv)
{
PID pidSession;
PID pidProcess;
STARTDATA startdata;
static char parms[256];
static char pgm[_MAX_PATH];
USHORT rc;
int i;
USHORT SessionType = 0;
BOOL back = TRUE;
BOOL wait = FALSE;
HQUEUE hq;
char qname[30];
QUEUERESULT qr;
USHORT len;
BYTE prty;
QSTART far *pv;
QDIE far *qd;
if (argc == 1){
showuse();
exit(1);
}
rc = 0;
for(i=1; (int)i * Origin: Beer bellies = great waist. (905)858-8488 (1:259/414)SEEN-BY: 54/54 620/243 632/348 640/820 690/660 711/409 413 430 807 808 809 SEEN-BY: 711/934 712/353 623 713/888 800/1 2442/0 @PATH: 259/414 400 99 98 3615/50 229/2 2442/0 711/409 54/54 711/808 809 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.