[dev] best way to debug a plugin

lspcity
2013-04-12
2013-04-12
  • lspcity

    lspcity - 2013-04-12

    What is the best way to debug a plugin?
    Currently I do some dump via messagedialogs, but I don't think that's the common way of debugging ;)

    But KeePass compiles a PLGX-file which cannot run in a debug, or can it?

    Thank you for your help.

    Best regards
    Lukas

     
  • Dominik Reichl

    Dominik Reichl - 2013-04-12

    A PLGX file should be created for the final distribution; it is not suited for debugging.

    When you compile your plugin using Visual Studio, it creates a DLL, which you can debug. After opening your plugin's solution, go 'Project' -> 'YourPlugin Properties' -> tab 'Debug', choose 'Start external program' as 'Start Action' and select the 'KeePass.exe' in the output folder of your plugin (which contains your plugin DLL). When you now start debugging, Visual Studio runs KeePass, and breakpoints within your plugin work fine.

    Best regards,
    Dominik

     
  • lspcity

    lspcity - 2013-04-12

    Thank you!
    It works great!

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks