Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Confused about mid() command
#8
(06-14-2024, 08:34 PM)johnno56 Wrote: hmm... Interesting response... I am receiving mixed messages... On one hand, "can't" (cannot) implies a "No"... But, "can't really" implies a measure of doubt and conveys a possible interpretation of... "No. But I dare you to try". I enjoy a good puzzle, but when it comes to coding, I find myself at the shallow end of the "smart" pool... lol

Not a problem... Time for new train of thought... The only problem is that I do not have a ticket... Boom Boom.... lol

Thank you for responding... Wink


Haha Smile

Strings are like numbers. You can't change a string without getting a new string. That's why mid/left/right/replace all return new strings. It doesn't really matter. There's no simple way of replacing a character at a certain index in a string with another character. If you know what character it is, you could probably use 'replace' to get a new string:

Code:
foo = "ABCDEF"
pln "foo = " + foo

foo = replace(foo, "C", "Z")
pln "foo = " + foo

system "pause"

Output:
foo = ABCDEF
foo = ABZDEF
Reply


Messages In This Thread
Confused about mid() command - by johnno56 - 06-11-2024, 01:39 AM
RE: Confused about mid() command - by 1micha.elok - 06-11-2024, 10:27 AM
RE: Confused about mid() command - by johnno56 - 06-11-2024, 12:25 PM
RE: Confused about mid() command - by 1micha.elok - 06-12-2024, 09:46 AM
RE: Confused about mid() command - by johnno56 - 06-12-2024, 07:59 PM
RE: Confused about mid() command - by Marcus - 06-14-2024, 01:43 PM
RE: Confused about mid() command - by johnno56 - 06-14-2024, 08:34 PM
RE: Confused about mid() command - by Marcus - 06-15-2024, 08:23 AM

Forum Jump:


Users browsing this thread: 2 Guest(s)