logfilename = os.path.join( os.path.dirname(os.path.realpath(__file__)), os.path.splitext(os.path.basename(__file__))[0] + '.log')
__file__ is the script file itself. From python3.9 above, it is an absolute path, otherwise the path passed by command line.
os.path.join joins two paths.
realpath returns a absolute path, it also resolves symbolic links. You can also call abspath or normpath.
dirname returns the directory.
splitext returns list of strings split by extension.
In current Internet environment, every PC is assigned a private IP. If global IP is…
You need to clear these two flags IMF_DUALFONT and IMF_AUTOFONT to keep font unchanged. [code…
I don't know what is going wrong but... How to fix it Open the solution…
Create a break point that hits when CreateProcess was called Enter a Function Breakpoint Enter…
#include #include #include #pragma comment(lib, "Shell32.lib") using namespace std; class MyClass { public: MyClass() {…