Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Variable as a reference or value to a function
#21
nope; with strings the brackets don't have a function as with arithmetic (calculus order); so with strings they are just ignored

And in the initial example at the top, it was with numbers and it was actually THE reason for the confusion by TS (but I think nobody noticed so far :-))
45y and 2M lines of MBASIC>BASICA>QBASIC>QBX>QB64 experience
Reply
#22
believe it or not, the tip about parenthesis around the arguments that need to be preserved was the clue, even though enclosing the string arguments in parenthesis does not work in QB64, it apparently did work in VB 3, so I simply used temporary variables wherever needed.
Reply
#23
(08-08-2022, 03:37 PM)mdijkens Wrote: nope; with strings the brackets don't have a function as with arithmetic (calculus order); so with strings they are just ignored

And in the initial example at the top, it was with numbers and it was actually THE reason for the confusion by TS (but I think nobody noticed so far :-))

This?
Code: (Select All)
Print Using "Eingabe nach Funktionsaufruf: ###"; AlsWert((zahlwert))


Who is TS? =KP? BP needs to know. ;-)) I though KP was putting the () there to attempt passing by val.
But then he failed to change the value in the function LOL this is funny, like Hogans Heroes.
Code: (Select All)
Function AlsWert (eingabe As Integer)

  AlsWert = eingabe + 3
End Function
  724  855  599  923  575  468  400  206  147  564  878  823  652  556 bxor cross forever
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Function Pointers? BlameTroi 5 230 02-20-2026, 05:55 PM
Last Post: BlameTroi
  Variable length type declarations dano 5 688 08-06-2025, 09:53 PM
Last Post: dano
  Determining if variable or static string is passed to a Sub dano 9 1,220 06-20-2025, 06:31 PM
Last Post: CookieOscar
  Most efficient way to build a big variable length string? mdijkens 9 1,878 01-17-2025, 11:36 PM
Last Post: ahenry3068
  Huge array of variable length strings mdijkens 9 1,829 10-17-2024, 02:01 PM
Last Post: mdijkens

Forum Jump:


Users browsing this thread: 1 Guest(s)