KnowledgeBase Archive

An Archive of Early Microsoft KnowledgeBase Articles

View on GitHub

Q157635: PRB: COPY FILE <filename> TO LPT1 Causes Invalid Seek Offset

Article: Q157635
Product(s): Microsoft FoxPro
Version(s): WINDOWS:3.0b,5.0,5.0a,6.0
Operating System(s): 
Keyword(s): kbvfp300 kbvfp500 kbvfp600kbbuglist
Last Modified: 01-MAR-1999

-------------------------------------------------------------------------------
The information in this article applies to:

- Microsoft Visual FoxPro for Windows, versions 3.0b, 5.0, 5.0a, 6.0 
-------------------------------------------------------------------------------

SYMPTOMS
========

In Windows 95, using the COPY FILE command to copy a file to LPT1 causes the
"Invalid Seek Offset" error in Visual FoxPro 5.0 and 3.0b if the port is not
captured. If the port is captured, the error "Invalid Path or File Name"
appears. However, in Windows NT 3.51 and Windows NT 4.0, using the COPY FILE
command to copy a file to LPT1 first returns a warning message that the file
will be overwritten unless SAFETY is set to OFF, then the message "Error Writing
to File" appears.

RESOLUTION
==========

To work around this problem, do the following:

"COPY FILE <filename> TO LPT1.DOS " (without the quotation marks)

MORE INFORMATION
================

Steps to Reproduce Behavior
---------------------------

1. Create a simple text file in Visual FoxPro as Test.txt.

2. In the Command window, type in the following code:

  "COPY FILE Test.txt TO LPT1:" (without the quotation marks)

Under Windows 95, you get an "Invalid Seek Offset" error message dialog box when
the port is not captured. If it is captured, the error "Invalid Path or File
Name" appears.

Additional query words:

======================================================================
Keywords          : kbvfp300 kbvfp500 kbvfp600 kbbuglist
Technology        : kbVFPsearch kbAudDeveloper kbVFP300b kbVFP500 kbVFP600 kbVFP500a
Version           : WINDOWS:3.0b,5.0,5.0a,6.0
Issue type        : kbprb

=============================================================================

THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Copyright Microsoft Corporation 1986-2002.