Search found 94 matches

by hoangdiemtinh
Sun Jul 07, 2024 2:50 am
Forum: Coding Questions
Topic: How to send a command to the "Download" button of Google Drive
Replies: 2
Views: 686

How to send a command to the "Download" button of Google Drive

Good morning.
My primary language is not English, so I am using Google Translate to post.

I have more than 4GB of RAR compressed data, I uploaded to Google Drive.
So how do I send a command to the "Download" button of Google Drive ?

The google drive link looks like this:


https://drive.google ...
by hoangdiemtinh
Sat Jun 29, 2024 3:28 pm
Forum: Windows
Topic: Pop-up Menu Font
Replies: 6
Views: 6681

Re: Pop-up Menu Font

Still error. Error in command:

Code: Select all

DrawText_(\hDC, options(\itemID), -1, @\rcItem, 0)
Array index out of bounds.

And I want to add my icon/png to this Menu. It support ?
by hoangdiemtinh
Sat Jun 29, 2024 2:35 pm
Forum: Windows
Topic: Pop-up Menu Font
Replies: 6
Views: 6681

Re: Pop-up Menu Font


Howzis?
Can't really get away from owner drawing the menu. But it's not difficult as you can see.


I added an OpenSubMenu("my SubMenu") , why does the error appear?


MenuItem(1, options(1)) ; You can use all commands for creating a menu
MenuItem(2, options(2)) ; just like in a normal menu ...
by hoangdiemtinh
Wed Jun 26, 2024 4:40 pm
Forum: Coding Questions
Topic: GetFirmwareType - Why always return 0?
Replies: 5
Views: 974

Re: GetFirmwareType - Why always return 0?

How? Can you explain it to me?
by hoangdiemtinh
Wed Jun 26, 2024 4:33 pm
Forum: Coding Questions
Topic: GetFirmwareType - Why always return 0?
Replies: 5
Views: 974

GetFirmwareType - Why always return 0?

Good afternoon.

I am new to PB. My primary language is not US/UK. I am using Google Translate.

I am practicing writing code to distinguish whether Windows is booting using FW MBR or UEFI.


Enumeration FIRMWARE_TYPE
#FirmwareTypeUnknown
#FirmwareTypeBios
#FirmwareTypeUefi
#FirmwareTypeMax ...
by hoangdiemtinh
Wed Jun 26, 2024 6:36 am
Forum: Coding Questions
Topic: How to search HEX value and replace all it
Replies: 15
Views: 2968

Re: How to search HEX value and replace all it

I found a module ( it's belong to C# ). Please convert it to PB.


namespace ClassicPatcher
{
internal class Patch
{
private static bool DetectPatch(byte[] sequence, int position, byte[] FindHex)
{
if (position + FindHex.Length > sequence.Length) return false;
for (int p = 0; p < FindHex ...
by hoangdiemtinh
Tue Jun 25, 2024 2:10 pm
Forum: Coding Questions
Topic: How to search HEX value and replace all it
Replies: 15
Views: 2968

Re: How to search HEX value and replace all it

Why not success ? ( Source at here )


EnableExplicit

#REPLACEONE = 1 ;make only one replacement, default is to search whole file and make multiple replacements (without this flag)
#STRINGMODE = 2 ;find string, default is hex (without this flag)
#CASESENSITIVE = 4 ;case sensitive string search and ...
by hoangdiemtinh
Tue Jun 25, 2024 11:28 am
Forum: Coding Questions
Topic: How can I identify the computer as a Laptop or PC/Desktop.
Replies: 6
Views: 1443

Re: How can I identify the computer as a Laptop or PC/Desktop.

I appreciate your suggestions.

I need that runs through winAPI or direct PB code. My program also need to run on winPE.
by hoangdiemtinh
Tue Jun 25, 2024 11:25 am
Forum: Coding Questions
Topic: How to search HEX value and replace all it
Replies: 15
Views: 2968

Re: How to search HEX value and replace all it

Searched the forum, I saw a post by @CELTIC88

I tried running it but got an error:

Code: Select all

ScrollBarGadget(): ScrollBar 'PageLength' must be lower than or equal to the 'Max' value.
and it's long for me to understand...
by hoangdiemtinh
Tue Jun 25, 2024 9:06 am
Forum: Coding Questions
Topic: How to search HEX value and replace all it
Replies: 15
Views: 2968

Re: How to search HEX value and replace all it

Have the same byte length.
( If possible, in case the byte length to replace is greater than the original byte length, insert 00 or FF ).
The file (.exe, .dll...) to find replacement bytes is made with unicode support.
by hoangdiemtinh
Mon Jun 24, 2024 11:22 pm
Forum: Coding Questions
Topic: How to search HEX value and replace all it
Replies: 15
Views: 2968

Re: How to search HEX value and replace all it

Is it possible to replace it with a hex segment whose length is smaller or larger than the found hex segment?
(If this is not possible, just use the equal length option.)

ex:
hex to find: 66696e642069742e
hex to replace: 666f756e642069742e

Hex code is converted from utf-8 string.
by hoangdiemtinh
Mon Jun 24, 2024 10:38 am
Forum: Coding Questions
Topic: How to search HEX value and replace all it
Replies: 15
Views: 2968

Re: How to search HEX value and replace all it

I replaced the same hex value (in my exe file) by using HxD Hex Editor.
But I want to automate this operation, it happens faster.
by hoangdiemtinh
Mon Jun 24, 2024 10:17 am
Forum: Coding Questions
Topic: How to search HEX value and replace all it
Replies: 15
Views: 2968

How to search HEX value and replace all it

I am new to PB. My primary language is not US/UK. I am using Google Translate.

I need to create a patch for a file.
I have the hex code from the following Procedure.

How to find all these HEX value and replace them in one file?
by hoangdiemtinh
Sat Jun 22, 2024 5:54 pm
Forum: Coding Questions
Topic: How can get uncompress size 7zip file without extract
Replies: 5
Views: 997

Re: How can get uncompress size 7zip file without extract

Not support 7z archive which have password
by hoangdiemtinh
Sat Jun 22, 2024 1:57 pm
Forum: Coding Questions
Topic: How can get uncompress size 7zip file without extract
Replies: 5
Views: 997

Re: How can get uncompress size 7zip file without extract

@Marc56US @boddhi Thank for your sharing !

All working so great.