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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

String of Variable Length

Status
Not open for further replies.

GerritGroot

Technical User
Nov 3, 2006
291
ES
Hi,

Maybe a stupid question, but if I want to specifiy a string of a variable length, without it being an argument of a subroutine, what do I do?

CHARACTER*(*) :: ch

Is not allowed, because it's not an argument to a routine
(Never understood the extra (*) BTW)

CHARACTER, DIMENSION:)), ALLOCATABLE :: ch

Is an option, but that's an array of characters and not a string.

Is there a more elegant solution?
Any suggestions?

Thanks,

Gerrit
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top