Hi!
I'm fairly new to programming in C++ (only done Java before). I try to read data from a *.dat file.
As this file is selcted by the user via a GUI(done with QT) there isn't one special file to test with.
I wrote the following method to read the data - there are 3 times 2 bytes at the beginning of each *.dat file which specify the amount of data given for x, y and z direction
- this is why I only try to read these 2 bytes for the beginning
yes I linked against "$(QTDIR)\lib"; where QTDIR is defined in the windows environment variables as path to the QT folder
all other methods needing QT do work fine - so I guess linking QT is ok
It is just that:
1. The QString stuff is in the qtcore library (QT has about 30 libraries)
2. The QString::toWCharArray function did not appear in QT until version 4.2
(And another thing is that you actually have to allocate the WCHAR buffer - which you are not actually doing);
I use QT 4.5.3 - do I have to link each library needed on its own? I do link the whole library folder which holds QtCore4.lib as well. Is this the one meant?
You link libraries as required.
QtCore4.lib is the one I'm particularly thinking about (QtCore4d.lib is the debugging version)
How are you using qt - are you using an IDE - if so which one - we should be able to get this thing sorted in no time at all.
I'm not using an IDE - I downloaded the QT sources, compiled them and installed the addin for msvc
I started using the QT creator but switched to doing the GUI moddeling without creator
Ah, that is what I use. I really like it.
Bring up the project properties dialog and go linker ->input
What (libraries) have you got listed in the Additional Dependencies box??