comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Dumb problem with STRPOS
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Dumb problem with STRPOS [message #4738] Fri, 14 July 1995 00:00 Go to previous message
steele is currently offline  steele
Messages: 5
Registered: March 1994
Junior Member
Can someone explain the following behaviour to me?

IDL> help,/st,!version ; Here's the situation.
** Structure !VERSION, 3 tags, length=24:
ARCH STRING 'mipseb'
OS STRING 'RISC/os'
RELEASE STRING '3.1.0'
IDL> test='c000.' ; define a string
IDL> help,test ; check it is a string
TEST STRING = 'c000.'
IDL> print,strpos(test,'000') ; search for a substring
1
IDL> print,strpos(test,'000.') ; and a slightly different one
1
IDL> test='c0000.' ; add a '0'
IDL> help,test
TEST STRING = 'c0000.'
IDL> print,strpos(test,'000') ; search again
1
IDL> print,strpos(test,'000.') ; Why isn't this substring found???
-1

I checked the manual for this version and it says nothing that would
explain this. BTW, it's nothing to do with octal constants.

All suggestions gratefully received!

Dave

--
David Steele | Internet : steele@aragorn.phys.ucalgary.ca
Dept. of Physics and Astronomy | SPAN : CANCAL::STEELE
The University of Calgary | Phone : +1 403 220 8651
OPINIONS EXPRESSED WITHIN ARE MY OWN AND NOT THOSE OF THE UNIVERSITY OF CALGARY
[Message index]
 
Read Message
Read Message
Previous Topic: idl programs for image segmentation & volumetric brain MRI
Next Topic: Are handles garbage collected?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 08:35:17 PDT 2025

Total time taken to generate the page: 0.48321 seconds