Re: IDL_FileOpen problem? [message #20338] |
Tue, 13 June 2000 00:00 |
Nando Iavarone
Messages: 48 Registered: December 1998
|
Member |
|
|
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Ben Tupper wrote:
<blockquote TYPE=CITE>Hello,
<p>My eyes tend to glaze over when I see c code... but I think I see that
<br>you are expecting your 'foo' file to be binary format.
<br>If so, you should set the BINARY keyword to OPENW since the default
<br>behavior on WIN platforms is to write in text format.
<br> </blockquote>
<p><br>Hi Ben,
<br>sorry for your eyes ;o)
<p>I don't think so because I am writing unformatted.
<br>In fact the result is the same (and IDL_FileOpen should warrantee portability).
<br>I tried also to write the file using the IDL_FileOpen in write mode
and using the c-fwrite function. Nothing changes.
<p>I am waiting for the RSINC support answer.
<p>Thank you.
<br> Best regards,
<br> Nando
<pre>--
Nando Iavarone
Advanced Computer System - SPACE DIVISION
via Lazzaro Belli, 23
00040 Frascati - RM
Tel: +39-6-944091 (switchboard)
9440968 (direct)
E-mail:
f.iavarone@acsys.it
FrdndVrn@altavista.net</pre>
</html>
|
|
|
Re: IDL_FileOpen problem? [message #20341 is a reply to message #20338] |
Tue, 13 June 2000 00:00  |
Ben Tupper
Messages: 186 Registered: August 1999
|
Senior Member |
|
|
Hello,
My eyes tend to glaze over when I see c code... but I think I see that
you are expecting your 'foo' file to be binary format.
If so, you should set the BINARY keyword to OPENW since the default
behavior on WIN platforms is to write in text format.
Ben
Nando Iavarone wrote:
> Dear all,
> I have some problems reading files using DLM under win platform.
> I am using IDL 5.2.1 and VisualC++ compiler.
>
> I wrote a little file called 'foo', using the simple
>
> IDL> data = dindgen(10)
> IDL> openW, 1, 'foo'
> IDL> writeU, 1, data
> IDL> close, 1
>
> After it I need to read them from a c-function in a DLM.
>
>
>
> - The code below works fine on unix platform (SGI and linux) but it
> can't read data if used on WIN 98, NT.
> Anyone knows what's happening? A flag problem in the open?
> Note that after the IDL_FileOpen the same procedure is repeated using
> simple fopen, and all is ok.
>
>
--
Ben Tupper
Bigelow Laboratory for Ocean Science
tupper@seadas.bigelow.org
pemaquidriver@tidewater.net
|
|
|