?
Solved

visual foxpro spellchk.app doesn't work

Posted on 2011-10-16
30
Medium Priority
?
102 Views
Last Modified: 2016-06-18
Here's the code.

Use inventory
define window memo1 name oSpellCheck title "Spell Checker" from 7,44 to 24,92 double zoom
oSpellCheck.autocenter=.T.
Modi memo inventory.ocr window memo1 nowait
do 'c:\PROGRAM FILES\MICROSOFT VISUAL FOXPRO 9\spellchk.app
Close memo inventory.ocr
release window memo1

when it executes the line spellchk.app it says source is not available.

This is Windows 7.  spellchk.app is from a VFP5 install. However this is VFP9. It was working on a different XP computer before. I've tried the compatibility box for XP service pack 2 and 3. No luck.

Please advise. Thanks!

0
Comment
Question by:coldfusionguy
  • 9
  • 8
  • 7
  • +2
28 Comments
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 36977649
Maybe it is designed to call a 32-bit function which is now 64-bit in Windows 7? Or maybe it does not have access privileges to a certain folder.
0
 
LVL 27

Assisted Solution

by:CaptainCyril
CaptainCyril earned 664 total points
ID: 36977652
0
 
LVL 30

Expert Comment

by:Olaf Doschke
ID: 36977872
VFP is backward compatible, but you can't expect objectcode of VFP5 to work in VFP9. I'd say you need sources and need to recompile in VFP9.

Cyril points you to a completely new and different spell checker done by Craig S- Boyd. You should perhaps go that route. VFP9 does still have the _spellchk system variable, so in principle it would support a spell checker for the vfp text editor, but there is neither spellchk.app, nor is there a spellchecker source code in the xsource directory or in tools. Spellcheckíng is no part of vfp9 anymore.

Bye, Olaf.
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 27

Expert Comment

by:CaptainCyril
ID: 36977946
I also use Word's spell checker but I have done it in a different way using RTF controls.
0
 

Author Comment

by:coldfusionguy
ID: 36978413
Thanks for the comments, but as I mentioned before, this did work in VFP9 on an XP computer. I'm running this on a 32 bit Windows 7 machine and  I've shared the folder where the spellchk.app is located. I've tried the Word spell checker but can't get it to work either. I don't think Craig Boyd's spell checker lets you type in different spellings that are not already in his dictionary. It seems pretty limited.

Any other ideas?
0
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 36978416
Then I would check what the spellchk.app is accessing and allow those folders. Windows 7 is very stringent with access privileges. It could also be the temporary folders where the spellchk is using.
0
 
LVL 30

Expert Comment

by:Olaf Doschke
ID: 36978561
Well, I'd say you should set the _spellchk system variable at runtime, and for sure endusers won't have a VFP program folder, that is not legal to distribute, so the spellchk.app file needs to be in your applications folder or in some extra folder, eg in appdata or c:\Users\Public\

User will just need read and execute rights on the app file, so your application directory should be sufficient, but it does not automatically install, does it?

Bye, Olaf.
0
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 36978576
Windows XP is very forgiving if you create files in Program Files or execute an app in any folder. Windows Vista and 7 are sure not.
0
 
LVL 30

Accepted Solution

by:
Olaf Doschke earned 672 total points
ID: 36979177
If spellchk.app itself writes to the directory it is installed into, what Cryil says about Vist/Win7 vs XP is of course valid. Then you better install spellchk.app to a folder users also have write permission to and config _spellchk to that location. And of course change your DO ... spellchk.app, perhaps to DO (_spellchk), which would also need that change of the system variable, of course, but would always be kept in synch by only changing the system variable at application start.

Bye, Olaf.
0
 
LVL 2

Expert Comment

by:jsrebnik
ID: 36979243
To eliminate one possibility in the Win XP vs Win7 comparison, try turning off Win 7 User Account Controls  to see if it makes a difference.
0
 
LVL 43

Assisted Solution

by:pcelba
pcelba earned 664 total points
ID: 36979958
This spellchecker should work: http://www.hallogram.com/foxspell/index.html (Hallogram also notes: The spell checker that comes with FoxPro for Windows and VFP cannot be distributed with your .APP or .EXE file.)

0
 
LVL 43

Expert Comment

by:pcelba
ID: 36980171
I've did more investigations...

VFP 6 SpellChecker works in my Vista under VFP 9 SP2 executed under Admin account. Vista has similar restrictions as W7, so it should be fasible.

