Search found 147 matches

by novablue
Fri Jan 20, 2023 7:35 pm
Forum: Coding Questions
Topic: How can i delete a Symbolic Link/Softlink?
Replies: 6
Views: 304

Re: How can i delete a Symbolic Link/Softlink?

This seems to be the right answer :lol:

Code: Select all

RemoveDirectory_("C:\My Softlink\")
by novablue
Fri Jan 20, 2023 7:26 pm
Forum: Coding Questions
Topic: How can i delete a Symbolic Link/Softlink?
Replies: 6
Views: 304

How can i delete a Symbolic Link/Softlink?

Hi, I created a softlink using the following code but how can i delete the softlink itself "C:\My Softlink\" without actually deleting its contents from "C:\My Folder\". Prototype pCreateSoftLink(lpSymlinkFileName.p-Unicode, lpTargetFileName.p-Unicode, dwFlags) Procedure.i Create...
by novablue
Wed Dec 28, 2022 3:54 pm
Forum: Coding Questions
Topic: "Optimize generated code" breaks this code
Replies: 8
Views: 587

Re: "Optimize generated code" breaks this code

Thank you but i have no idea what any of this means, my assembly knowledge is short to zero. :lol:
by novablue
Tue Dec 27, 2022 8:46 pm
Forum: Coding Questions
Topic: "Optimize generated code" breaks this code
Replies: 8
Views: 587

Re: "Optimize generated code" breaks this code

Works here under Windows and Linux with all compilers. Except under macOS C-backend (Invalid ASM Code) EnableExplicit DeclareModule Main Declare.i Create() Interface IPublic Run.i() EndInterface Interface IPrivate Extends IPublic Endian.i(val.l) EndInterface EndDeclareModule Module Main EnableExpli...
by novablue
Tue Dec 27, 2022 8:36 pm
Forum: Tricks 'n' Tips
Topic: Simple preprocessor for string obfuscation
Replies: 12
Views: 6219

Re: Simple preprocessor for string obfuscation

Encryption strings without preprocessing. !macro ppublic name{ !if name eq _SYS_StaticStringEnd !repeat $-_SYS_StaticStringStart !load zczc from _SYS_StaticStringStart+%-1 !store zczc xor 137 at _SYS_StaticStringStart+%-1 !end repeat !end if !public name} !public fix ppublic CompilerIf #PB_Compiler...
by novablue
Tue Dec 27, 2022 8:27 pm
Forum: Coding Questions
Topic: "Optimize generated code" breaks this code
Replies: 8
Views: 587

Re: "Optimize generated code" breaks this code

Don't use ASM with C-Backend. Its not work with ARM processors ... Link: ASM and C-Backend bswap16/32/64 Thanks this seems to be what i was looking for. Procedure bswap32(value.l) CompilerIf #PB_Compiler_Backend = #PB_Backend_C !return __builtin_bswap32(v_value); CompilerElse !mov eax, dword [p.v_v...
by novablue
Tue Dec 27, 2022 8:14 pm
Forum: Coding Questions
Topic: "Optimize generated code" breaks this code
Replies: 8
Views: 587

Re: "Optimize generated code" breaks this code

I changed two parts. Define ret.l = 0 ; <--- Define ret.i = 0 Added line: !"mov %[ret], Eax;" EnableExplicit DeclareModule Main Declare.i Create() Interface IPublic Run.i() EndInterface Interface IPrivate Extends IPublic Endian.i(val.l) EndInterface EndDeclareModule Module Main EnableExpl...
by novablue
Tue Dec 27, 2022 5:27 pm
Forum: Coding Questions
Topic: "Optimize generated code" breaks this code
Replies: 8
Views: 587

"Optimize generated code" breaks this code

Hi, i am using the C backend compiler and "Optimize generated code" option turned on. Endian() here produces the wrong result when it is compiled WITHOUT DEBUGGER, running it with debugger the result is correct. EnableExplicit DeclareModule Main Declare.i Create() Interface IPublic Run.i()...
by novablue
Sun Dec 25, 2022 11:28 pm
Forum: Coding Questions
Topic: Weird bug causing slowdown with asm compiler
Replies: 3
Views: 300

Weird bug causing slowdown with asm compiler

Hi, i have a weird bug that i can not really reproduce in a small code, i can only try to explain what happens and how i "fixed" it, but maybe it can still be of help. I basically have this code where i call a procedure using the string output from another procedure. When i call DoSomethin...
by novablue
Mon Nov 21, 2022 6:20 pm
Forum: Coding Questions
Topic: Detect if window is hidden by other windows on top?
Replies: 2
Views: 320

Re: Detect if window is hidden by other windows on top?

Thanks i will give this a try!
by novablue
Sun Nov 20, 2022 5:03 pm
Forum: Coding Questions
Topic: Detect if window is hidden by other windows on top?
Replies: 2
Views: 320

Detect if window is hidden by other windows on top?

Hello, i need a way to detect if a window is totally hidden by other windows that are on top of it. I think it can be done by examining all visible windows and getting their dimensions with GetWindowRect_() but i dont know how i can combine all the different window dimensions to figure out if my win...
by novablue
Sat Nov 19, 2022 9:41 pm
Forum: Windows
Topic: Get the overall brightness level of a picture?
Replies: 5
Views: 2324

Re: Get the overall brightness level of a picture?

I would like do dim down every picture to the same rough brightness level to use it as a background.

Could someone smart modify this code to also SET the overall brightness of a picture? :lol:
by novablue
Wed Jun 01, 2022 7:01 pm
Forum: Coding Questions
Topic: Turn off #CURLOPT_SSL_VERIFYPEER for PB Http library
Replies: 30
Views: 1851

Re: Turn off #CURLOPT_SSL_VERIFYPEER for PB Http library

I don't know if it's related or not, but maybe the flag: #PB_HTTP_NoSSLCheck could do the job? Yes that fixed it! :mrgreen: Does anyone know why PB_HTTP_NoSSLCheck is needed for some sites, is this a bug or what could be the reason? Opening those same urls in a browser works always without a problem.
by novablue
Sun May 29, 2022 10:23 pm
Forum: Coding Questions
Topic: Turn off #CURLOPT_SSL_VERIFYPEER for PB Http library
Replies: 30
Views: 1851

Turn off #CURLOPT_SSL_VERIFYPEER for PB Http library

Hello, i have the problem that ReceiveHTTPMemory() and other commands from the HTTP library often fail where as using libcurl and setting #CURLOPT_SSL_VERIFYPEER to 0 will make the download work. Is There any way to use: curl_easy_setopt(handle, #CURLOPT_SSL_VERIFYPEER, 0) for the normal HTTP librar...