I suggest you ...

Save/restore queries on close or manually

I'm a multitasker, and I usually have 7 or 8 (or 20) tabs open in LINQPad. When I need to restart my computer, or for whatever reason close LINQPad, I *could* to save each of my queries (coming up with a meaningful name for each), remember which ones I had open, and reopen them one by one when I restart, but I find it's quicker and easier to just kill LINQPad with Task Manager so that it will offer to reload all my tabs for me automatically. I would be nice if LINQPad had the option to save and restore all queries on close/start, and/or the option to save and reload a group of queries at will.

356 votes
Sign in
Password icon
Signed in as (Sign out)
You have left! (?) (thinking…)
Daddy shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

I need some feedback on this feature. First:
(a) Would you expect it to apply only to untitled queries? Or:
(b) Would you also expect it to apply to saved queries that were modified?
(The reason I ask is that option (a) is simple to implement, whereas option (b) creates numerous complications.)


Sign in
Password icon
Signed in as (Sign out)
  • Erdoğan Kürtür commented  ·   ·  Flag as inappropriate

    I believe it would be best if it works like Sublime Text.

    It reopens as if nothing happened. New and unsaved files are restored, edited files reloaded as unsaved. As if program not terminated and restarted but somehow hibernated.

    I believe sublime does this by recording everything in a work space, and reload this workspace so nothing is lost

  • Oleksii Vynnychenko commented  ·   ·  Flag as inappropriate

    Honestly, it seems like LinqPad is almost dead in terms of new features. This ticket is almost 8 years old and it's 2019 out there. Feature of auto-saving current session is a must for tool that intended to be opened/closed frequently that LinqPad is.
    Currently I'm using RoslynPad when I feel like I won't need to debug (the only feature that makes LinqPad unique for me) just because it provides that expected in 2019 experience of:
    "Run the tool and it will open at place where you left -> do your stuff -> close without thinking if your session will be lost or not".
    Look at Notepad++, RoslynPad, etc. - that's how good tools that intended to open/close frequently are designed.

  • Raimonds commented  ·   ·  Flag as inappropriate

    I would like "Notepad++" approach too - reopen tabs as they was before closing. It's simple and intuitive, for use as scratchpad with autosave feature too. Same here - often i do some code tests in Linqpad, with multiple important code fragments opened in different unsaved queries. OK, there is bruteforce 'end task' solution, but it is inconvenient and also it doesn't work for windows insider 'fast ring' machine due to frequent OS updates. At least, if possible - keep unsaved (new and untitled) queries …

  • Anonymous commented  ·   ·  Flag as inappropriate

    I would love this too.
    When you reopen LinqPad it should be the way it was when you closed it.
    If this is not easy, at least it should open the last opened saved queries.

  • Dennis Jones commented  ·   ·  Flag as inappropriate

    Personally, I would NOT want it to apply to named queries, only unnamed queries, because those are the ones that are lost if you close LinqPAD without saving/naming them. Also, oftentimes, I make changes to named queries that I don't want to save.

    So my vote is for this to apply to UNNAMED QUERIES ONLY.

  • Roy LIANG commented  ·   ·  Flag as inappropriate

    Even the most simple idea of saving a list of files (names) to a project, then loading a project opens all these files would be very helpful.

  • chojrak11 commented  ·   ·  Flag as inappropriate

    I think it should be similar behavior to what VS Code offers. Saved documents that were modified are just saved, untitled/unsaved documents are persisted in some temp area (in Local portion of user profile) and all of them are reopened next time LinqPad is started, in the same tab order. Thanks.

  • Union Palenshus commented  ·   ·  Flag as inappropriate

    Came here to request this feature and found out I'm in good company. I use the same workaround as everyone else, killing it with taskman, but this would make a lot more sense. Notepad++'s solution would work great for this. Joe, any update on this? Thanks!

  • Chris Core commented  ·   ·  Flag as inappropriate

    Infact, just implementing the behaviour that already exists when killing the LINQPad process would work perfectly well imo.

  • Chris Core commented  ·   ·  Flag as inappropriate

    @Daddy, you can do this now (although with a bit of workaround) by killing the LINQPad process in task manager. Seems that LINQPad has some kind of crash recovery built into it, so doing this will prompt you to re-open unsaved queries next time you launch :)

    R.e the feature behaviour, I also think it would be great to emulate the way that notepad++ deals with this.

  • Brad commented  ·   ·  Flag as inappropriate

    Option (a) would be nice, but (b) would be better.

    What I'm actually hoping for would just be to keep a list of open tabs (saved or not) that will be opened, but have that setting be localized. That way if I have two different portable deployments of LINQPad for different contexts, then I could open either of those windows and get back the tabs I was working on previously, for that specific portable deployment.

    This would be awesome!!! thanks for considering it!

  • Marty Casey commented  ·   ·  Flag as inappropriate

    I could really use this. My workaround of killing the process so LinqPad restores itself when I relaunch it is cumbersome to say the least.

  • Jude Melancon commented  ·   ·  Flag as inappropriate

    (b) does no harm over (a) obviously, but (a) would provide most of the benefit to my personal usage.

  • Shukhrat Nekbaev commented  ·   ·  Flag as inappropriate


    definitely some solution is required. For example like in Notepad++.

    I was also killing the process to preserve, but just now it started clean, I had tabs created in the last two or three weeks (I don't reboot that frequently). You can imagine my frustration ATM :( And it's not the first time either...

    Thank you!

    P.S. licensed user.

  • Marc Selman commented  ·   ·  Flag as inappropriate

    I would really like to see this implemented.
    Option (a) is mostly neccessary but for option (b) maybe you could:
    Save the query as an untitled query (same as (a)) but save the original saved query file location as meta-data.
    Then, when opening Linqpad again, all unsaved queries can open and if there's a file location as meta-data available, just check if that file still exists and open that file and replace the contents with the unsaved query.

  • Aaron Bauman commented  ·   ·  Flag as inappropriate

    Automatically save untitled queries.
    Ask to save titled queries.
    SQLPrompt does this and it hasn't bothered me yet.

  • Anonymous commented  ·   ·  Flag as inappropriate

    Pretty pretty please (b). Having this feature would pretty much mean my whole taskbar works the same way. (Notepad++, all the jetbrains stuff (phpstorm, datagrip, dotpeek etc), and chrome)

  • James Curran commented  ·   ·  Flag as inappropriate

    I was about to write that I'd be happy with (A), since saving a named file involves just clicking the toolbar icon --- then I realized that LINQPad doesn't have a "Save FIle" icon. GIve me that button, and I'd be happy with option (a).

  • Anonymous commented  ·   ·  Flag as inappropriate

    I wasn't kidding about buying LINQPad again for this feature. I've pre-emptively kept my word by just now buying a 2nd user license. GO LINQPAD!

← Previous 1 3

Feedback and Knowledge Base