BUT, read this: http://support.microsoft.com/kb/175620/en-us?fr=1
You will need VFP 6 installed on every computer which uses SpellChecker...
0
 

Author Comment

by:coldfusionguy
ID: 36980914
Yes, I understand the limitations re: distribution. That's no problem as we only have one workstation that uses it. But why VFP 6?
0
 
LVL 43

Expert Comment

by:pcelba
ID: 36981126
Why VFP6? It is the last VFP version delivered together with spellchk.app. I cannot say if this version differs from the one delivered together with VFP 5 because I don't have it at hand just now.

You should also check whether all C libraries necessary for the spellchecker are present on the W7 computer.
0
 

Author Comment

by:coldfusionguy
ID: 36981301
I'll give that a shot. thanks.
0
 

Author Comment

by:coldfusionguy
ID: 36981964
Ok, I'm kinda back to the best place I've been with this, but it's still not working 100%.

The spell checker works, then when the spell check dialog box is closed I get 5 messages that say there are syntax errors. No other code is running. I've shared the c:\devstudio and c:\devstudio\vfp folder with everyone.

SET PATH TO c:\devstudio\vfp
RELEASE WINDOWS
CLOSE all
USE table2
DEFINE WINDOW SpellChecker FROM 0,0 TO 50,50 NOZOOM float
ACTIVATE WINDOW SpellChecker
MODIFY MEMO abstract WINDOW spellchecker nowait
DO c:\devstudio\vfp\spellchk.app

What should I try next? Thanks.
0
 

Author Comment

by:coldfusionguy
ID: 36981975
This is installed on yet another windows 7 test computer. I installed VFP5 first (I don't have a VFP6) and then I installed VFP9 with Security Pack 2 installed.

0
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 36981991
0
 

Author Comment

by:coldfusionguy
ID: 36982117
Yes, I know about the Word alternative. But I haven't been able to focus on reprogramming it. I'm so close to getting the original solution to work.
0
 
LVL 43

Expert Comment

by:pcelba
ID: 36982330
DO these error messages say something about Method and Line number?
0
 

Author Comment

by:coldfusionguy
ID: 36982506
No, just syntax error, 5 times. It does finish the spell check properly though. It replaces misspelled words and everything seems fine. It's just when it closes down the spellchk.app that these errors occur. This did happen before on the XP computer.
0
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 36982570
Probably cleanup deleting stuff.
0
 
LVL 43

Expert Comment

by:pcelba
ID: 36982705
If you change ON ERROR then it could tell more (or suppress the message completely).
0
 

Author Comment

by:coldfusionguy
ID: 36986803
I've been successful in suppressing the error messages! However, I'd like to see what messages I can get out of it though. So far, only Syntax Error. How would I get more verbose errors to show? Thanks.
0
 
LVL 43

Expert Comment

by:pcelba
ID: 36987382
ON ERROR WAIT WINDOW "Error: " + TRANSFORM(ERROR()) + " " + MESSAGE() + ;
   CHR(13) + "Line: " + TRANSFORM(LINENO()) + " " + MESSAGE(1) + ;
   CHR(13) + "Module: " + SYS(16)

To provide an output LINENO() and MESSAGE(1) requires debug info in compiled code. Spellchk.app does not contain it most probably.

BTW, did you hear about Refox?
0
 

Author Comment

by:coldfusionguy
ID: 36987448
Refox looks great. We don't package software though; we just use it for in house programs such as a home grown book cataloguing system for Mail Order Manager.

I'll give the On Error a shot later today or tomorrow and will report back.
0
 
LVL 43

Expert Comment

by:pcelba
ID: 41658145
Hard to decide... I would recommend to split points:
https:#a36979177
https:#a36977652
https:#a36979958
0
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 41658862
Split points just as pcelba suggests.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft Visual FoxPro (short VFP) is a programming language with it’s own IDE and database, ranking somewhat between Access and VB.NET + SQL Server (Express). Product Description: http://msdn.microsoft.com/en-us/vfoxpro/default.aspx (http://msd…
This holiday season, we’re giving away the gift of knowledge—tech knowledge, that is. Keep reading to see what hacks, tips, and trends we have wrapped and waiting for you under the tree.
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…
As many of you are aware about Scanpst.exe utility which is owned by Microsoft itself to repair inaccessible or damaged PST files, but the question is do you really think Scanpst.exe is capable to repair all sorts of PST related corruption issues?
Suggested Courses

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question