Author Topic: I have an issue.  (Read 3654 times)

0 Members and 1 Guest are viewing this topic.

Offline gabrilesi95

  • Newbie
  • Posts: 1
    • View Profile
I have an issue.
« on: December 30, 2020, 06:22:04 am »
So, when I try to set the variable EP in one of my programs, it just simply won't change the variable. Does anyone know what the problem is? If so, please tell me. (I think it is a bug or the program is just out of memory, although it is using 113.3 MB of memory, it hasn't given me an error.)

Offline SMcNeill

  • QB64 Developer
  • Forum Resident
  • Posts: 3972
    • View Profile
    • Steve’s QB64 Archive Forum
Re: I have an issue.
« Reply #1 on: December 30, 2020, 06:38:53 am »
Share the code, please.  I’d imagine it’s a scope error, with a local variable not sharing values, or else a separate routine resetting the value back to 0.
https://github.com/SteveMcNeill/Steve64 — A github collection of all things Steve!

Offline bplus

  • Global Moderator
  • Forum Resident
  • Posts: 8053
  • b = b + ...
    • View Profile
Re: I have an issue.
« Reply #2 on: December 30, 2020, 11:04:28 am »
+1 Yes, you might find the problem yourself by isolating it with fewest lines of code possible.

On the other hand, sometimes you need the Keyword or Command or the general topic under which to search Help,

and sometimes you just gotta share the code :)
« Last Edit: December 30, 2020, 12:32:22 pm by bplus »

Offline Pete

  • Forum Resident
  • Posts: 2361
  • Cuz I sez so, varmint!
    • View Profile
Re: I have an issue.
« Reply #3 on: December 30, 2020, 12:52:46 pm »
Make sure you have not dimensioned that variable as something else, some other place. For instance, if I have a DIM a as INTEGER and set it to the value of 3, and then in  some sub I try to make a = 5, The program thinks I mean let a! = 5, the SINGLE default. So in fact, I now have two variables, both named a, but with two different values. The a in the sub gets set to 5, but when the program runs back to the main, or whatever sub the a variable was DIMmed in, it retains the value 3.

Of course it could be other things, but this just came to mind. Sometimes in a lot of code, it just takes one simple continuity mistake to make a problem.

Pete
Want to learn how to write code on cave walls? https://www.tapatalk.com/groups/qbasic/qbasic-f1/

Offline Cobalt

  • QB64 Developer
  • Forum Resident
  • Posts: 878
  • At 60 I become highly radioactive!
    • View Profile
Re: I have an issue.
« Reply #4 on: January 01, 2021, 12:36:21 pm »
as Steve said, we need the code.

If you want definitive help with this issue we need to see your code, otherwise we are shooting in the dark.
Granted after becoming radioactive I only have a half-life!

Offline Pete

  • Forum Resident
  • Posts: 2361
  • Cuz I sez so, varmint!
    • View Profile
Re: I have an issue.
« Reply #5 on: January 08, 2021, 09:30:38 pm »
Me aveetar spends half of its time shootin in the dark, varmint!
Want to learn how to write code on cave walls? https://www.tapatalk.com/groups/qbasic/qbasic-f1/

Offline SpriggsySpriggs

  • Forum Resident
  • Posts: 1145
  • Larger than life
    • View Profile
    • GitHub
Re: I have an issue.
« Reply #6 on: January 15, 2021, 11:28:59 am »
I guess the issue resolved itself.
Shuwatch!