From [log in to unmask] Wed Oct 8 22:45:29 1997
Date: Wed, 8 Oct 1997 08:44:56 -0400
From: Richard Shapiro <[log in to unmask]>
To: [log in to unmask]
Date: Wed, 8 Oct 1997 16:05:03 +1000 (EST)
From: robin <[log in to unmask]>
X-List: [log in to unmask]
From [log in to unmask] Wed Oct 8 14:49:43 1997
From: "Jimmy E. Touma" <[log in to unmask]>
To: <[log in to unmask]>
Subject: Assumed string length
Date: Tue, 7 Oct 1997 23:44:31 -0500
Hello everyone
I am using MS FPS 4.0 and am having problems with assumed character string
length. Here is what I am trying to do:
CHARACTER(2) :: str1, str2
CHARACTER(len = *) :: str3
...
str1 = '1 '
str2 = '2 '
str3 = 'file'//Trim(str1)//Trim(str2)//'.dat'
The error that I get is the following:
F:\Oct97\07\stark\f90\lines\ImpactLine.f90(108): error FOR3288: assumed
length is not valid for CHARACTER item. STR3 Error executing fl32.exe.
I am trying to use my data to create the names of my output files on the fly
but apparently I am doing some thing wrong. Can you help?
Try CHARACTER (LEN=10) :: str4
str4 = str3
and then use trim(str4) instead of trim(str3).
Dummy arguments aren't acceptable in a catenation operation.
Thanks in advance
Jim
No, that's not the problem;
Who says so?
If the error message obtained is "assumed length is not
valid for character item" it is reasonable to assume that
that is what the problem is, and that it's not an
implementation of F90.
Only a fragment of code is given, and no line number
is given, but from the way that the problem is presented,
it would appear that it's occurring
on the assignment involving catenation.
Any better ideas?
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|