473,406 Members | 2,451 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

VC++ and WinNT Problem

hi all,

i have MSVC Project which was developed on Win 98 (quiet antique but
true), now i move the development to Win NT. when i runt the
application it fails with a message, "unable to create new document".
what could be the causes of this error? but the same application if
run in win 2k or XP is running fine.

thanks
Ravs
Jul 22 '05 #1
10 1759

"Raveen.B" <ra******@math.net> wrote in message
news:bb**************************@posting.google.c om...
hi all,

i have MSVC Project which was developed on Win 98 (quiet antique but
true), now i move the development to Win NT. when i runt the
application it fails with a message, "unable to create new document".
what could be the causes of this error? but the same application if
run in win 2k or XP is running fine.


Questions about Windows programming should be asked on a Windows programming
group, like news:comp.os.ms-windows.programmer.win32.

This group is for C++ questions and your question has nothing to do with
C++.

john
Jul 22 '05 #2

"Raveen.B" <ra******@math.net> wrote in message
news:bb**************************@posting.google.c om...
hi all,

i have MSVC Project which was developed on Win 98 (quiet antique but
true), now i move the development to Win NT. when i runt the
application it fails with a message, "unable to create new document".
what could be the causes of this error? but the same application if
run in win 2k or XP is running fine.

thanks
Ravs


I think that NT (4.0) is as old as 98, if not older. (But who can remember
back that far? :-)) And it was a very different OS from 95, 98, 2000 or XP.
You have to compile explicitly for the NT in most cases, and sometimes even
rewrite the code to work with the NT. Want advice? Drop NT, it's lifetime
is over.

-Howard
Jul 22 '05 #3
* Howard:

"Raveen.B" <ra******@math.net> wrote in message
news:bb**************************@posting.google.c om...
hi all,

i have MSVC Project which was developed on Win 98 (quiet antique but
true), now i move the development to Win NT. when i runt the
application it fails with a message, "unable to create new document".
what could be the causes of this error? but the same application if
run in win 2k or XP is running fine.

thanks
Ravs


I think that NT (4.0) is as old as 98, if not older. (But who can remember
back that far? :-)) And it was a very different OS from 95, 98, 2000 or XP.
You have to compile explicitly for the NT in most cases, and sometimes even
rewrite the code to work with the NT. Want advice? Drop NT, it's lifetime
is over.


Off-topic except the degree to which C++ development is influenced by
system support might be sort of on-topic, e.g. NT provides better
checking of invalid pointer usage.

<OT>
The Explorer GUI was introduced in Windows 95 and subsequently made
available on Windows NT, then in version 4. Windows 2000 is NT 5.0,
Windows XP home and professional is NT 5.1, and XP Server is 5.2.
It's a bit difficult to drop NT for Windows programming since it's
the current Windows.
</OT>
--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
Jul 22 '05 #4

Up until WinXP, all home editions of Windows were ASCII
while the office editions were Unicode. Both operating
systems have:

MessageBoxExA
MessageBoxExW

But on the home editions, the W one is a dummy. While on
the office editions, both work. Consequently, WinNT progs
simply *won't* work on normal Windows 98, but Win98 progs
*will* run on WinNT.

Now, with WindowsXP, everything's Unicode. If you call an A
function, then:

blah AFunction(blah)
{
Convert();
WFunction();
}

This is the opposite of how WinNT dealed with Win98 progs.

-JKop
Jul 22 '05 #5
* JKop:
[incorrect]


Get the facts straight at least if you must post off-topic.

--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
Jul 22 '05 #6
Alf P. Steinbach posted:
* JKop:
[incorrect]
Get the facts straight at least if you must post off-

topic.


This is the part where you correct me, and then I respond
with either "Yeah, you're right", or "Shutup".

Shutup.
-JKop
Jul 22 '05 #7
JKop wrote:
Consequently, WinNT progs
simply *won't* work on normal Windows 98, but Win98 progs
*will* run on WinNT.


Not only is this off-topic, it's patently false. The default use of
ANSI vs. Unicode API calls is determined by the compiler, not by the OS.
If you #define UNICODE then the API calls resolve to Unicode
functions, otherwise they resolve to ANSI functions. It is entirely
possible to build Win32 executables that will run as-is on everything
from Win95 through Longhorn.

--
Mike Smith
Jul 22 '05 #8
Mike Smith posted:
JKop wrote:
Consequently, WinNT progs
simply *won't* work on normal Windows 98, but Win98 progs *will* run on WinNT.
Not only is this off-topic, it's patently false.


False.
The default use of
ANSI vs. Unicode API calls is determined by the compiler, not by the OS.

False, it's determined by which you call.

MessageBoxA
MessageBoxW

There's no such Win32API function "MessageBox". It's very
possible that you possess a certain header file that maps
MessageBox to MessageBoxW via a macro or a function.
If you #define UNICODE then the API calls resolve to Unicode functions, otherwise they resolve to ANSI functions.
....with a certain header file.
It is entirely
possible to build Win32 executables that will run as-is on everything from Win95 through Longhorn.


