Quantcast
Browsing all 1449 articles
Browse latest View live

How to retrieve OS Language

This code will detect the OS Language of your windows Just call Debug.Print DetectOSLanguage() Code: Private Declare Function GetUserDefaultLangID Lib "kernel32" () As Integer Public Function...

View Article


Download file from WEB in a few lines

This very short code can download a file from an URL : Ex : Call DownloadFile("https://www.vbforums.com/attachment.php?attachmentid=179280&d=1605528528", "D:\test.zip") Code: Public Function...

View Article


Generate a Prime number of 8 Digits

Generate a Prime number of 8 Digits (you can adjust if you need more). I needed 8 digits pour internal security checks Code: Public Function EightDigitPrime() As Double   '...

View Article

Retrieve the Dropbox folder

Retrieve the Dropbox folder ? Global_GetDropboxFolder() Code: Option Explicit Public Function Global_GetDropboxFolder() As String   '...

View Article

Here's code to get any part of a URL.

Just copy the code from the below code box and paste it into a module, and you can use it to get any part of a URL. The part numbers are as follows. 0 = protocol 1 = username 2 = password 3 = host 4 =...

View Article


MS-OXRTFCP Compressed RTF Decompression Methods

I had a need to decompress MS-OXRTFCP Compressed RTF data that is used by Outlook messages. The format is described here in great detail: https://interoperability.blob.core.w...OXRTFCP%5d.pdf I wasn't...

View Article

Image may be NSFW.
Clik here to view.

Password Protection

Protecting passwords is not a simple task. For material that is not highly sensitive, it is enough just to make it difficult for the hacker. That involves using passwords at least 8 characters in...

View Article

Image may be NSFW.
Clik here to view.

(VB6) Get the main or prevalent color tone of a picture

Some applications set a background color (or even other "theme" colors) based on an image that the user selects. That's the idea, to get the main color tone of an image. Download from GitHub. Attached...

View Article


Transmit Executables

I discovered a way to get around the problem of web bowsers (eg. Google Chrome) and mail servers (eg. Gmail) blocking executable files without any notification or bypass method. The servers do not...

View Article


Modal mode to show forms that allows non-modal forms

This is a simple function that can be used as a replacement to show forms "modally" but still allow to show non-modal forms: In a module: Code: Private Declare Sub Sleep Lib "Kernel32" (ByVal...

View Article

[VB6] WinXP compatible PBKDF2

This one uses legacy CryptoAPI and requires XP for HMAC support and XP SP3 minimum for the SHA-2 support for the hash function (i.e. SHA256, SHA384 and SHA512) while MD5 and SHA1 are always supported....

View Article

Image may be NSFW.
Clik here to view.

Hide IDEOwner Class Window when loading IDE

I'm not sure if this just happens when running SDI (which is the only way I run) for the VB6 IDE, or if it happens for everyone. But, when I load the IDE, ever since about the beginning of Windows 10,...

View Article

NaN and Inf numbers for IEEE Singles in VB6

I needed this the other day, so I coded it up (IEEE Single Precision): Code: Option Explicit ' Public Declare Function GetMem4 Lib "msvbvm60" (ByRef Source As Any, ByRef Dest As Any) As Long ' Always...

View Article


Enum windows without any widely scoped variables

This isn't anything terribly special, but it is something I've been wanting to do for some time. It's just a top-level window enumeration, but it's accomplished without any global nor module level...

View Article

Image may be NSFW.
Clik here to view.

VB6 R-Tree Demo for large Game-Maps

In larger 2D (or 2.5D) Games, there's often the question of efficient Map-Handling... Not only with regards to Map-creation or -definition, but also with regards to efficient re-rendering after the...

View Article


Image may be NSFW.
Clik here to view.

[VB6, Win7+] Undocumented ListView Feature: Multiselect in first column like...

Undocumented ListView Features : Part 5 - Explorer-style selection See Also: Part 1 - Footer Items | Part 2 - Subsetted Groups | Part 3 - Groups With Virtual Mode | Part 4 - Column Backcolor In...

View Article

Image may be NSFW.
Clik here to view.

[VB6, Win7+] Undocumented ListView Feature: Multiselect in columns like Explorer

Undocumented ListView Features : Part 5 - Explorer-style selection See Also: Part 1 - Footer Items | Part 2 - Subsetted Groups | Part 3 - Groups With Virtual Mode | Part 4 - Column Backcolor In...

View Article


Image may be NSFW.
Clik here to view.

[VB6] Using IShellWindows to register for SHOpenFolderAndSelectItems

Shell Window Registration V2 People who've made Explorer replacements or other apps that display a window have found that they can, at best, get the folder passed to them when someone uses 'Show in...

View Article

Image may be NSFW.
Clik here to view.

Homegrown Popup Menus with Tooltips

The main downside to my homegrown approach is that it won't work on modal forms. However, I try to not do that, so this serves my needs well. The main reason I did this is that I wanted popup menus...

View Article

Image may be NSFW.
Clik here to view.

VB6 DPI-awareness via RC6/RC6Widgets (and Device-Independent-Pixels)

Just some Drop-In-Code (about 140 Code-Lines) for a normal VB6-Form, producing the following output: For those not yet familiar with the RC5/RC6 Widget-concept, here is a Tutorial-Link:...

View Article
Browsing all 1449 articles
Browse latest View live