Debugging with JK-IDE

New to FreeBASIC? Post your questions here.
Post Reply
Syd
Posts: 3
Joined: Mar 29, 2022 1:06

Debugging with JK-IDE

Post by Syd »

New user of JK-IDE and FreeBASIC here. I recently rewrote an old QB 4.5 program in FreeBASIC. My program compiles without errors (sometimes) and now I need to debug the logic. I can use the IDE to step through the program one line at a time and I reach a point where the program asks for user input, but how do I use the IDE to view the program's output window and enter the user input that's required?

I wrote "sometimes" because with all the compile options (which I don't yet understand and which seem to have little documentation), sometimes I get no errors and sometimes I get many errors. In the IDE Compiler Options, I specified the path to the 32-bit and 64-bit compilers. When I run the Debug|Compile Debug (F11) command, sometimes I get hundreds of 64-bit assembler errors. Sometimes I get no 64-bit errors but it seems the compiler generated only a 32-bit EXE file. If I delete the path to the 32-bit compiler and point only to the 64-bit compiler, I receive an error saying the 32-bit compiler can't be found. Does the Debugger work only with 32-bit code? Is there a different IDE that's considered easier to use/more popular that also has debugging tools?
Xusinboy Bekchanov
Posts: 782
Joined: Jul 26, 2018 18:28

Re: Debugging with JK-IDE

Post by Xusinboy Bekchanov »

With a debugger I can suggest FBEdit, VisualFBEditor, VisualFreeBasic, VSCode.

Debuggers separately: FBDebugger, FrontEnd GDB for freebasic, gdb, gede, insight and etc.
Syd
Posts: 3
Joined: Mar 29, 2022 1:06

Re: Debugging with JK-IDE

Post by Syd »

Thanks, I'll take a look at those other IDE options.

Meanwhile, is there any way to interact with a program running in JK-IDE debug mode? It seems there must be a way, but I've been looking for several days and I can't find it. My program includes code that says something like:

Dim Choice as STRING
Input "Make a selection, Yes or No"; Choice

but the debugger continues past the Input command when I'm stepping through the program and it leaves Choice = "". I need to be able to answer Yes or No, then press <enter> to continue.
ktuee753
Posts: 12
Joined: Mar 23, 2022 17:04

Re: Debugging with JK-IDE

Post by ktuee753 »

If you are still insisting on using said IDE, you should contact the developer directly. This is the website of it I found via Google search: https://jk-ide.jimdofree.com/ The developer of it used to lurking on this forum but I don't remember his account name and don't recall ever seeing him active.
paul doe
Moderator
Posts: 1730
Joined: Jul 25, 2017 17:22
Location: Argentina

Re: Debugging with JK-IDE

Post by paul doe »

ktuee753 wrote: Mar 30, 2022 6:08 ...
The developer of it used to lurking on this forum but I don't remember his account name and don't recall ever seeing him active.
'Lurk' on this forum, eh?

viewtopic.php?p=268180#p268180

You will be surprised to know that he was, at one point, developing the compiler.
ktuee753
Posts: 12
Joined: Mar 23, 2022 17:04

Re: Debugging with JK-IDE

Post by ktuee753 »

paul doe wrote: Mar 30, 2022 10:40
ktuee753 wrote: Mar 30, 2022 6:08 ...
The developer of it used to lurking on this forum but I don't remember his account name and don't recall ever seeing him active.
'Lurk' on this forum, eh?

viewtopic.php?p=268180#p268180

You will be surprised to know that he was, at one point, developing the compiler.
Contributors. Like me. I also contributed under another name. Contributors come and go. Developers are always with the project.

You have to agree with me that he is no longer there, don't you? The only memory I recall of him is he advertised his IDE on the forum and suddenly gone. This IDE is primarily for PowerBASIC, FreeBASIC is only the second thought.
paul doe
Moderator
Posts: 1730
Joined: Jul 25, 2017 17:22
Location: Argentina

Re: Debugging with JK-IDE

Post by paul doe »

ktuee753 wrote: Mar 30, 2022 13:21 ...
The only memory I recall of him is he advertised his IDE on the forum and suddenly gone.
...
That's why I posted that, to refresh your memory. At one point, he was involved in developing the compiler (preprocessor, most specifically; but he also did some work on arrays). That he is active nowadays or not is irrelevant.
Syd
Posts: 3
Joined: Mar 29, 2022 1:06

Re: Debugging with JK-IDE

Post by Syd »

Thanks, guys. I haven't written new code in awhile and this is the first IDE I've used since QB 4.5, but I get the impression I'm struggling with an IDE that's not quite ready for FreeBASIC prime time.

Which IDE do most people use? I don't need anything fancy. Something similar to QB 4.5 that lets me compile 64-bit code and step through it while setting break points and watching variables would be perfect. I could even compile the source code myself from a command prompt if I understood which FreeBASIC switches to use. The IDE's main requirement would be to provide a tool I can use to help debug the program's logic. (Or is that considered a crutch these days? Do most people just insert IF...THEN, PRINT, and PAUSE statements, etc. in their code then compile again when they're troubleshooting?)
adeyblue
Posts: 299
Joined: Nov 07, 2019 20:08

Re: Debugging with JK-IDE

Post by adeyblue »

Syd wrote: Mar 29, 2022 19:18 but the debugger continues past the Input command when I'm stepping through the program and it leaves Choice = "". I need to be able to answer Yes or No, then press <enter> to continue.
See if there's a build option for 'windows app'/'Windows gui app' or if '-s gui' is in the place where you can specify compiler command line options.
If you turn that option off / delete that part of the command line and rebuild, that'll probably fix it.
Post Reply