• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 195
  • Last Modified:

My Word Processor won't run on WIn 98

Hi team,
I wrote a simplified word processor in Delphi.
I have a bug though that I can't understand.
The exe will run no trouble on Win 2000 or XP, but when you try and run it on 98 or 98 SE it won't run.
Instead it gives an rror message
"This program has performed an illegal operation and will be shut down"

THe next error message is
Exception EInOutErrorin module prjWriter.exe at 000B5A8A. invalid filename

I have created a log file in the project unit of the application, but this never gets created so I from this I gather that the application doesn't even start the reading any of the code at all...

Any ideas?

Myles :)
0
myleseven2
Asked:
myleseven2
  • 4
  • 4
  • 4
  • +2
1 Solution
 
moorhouselondonCommented:
Have you tried putting this switch at the beginning of your code:-

{$IOChecks Off}

0
 
Wim ten BrinkCommented:
The problem could be that you're using Windows NT-specific instructions in your code. W2K and XP have been based upon the Windows NT sourcecode and while the Windows API's for 95/98 and NT/W2K/XP is quite similar, there are also quite a few compatibility problems. I think you just found one.
The best solution that I've seen in these cases is to just put W2K as minimum operating system. Saves you a lot of compatibility issues. :-)

If you want to solve it, then let me make a wild guess. It complains about an invalid filename so either the filename you're using is too big or it contains invalid characters. Are you using unicode filenames? Is the filename longer than 255 characters?
0
 
HypoviaxCommented:
I agree with Workshop_Alex, it may just be worthwhile setting Win2K as the minimum OS. Win98 is very old nowadays, and i think you can safely assume *most* people will be using newer OSs.

The other option is to try and compile it using delphi on the 98 machine. This way you can determine more precisely from where the error is occuring.

Regards,

Hypoviax
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
HypoviaxCommented:
Also try using try except blocks around you code (TRY..Code..EXCEPT..handleit) this may remove the issue that is occuring on the 98 machine.
0
 
MadshiCommented:
Maybe madExcept can help locating the code at fault?

http://help.madshi.net/madExcept.htm
http://madshi.net/madCollection.exe

(free for non-commercial use)
0
 
HypoviaxCommented:
Madshi - you havn't been around here for ages. Good to see you back in action

Hypoviax
0
 
MadshiCommented:
Thank you!!   :-)

Well, I've been here all the time more or less, but I'm only looking into questions I like now!
0
 
Wim ten BrinkCommented:
Oh, no! Madshi, you're back? I was so hoping that I could gain enough points to finally get a higher score than you at EE... ;-)
Welcome back, old guy... :-P
0
 
MadshiCommented:
No no, as I said, I'm only looking into questions that I like (just like I've done in the previous months). So no change here. I'm not going to chase for points, anymore...
0
 
Wim ten BrinkCommented:
Phew! :-) Well, maybe you like to look at my post then, about loading an executable as a DLL. http://www.experts-exchange.com/Programming/Programming_Languages/Delphi/Q_21163413.html might be a real challenge for you. :-P
Oh, wait. Better don't. If you do answer it, I need to gain even more points to get past you... :)
0
 
myleseven2Author Commented:
Thanks for your help guys,
I have been away from the net for a while sorry about that....
I like the idea of putting W2K as the minimum operating system, but many of the users that (hopefully) will be using this program will have win 98 so I would like to try and solve the problem...

I will now try your suggestions...

Myles :o)
0
 
Wim ten BrinkCommented:
They still use Windows 98? I would have expected most people would be using XP by now. People who still use 98 probably have systems that are about 5 years old, or older. But the XP Home edition should be supported well by those older systems, I assume. Increasing the minimum requirements is just a good idea because you don't want to have lots of trouble maintaining backwards compatibility. If you have to adjust your code to support 98, you might even have to drom some functionality because it might not be available on 98.

Many companies put W2K as minimum requirement these days, btw.
0
 
myleseven2Author Commented:
Yes I know, the thing is I am building some programs for a group of elderly people and alot of them, but not all, have elderly systems.

By the way is there much of a difference between 98 and SE?

I can't certain yet but initial testing seems to point that

{$IOChecks Off}

might be enough to solve the problem for 98, but I need further testing before I can be sure...
0
 
HypoviaxCommented:
>>building some programs for a group of elderly people

Fair enough too. I reccomend that you don't push them onto newer OSs because they will have difficulty enough trying to learn the new one.

Have you tried compiling your app in a 98 machine?

Best Regards,

Hypoviax
0
 
moorhouselondonCommented:
I compile and test my programs on Win98 and that's how I found out/resolved a similar problem (ICELicense seems to cause this exception to occur on W98).  BTW Win98SE is still being sold in the Distribution channel so there's some life left in it yet.  

If it is ascertained that this solution works for you, if you are concerned that there may be knock-on effects with other OS's you can handle the exception rather than ignoring it (i.e. if win98 then ignoreexception else handlexception).
0
 
myleseven2Author Commented:
Well I got to work and left my copy of Delphi at home again.... Dohhhh!
So I will have to leave the experiment of installing Delphi onto the 98 platform till tomorrow, sorry for the time delay...

One issue we were concerned about with testing our system on a system with Delphi on it is that the program might use some files from the Installed Delphi and so testing a program on a system with Delphi installed would be quite different 2 testing on a system without delphi...

What are your thoughts?
0
 
moorhouselondonCommented:
If the BDE is being used and the aliases is being created manually (by going into the BDE to create them) then you are working on the same target data regardless of location of the program files.  If you dynamically create aliases to be in a directory relative to the installation directory then you should be ok (unless you are using the Registry to store values, or other things that are singular on the target system - an ini file in a specific, absolutely defined location for example).  

If this is software you are going to package up and send out, then any tests that involve the creating of the initial environment need to be tested by removing everything from the pc to install and test. If however everything is in its own subdirectory then install everything into a new testbed directory then this should isolate you from the development system (subject to my para 1 above).
0
 
myleseven2Author Commented:
I am sorry other problems came up that needed dealing with, but thank you for your patience...
I will close this question now so not to leave anyone hanging.
THanks all for your help.
There are still problems, when I get a bit closer to be able to solving them then I might post another question up on E-E

Thanks agaian

Myles
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 4
  • 4
  • 4
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now