Results 1 to 15 of 15

Thread: How do you jump back after VB6 moves to ".Show vbModal"?

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Jul 2017
    Posts
    761

    Lightbulb How do you jump back after VB6 moves to ".Show vbModal"?

    Hello!

    I spent too much time to locate / go back to where I was before VB6 put the cursor to the line

    Code:
    Form.Show vbModal, Me
    How do you handle this?
    I spent too much time to navigate back. In case somebody wants to see what I am talking about I have recorded a video here:



    What I sometimes do in such a situation:
    I use "Undo". Then VB6 undoes my last text input and automatically jumps to this line, but sometimes that stops the debugger, that is why I need to find a better way.

    Thank you!

  2. #2
    Lively Member
    Join Date
    Jul 2017
    Posts
    117

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    I'm a ctrl-Zer myself. Axtools Codesmart has a History panel that you could use. It's an expensive purchase though.
    Could use bookmarks but I don't know of any keyboard shortcuts for those, so it's a pain.

  3. #3
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Good question, something like "go to last edited line".
    But I don't know of anything like this in the VB6 IDE. I also use Control+Z and maybe Edit/Redo after that.
    If the action undoes some declaration, the debugger will stop, and if there is some subclassing or something, the IDE can crash

  4. #4
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    9,017

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by bahbahbah View Post
    It's an expensive purchase though.
    I don't envy someone in this position as I'd feel like this is a rip off given that this is a standard feature in modern versions of Visual Studio.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  5. #5
    PowerPoster VanGoghGaming's Avatar
    Join Date
    Jan 2020
    Location
    Eve Online - Mining, Missions & Market Trading!
    Posts
    2,619

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    There is a "Last Position" option in the context menu but for some reason it doesn't work in debug mode.

  6. #6
    PowerPoster
    Join Date
    Aug 2010
    Location
    Canada
    Posts
    2,891

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    If I've understood what you're looking for, pressing Ctrl+Tab will flip you back to the window that was active before the IDE jumps to the .Show vbModal line. The caret will be at the last position it was at too.

  7. #7
    Lively Member
    Join Date
    Jul 2017
    Posts
    117

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by Niya View Post
    I don't envy someone in this position as I'd feel like this is a rip off given that this is a standard feature in modern versions of Visual Studio.
    Certainly is a rip off in that respect. On the other hand, not a rip off as no way I'm going back to stock ever again. F that s.



    Quote Originally Posted by jpbro View Post
    If I've understood what you're looking for, pressing Ctrl+Tab will flip you back to the window that was active before the IDE jumps to the .Show vbModal line. The caret will be at the last position it was at too.

  8. #8

    Thread Starter
    Fanatic Member
    Join Date
    Jul 2017
    Posts
    761

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by jpbro View Post
    If I've understood what you're looking for, pressing Ctrl+Tab will flip you back to the window that was active before the IDE jumps to the .Show vbModal line. The caret will be at the last position it was at too.
    THANK YOU!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    I don't want to count the hours and hours, but rather days that I have spent on this task that (as you told you and you were right!) can be done with a key combination.
    Thank you!!!

  9. #9
    PowerPoster
    Join Date
    Aug 2010
    Location
    Canada
    Posts
    2,891

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by tmighty2 View Post
    THANK YOU!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    I don't want to count the hours and hours, but rather days that I have spent on this task that (as you told you and you were right!) can be done with a key combination.
    Thank you!!!
    Glad that did the trick! Hope it saves you some hours from this point forward

    Note that Ctrl+Tab cycles through the open windows in one direction, and Ctrl+Shift+Tab cycles through them in the opposite direction. Both of these shortcuts can be handy for hopping around your code when it spans a few different windows.

  10. #10
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    6,167

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Try using Ctrl+Shift+F2 to go to last position.

    I'm using Ctrl+L to navigate stack all the time too but here it won't be very useful.

    RC6 custom forms have this unfortunate side-effect where the application loop is actually replaced with a single VB6 form Show method call (i.e. a dialog loop) so Ctrl+Breaking always shifts focus to it.

    Btw, Ctrl+F6 = Ctrl+Tab and Ctrl+Shift+F6 = Ctrl+Shift+Tab

    cheers,
    </wqw>

  11. #11
    PowerPoster
    Join Date
    Aug 2010
    Location
    Canada
    Posts
    2,891

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by wqweto View Post
    Btw, Ctrl+F6 = Ctrl+Tab and Ctrl+Shift+F6 = Ctrl+Shift+Tab
    Wasn't aware of the F6 analogs, but Ctrl+Tab/Ctrl+Shift+Tab have one advantage: most tab based interfaces use the Ctrl+Tab/Ctrl+Shift+Tab shortcuts to navigate around tabs which ensures your keyboard muscle-memory is useful outside the VB6 IDE.

  12. #12
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    6,167

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by jpbro View Post
    Wasn't aware of the F6 analogs, but Ctrl+Tab/Ctrl+Shift+Tab have one advantage: most tab based interfaces use the Ctrl+Tab/Ctrl+Shift+Tab shortcuts to navigate around tabs which ensures your keyboard muscle-memory is useful outside the VB6 IDE.
    Yes, but inside ActiveReports designer Ctrl+Tab navigates reports controls so I’m always switching open files with Ctrl+F6 in VB IDE to not care if inside report designer or not.

  13. #13
    PowerPoster
    Join Date
    Aug 2010
    Location
    Canada
    Posts
    2,891

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by wqweto View Post
    Yes, but inside ActiveReports designer Ctrl+Tab navigates reports controls so I’m always switching open files with Ctrl+F6 in VB IDE to not care if inside report designer or not.
    Good thing we have 2 options then

  14. #14
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: How do you jump back after VB6 moves to ".Show vbModal"?

    Quote Originally Posted by wqweto View Post
    Btw, Ctrl+F6 = Ctrl+Tab and Ctrl+Shift+F6 = Ctrl+Shift+Tab
    Ctrl+F6 and Ctrl+Shift+F6 do nothing here (IDE in English).

  15. #15

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width