That’s awas great! Thanks for the code!
Although I am extremely adept at programming VBA (in Excel) not VB, I can make out everything you specified. However, I don’t know what the ppgb object is. What does it refer to?
That’s awas great! Thanks for the code!
Although I am extremely adept at programming VBA (in Excel) not VB, I can make out everything you specified. However, I don’t know what the ppgb object is. What does it refer to?
My dyslexic fingers kicked in…
The first sentence was supposed to be…“That was great”
If you can program in C++, you don’t need a database to do that. The ID3 v2 standard has a format for storing lyrics and allows user-definable fields. What other information are you trying to track?
My C++ is EXTREMELY rusty and although this is going to be a great learning experience, I think using C++ would just be too frustrating with my competency level in it.
The “p” prefix simply means passed parameter, and the “pgb” stands for “Progressbar”, which is in the Microsoft Common Controls (not dialogue), found under the Components section of the Project menu. (It’s the same component that offers several objects: Progressbar, tab control, etcetera…) The idea is that you send the function a reference to the progressmeter you want to use to keep the user informed that the program didn’t lock up, and the function won’t need to reference a hardcoded form name. Typically, my code to call it would be:
ValidateSongs Me.pgb
Where the current form (referenced by the Me keyword) has a Progressbar control on it that I named “pgb”.
After posting, I have looked over some of my old code, and noticed that I didn’t demonstrate the Type declarations accurately. Instead of:
Public Type SongInfoType
Dim lngSongID As Long
Dim strTitle As String
Dim strArtist As String
Dim strLyrics As String
Dim dtmLastPlayed As Date
Dim lngPlayCount As Long
End Type
It should be:
Public Type SongInfoType
SongID As Long
Title As Variant
Artist As Variant
Lyrics As Variant
LastPlayed As Variant
PlayCount As Long
End Type
You don’t use the “Dim” keyword, and the prefixes seem a bit overkill, at least to me. (Or rather, they did when I wrote my last type declaration. They still do.) Also, I always get annoyed when my tables hold the perfectly legitimate Null value, which I love, but my type declarations bomb out with “invalid use of null”, so I switch all the non-numeric variables to type Variant. (That’s assuming you have default values for the numeric fields. If not, they should be Variants as well.)
Agreed 100%. But as I said, I’d start with your most comfortable data layer amd then switch it out to something better as needed. (I’ve heard good things about SQLite other than in this thread. but I find Access is so mind-numbingly simple that I usually go with that if given a choice. However, when MS releases a new Access version, it can introduce issues. Most of my apps shit the bed when Access 95 came out, for example. Pain in the ass, that upgrade.)
Let me know if you have any more questions. Happy to help.