How Can I Create A

BlitzPlus Forums/BlitzPlus Programming/How Can I Create A

Doorman(Posted 2016) [#1]
Hello everyone!
I want to create a quick little program that I can input, edit, and delete entries within some sort of text-based database. What knowledge I had of BlitzPlus programming is all forgotten and I could really use the help.

I hope to store the following information:
(Example)
Joe Dill - PO Box 123 - Letters Set: 5 - Letters Received: 4

Did this make sense? I hope so. The main purpose of this program is so I can keep track of all of this crazy letter-sending stuff that's about to go down between myself and all of my friends. I could do it in Excel or Notepad or Access or Word, but I really need the coding practice!

Any help will be appreciated!


RustyKristi(Posted 2016) [#2]
Not sure about text based database. You can easily do it with INI files (search code arch) or go straight with database userlib like ETNA

http://repeatuntil.online.fr/Etna/


Kryzon(Posted 2016) [#3]
So each entry has some properties.
You need to design an application window that has the UI needed for the user to input, edit and delete entries and the properties of these entries.
Name, address and other textual information can use textfields.
Letters sent and received and other numerical information can use spinners, but BlitzPlus doesn't have these, so you'll have to use textfields as well. No problem.

You should also put buttons to create a new entry and to save\commit the entry you're modifying, and perhaps a listbox that is populated with all the entries in the database so you can quickly pick one to modify\delete.

Plus add label gadgets with the names of the properties etc., so you don't have just a bunch of nameless textfields to fill in.

For the database operations you're going to use the file input\output functions, but as for the database format itself there's no reason not to go with CSV:
https://en.wikipedia.org/wiki/Comma-separated_values

Since it's been a while since you used BlitzPlus, a good way to get familiar with it is to use GUIde, a visual UI layout tool that outputs BlitzPlus or BlitzMax (MaxGUI) code with the gadgets placed like you arranged them:
https://github.com/wiebow/guide

It only exists in source form now and that source is for using with BlitzPlus, so you have to download that whole repository and build it with BlitzPlus. I haven't seen the source files, I think you have to build GUIde.bb and the rest is included by that. Good luck.