Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Running foxpro in XP Mode of Windows7-- Can't maximize window. 2

Status
Not open for further replies.

peter1937

IS-IT--Management
Dec 16, 2011
7
CA
Hi all,
I am running 64-bit Windows7. In terms of running foxpro 16-bit applications I installed Virtual Pc and Windows XP Mode. After a little bit of struggle my apps finally working.

Now, last problem.When I run my BAT file -- it loads in a small window and when I am trying to maximize it --> error message "The video device failed to initialize for fullscreen mode".
Just to clarify -- error happens in the XP Mode of Win7.
Have tried couple of solutions found on the net, but still no luck.

Any suggestions?
 
What exactly is the BAT file you are referring to? Is it a file that launches your executable? And, if so, does the error message originate within the BAT file or the EXE file?

Put another way: What happens if you eliminate the BAT file and run straight from the EXE?

If the error originates from the EXE, which line of code is producing the error?

For what it's worth, my current application also programmatically maximises the window, and it runs happily in XP Mode.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips, training, consultancy
 
As Mike says above, the BAT file itself is not a FP/VFP file.
If that is the problem, then it is not a FP/VFP issue.

However if you eliminate using the BAT file altogether and just run the FP/VFP EXE file on its own from its own shortcut, then you should not have a problem.

Now if within your FP/VFP application you call for the execution of some BAT file, then you might get a different performance.

Perhaps some clarification of this BAT file would be in order to help us answer your question.

Good Luck,
JRB-Bldr
 
There is no exe file , it's a batch file essentially lunching foxpro2.6 multiple prgs.
Error produced NOT by bat file. It's just doesn't want to maximize because of some graphic limitations I guess?
One of the proposed solutions is to Disable Integration Features in XP Mode but it doesn't work for me :(
Is there a way to force maximizing window programmatically? What kind of code would I need to put in my batch file?
 
i would agree that this is not FP issue. for the time being i have no option not to use bat file, it's not up to me.
If it helps :
**************************************************************
@ECHO OFF
mode con lines=25
chcp 437
SET PATH=m:\;g:\vol1\apps\foxpro\foxprol;w:\;z:\;y:\;%PATH%
cls
if not exist l:\direct\*.* erreur
echo One moment please
l:
CD\DIRECT
FOXPROX -T MENU
cls
echo Return to menu
cdf:
*************************************************************
 
Let's get this right. You're saying the error is not produced by the batch file, right?

If so, then try running the app direct from Windows. In other words, set up a desktop shortcut with this target:

FOXPROX -T MENU

Then double-click on it. Do you have the same problem? If so, where does it occur?

Also, you said: Is there a way to force maximizing window programmatically?

I assumed that's what you are doing? If not, add this code near the start of your program:

_SCREEN.WindowState = 2

Oh, wait. You said you were running FoxPro 2.6. I can't remember how to maximise the window programmatically in that case. No doubt someone else will tell you.

Mike


__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips, training, consultancy
 
Oh, wait. You said you were running FoxPro 2.6. I can't remember how to maximise the window programmatically in that case. No doubt someone else will tell you.

MODIFY WINDOW SCREEN

(Don't complain to the language cops. This was about the same time we got EDIT NOEDIT and WAIT NOWAIT.)
 
Thank you all guys.
To Mike -- tried you shortcut solution -- same error message.
To Dan -- tried as well -- no go.

It must be something about video adapters or something. I don't think it has anything to do with batch itself,and as I said -- compiling exe is not an option.

We'll keep looking ...
 
Peter, you said: tried you shortcut solution -- same error message.

My suggestion wasn't meant to be a solution. It was a test, aimed at eliminating some variables. If the problem persists, the test has succeeded, in that it shows that it's not the BAT file where the problem lies.

The next thing to eliminate is FoxPro.

So, does the error occur with any other application, such as Word or Excel?

Is your app written in FoxPro for DOS? If so, does the error occur with other DOS apps (not FoxPro)? Or if you simply open a command window?

It's by eliminating variables in this way that you can home in on the solution.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips, training, consultancy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top