It's very possible to do so with any Win32 compiler.
Compile a Win32 program that uses a function like:

GetWindowTextW

Run the program on Win95 -> Win Millenium

The function will not do anything and the return value
won't mean anything, it's a dummy.

Run it on Win NT 4 -> Win 2000

It will run perfectly.

There's but one "W" function that will function on Win95 ->
Win Millenium and that's "MessageBoxW".

As for Windows XP. All versions of it have functional W and
A functions, although the A functions just perform a
conversion and call the W version, because WinXP is
Unicode. This is exactly what Windows NT did when you
called an A function.

-JKop
Jul 22 '05 #9
JKop wrote:
Mike Smith posted:

JKop wrote:

Consequently, WinNT progs
simply *won't* work on normal Windows 98, but Win98
progs *will* run
on WinNT.


Not only is this off-topic, it's patently false.

False.

The default use of
ANSI vs. Unicode API calls is determined by the compiler,


not by the OS.

False, it's determined by which you call.

MessageBoxA
MessageBoxW

There's no such Win32API function "MessageBox". It's very
possible that you possess a certain header file that maps
MessageBox to MessageBoxW via a macro or a function.


Uh, yeah, and that's how the Win32 SDK has come ever since NT 3.1, so I
didn't think it was worth mentioning - i.e. any decent Windows
programmer *knows* that already.
If you #define UNICODE then the API calls resolve to
Unicode
functions, otherwise they resolve to ANSI functions.


...with a certain header file.


Uh, yeah - the one supplied *by Microsoft* for *their* OS, since the
early '90s.
It is entirely
possible to build Win32 executables that will run as-is
on everything
from Win95 through Longhorn.

It's very possible to do so with any Win32 compiler.
Compile a Win32 program that uses a function like:

GetWindowTextW

Run the program on Win95 -> Win Millenium

The function will not do anything and the return value
won't mean anything, it's a dummy.

Run it on Win NT 4 -> Win 2000

It will run perfectly.

There's but one "W" function that will function on Win95 ->
Win Millenium and that's "MessageBoxW".

As for Windows XP. All versions of it have functional W and
A functions, although the A functions just perform a
conversion and call the W version, because WinXP is
Unicode. This is exactly what Windows NT did when you
called an A function.


And using the ...A() version of the function, with ANSI strings, will
perform correctly on all Windows versions, like I *said*.

--
Mike Smith
Jul 22 '05 #10
Mike Smith posted:
And using the ...A() version of the function, with ANSI strings, will perform correctly on all Windows versions, like I *said*.

--
Mike Smith

Back in the day, if one wanted to write a thoroughly
efficent prog for WinNT, they'd use the W functions. The
resulting executable wouldn't do anything on Win95 -> Win
Millenium.

End of discussion.

-JKop
Jul 22 '05 #11

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: t.schwenk | last post by:
hi ng! for our intranet i try to connect to the WinNT:// namespace from an asp (or from global.asa) to retrieve the usergroups which the current user is in (in order to regulate...
2
by: Sateesh K | last post by:
Hi, I am finding that VC++ 6.0 (with Service Pack VS6SP6 ) error gives me an error when pdb file is > 64 MB. Here is the exact error message. The OS is Win 2k " Linking... Creating library...
1
by: Jodi Wedll | last post by:
I am attempting to deploy my .Net Application from my WinXP development machine to production systems based upon WinNT and Win98. I believe that it is mostly working except for code relating to the...
1
by: Ivan | last post by:
Hi, I have moved an entire solution from .netframework 1.0 to 1.1; also I have migrated the solution to VS2003. After this I have added a new project (Web) to previous solution; I'm referencing...
1
by: Lloyd Dupont | last post by:
I have VS.NET 2005 standart edition. Before installing it I had installed VC++ express. I did modify some directory variable in VC++ express to have some project working. Now VS.NET is all...
10
by: Diego Martins | last post by:
I just discovered a serious issue when compiling code using auto_ptr<> and VC 8.0 consider some sort of create() function blahblah * create() { return new blahblah; } and a pretty auto_ptr
6
by: =?Utf-8?B?Tm90Q3BpUA==?= | last post by:
Hi, Can anyone tell me if it is possible to make the following function work under VC++.NET 2005 – x64 platform? How? Originally it works under VC++6. Thanks a lot! static PTIB GetTIB ( void...
2
by: Jim Michaels | last post by:
I just found out a nasty in the microsoft code base for Visual C++ 6.0 in winnt.h (has this changed for 2005?) - #define MAXIMUM_WAIT_OBJECTS 64 // Maximum number of wait objects #define...
1
by: mrpetegroups | last post by:
Hi - Problem: The file below has become zero length \winnt\assembly\GAC_MSIL\system.deployment\2.0.0.0_b03f5f7f11d50a3a \system.deployment.dll Details follow ... I've been programming...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.