Is this a bug or is this newby missing something

Everything else that doesn't fall into one of the other PB categories.
Songdog
New User
New User
Posts: 5
Joined: Wed Apr 12, 2023 4:13 pm

Is this a bug or is this newby missing something

Post by Songdog »

So I'm noticing that when I use the IDE to run a program then edit it and run again it runs the old code that was there b4 editing unless I close the IDE then reopen it again. Any one else having this problem Using doze 7..

I'm running some sample code that I hacked.

Code: Select all


;If OpenWindow(0, 0, 0, 230, 90, "Event handling example...", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
EnableDebugger
OpenWindow(0, 0, 0, 230, 90, "Event handling example...", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
someCondition=0
   ButtonGadget  (1, 10, 10, 200, 20, "Click me")
   CheckBoxGadget(2, 10, 40, 200, 20, "Check me")

   If CreateMenu(0, WindowID(0))
     MenuTitle("Menu")
     MenuItem(1, "Item 1")
     MenuItem(2, "Item 2")
     MenuItem(3, "Item 3")
   EndIf

   Repeat
     WWE = WaitWindowEvent()
     Result$ = Str(WWE)
     Select WWE
       Case #PB_Event_Gadget
         Eg$ = Str(EventGadget())
       ;  Debug "Eg = "+ Eg$
         Select EventGadget()
           Case 1 : Debug "Button 1 clicked! " + Result$ + " Eg= " + Eg$
           ;  Debug Result$
           Case 2 : Debug "Button 2 clicked! " + Result$ + " Eg= " + Eg$
           ;  Debug Result$
         EndSelect
         
       Case #PB_Event_Menu
         MenuNumber = EventMenu()
         Mn$ = Str(EventMenu())
       ;  Debug "Mn = " + Mn$
         Select EventMenu()
           Case 1 : Debug "Menu item 1 clicked! " + Result$ + " MN= " + Mn$
           ;  Debug Result$
           Case 2 : Debug "Menu item 2 clicked! " + Result$ + " MN= " + Mn$
           ;  Debug Result$
           Case 3 : Debug "Menu item 3 clicked! " + Result$ + " MN= " + Mn$
           ;  Debug Result$
         EndSelect
     EndSelect
    ; someCondition = 0
     If someCondition
       Break
     EndIf
   Until WWE = #PB_Event_CloseWindow
; EndIf
User avatar
mk-soft
Always Here
Always Here
Posts: 6246
Joined: Fri May 12, 2006 6:51 pm
Location: Germany

Re: Is this a bug or is this newby missing something

Post by mk-soft »

Settings adjusted by the IDE?

Preferences -> Editor
- Auto-save before compiling
- Save all sources with auto-save
My Projects ThreadToGUI / OOP-BaseClass / EventDesigner V3
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
Songdog
New User
New User
Posts: 5
Joined: Wed Apr 12, 2023 4:13 pm

Re: Is this a bug or is this newby missing something

Post by Songdog »

Thanks for the reply mk-soft.

I found
Preferences -> Editor under the file Menu, but could not find the options for
- Auto-save before compiling
or
- Save all sources with auto-save
what am I missing? :?
User avatar
mk-soft
Always Here
Always Here
Posts: 6246
Joined: Fri May 12, 2006 6:51 pm
Location: Germany

Re: Is this a bug or is this newby missing something

Post by mk-soft »

- Menu File
-> Preferences ...
--> Tree - Editor
My Projects ThreadToGUI / OOP-BaseClass / EventDesigner V3
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
BarryG
Addict
Addict
Posts: 4173
Joined: Thu Apr 18, 2019 8:17 am

Re: Is this a bug or is this newby missing something

Post by BarryG »

Songdog wrote: Fri Apr 14, 2023 10:23 pmwhen I use the IDE to run a program then edit it and run again it runs the old code that was there b4 editing
Sounds like you didn't compile/run, but just ran the code again. Any edits need a new compile/run each time. Auto-saving of the code isn't required (I never auto-save).
Songdog
New User
New User
Posts: 5
Joined: Wed Apr 12, 2023 4:13 pm

Re: Is this a bug or is this newby missing something

Post by Songdog »

Barry, you hit the nail squarely on the head.
Thank You
Post Reply