Solved

MS Visual C++ 2010 - Beginner

Posted on 2013-01-25
8
290 Views
Last Modified: 2013-01-27
Hello,
I am an iSeries RPG programmer. I have done some C++ courses over the years but never used it. I am now looking to start a small project in C++ and use it as a learning exercise. I have downloaded MS Visual C++ 2010.

My project is quite simple. I involves a customer master file and a customer transaction file. The 1st part of the project will be to maintain both of these files. So I will need to be able to Add/update/delete & inquire on all of the fields on both files. The transaction file will also validate the customer against the customer master file.

Where do I start ? Is there any sample coding out there which I can refer to and base my coding on this ? Is there any documentation which will give me an insight in writing a file maintenance program. Any advise will be most welcome

thanks in advance

regards
Pat Clarke
0
Comment
Question by:pclarke7
  • 4
  • 4
8 Comments
 
LVL 22

Expert Comment

by:ambience
ID: 38821036
Since you are going to be working with files I would recommend some iostream tutorials to refresh your C++ acquaintance

http://www.learncpp.com/cpp-tutorial/136-basic-file-io/

This one should be more related to the stuff you'd have to do

http://courses.cs.vt.edu/~cs2604/fall00/binio.html
0
 
LVL 22

Expert Comment

by:ambience
ID: 38821059
BTW, writing a file based database with all CRUD operation support is fairly involved. As a learning exercise perhaps you should also checkout the sources of SQLite that even though is a C implementation of an embedded DB engine, but would have helpful insights.

This one seems more C++ based

http://sourceforge.net/projects/embedb/
0
 

Author Comment

by:pclarke7
ID: 38822101
Thanks for you comments ambience, and I will read the iostream tutorials. However much of the online documentation explains how to write to files on the fly (ie data imbedded with the program "outf << This is lie 1 <<endl;") What I am looking to build is a database maintenance screen(s) where the user inputs the data and some of the values are validated against other files,  similiar to the example below:

Customer Master maintenance (Add customer)

Cust#:                             ______
Cust name:                     ________________________________
Address:                         ____________________________________________________________________
Cust type:                       _
Date added                    ________
Date Changed               ________



Customer master maintenance (Inquire)

Cust#  _____  or Alpha Search ____________________________

Cust#    Name                                                                       Type
--------    ----------------------------------------------------------------     -
1234      Joe Blogs                                                                    A
1235      Jack Frost                                                                   A
1236      xxxxxxxxxx                                                                B


The above shows how records are added and displayed. To display the full details the user would click on one of the records displayed in the list and have the option of Updating or deleting. The data entry would validate that customer does not already exist and that the customer type is valid (exists on a customer type table)

It is this type of setup that I am trying to achieve and aslo find some sample coding for similiar projects.

regards
Pat
0
 
LVL 22

Expert Comment

by:ambience
ID: 38822661
C++ out of the box does not support any GUI or webapplications, but there are toolkits that fill the void. For example, the QT toolkit is C++ based. See this tutorial http://sector.ynet.sk/qt4-tutorial/my-first-qt-gui-application.html

What platform would you be developing for? developing on?
0
Being driven mad by email signature updates?

Having to make a change to your users’ email signatures, yet again? Feel like your head is going to explode? Rely on an Exclaimer email signature management solution to make the process simple!

 

Author Comment

by:pclarke7
ID: 38822723
I am developing on windows 2007

Should I be looking at using  an existing desktop database such as MS access or a relational database , rather than creating my own ? If so what would you recommend ?

regards
Pat
0
 
LVL 22

Accepted Solution

by:
ambience earned 500 total points
ID: 38822791
SQLite goes very well with QT and pretty easy to use as an embedded database. MySQL isnt bad either and has C++ SDK.
0
 

Author Comment

by:pclarke7
ID: 38824622
Hi Ambience,
I have had a look at MySql and I think that this would be perfect. I hadn't considered that I could use something like this to develop the database and then process the data through a C++ application. Thanks you for you input which has be a great help. I will now concentrate on the C++ application for learning rather than the database creation.

regards
Pat
0
 

Author Closing Comment

by:pclarke7
ID: 38824627
Selecting a relational database such as MySQL rather than trying to re-invent the wheel will allow me to concentract on the application. I would not have twigged this without input from Ambience
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Running VB/Batch script through Group policy 30 79
Comctl32.ocx problem - Office 2016 Pro Win 10 7 27
Project Operations Manual 2 49
Doubt. 2 57
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
In this article, I will show you HOW TO: Install VMware Tools for Windows on a VMware Windows virtual machine on a VMware vSphere Hypervisor 6.5 (ESXi 6.5) Host Server, using the VMware Host Client. The virtual machine has Windows Server 2016 instal…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now