|
When you choose the configuration to compile, you can choose minimum dependancy or minimum size. What they mean is a no brainer - one compiles to include all the code it needs, the other leaves out whatever it can to keep the size down. I believe this function is one you loose in min size, because there are other ways to register, but the details escapec me.
Mimi, if you logged in I would have got an email telling me you responded to my comment and I would have been able to reply sooner. Not that the other comment is no good, chances are he knows more about it than me, but I'm trying to point out the benefits of logging in. After two weeks of the same questions we all know it's you, so if you were hoping to be anonymous, you'll have to ask about something else ;0)
Christian
As I learn the innermost secrets of the around me, they reward me in many ways to keep quiet.
Men with pierced ears are better prepared for marriage. They've experienced pain and bought Jewellery.
|
|
|
|
|
He's having promblems spelling "anonymous" too.
To hell with those thin-skinned pillow-biters. - Me, 10/03/2001
|
|
|
|
|
I wanna know the width and height of a window in pixels!?
How to?
/
|------
\
|
|
|
|
|
Client area -> GetClientRect()
whole window (borders, caption) -> GetWindowRect()
---
Blessed are those who can laugh at themselves, for they shall never cease to be amused
|
|
|
|
|
CRect rc;
cwnd.GetClientRect ( &rc ); rc.right is the width, and rc.bottom is the height.
--Mike--
http://home.inreach.com/mdunn/
"....." -- Silent Bob
your with and
|
|
|
|
|
Normally GetClienRect() would work fine, if it doesn´t give you the size in pixels you have to change the viewport
HTH
Braulio
|
|
|
|
|
CRect rect;
GetWindowRect(&rect);
int nWidth=rect.Width();
int nHeight=rect.Height();
Jerzy
|
|
|
|
|
Hi,
I have made a database application using VC++ this database application connects to the Microsoft Access file via ODBC. I want to create an installshield setup to install this software on client system. I don't know how install shields can create a new User DataSource (in ODBC in ControlPanel) so that installed application can run properly.
Any help or hint or what so ever is welcome
Thanks for ur time .....
~Statbat( );
|
|
|
|
|
I have dont some setup application using Installshield.It is very very easy and selfexplanatory.do u have Installshield installed in ur system.u can mail me for additional help.my email id is ujustmailme@email.com.
bye
|
|
|
|
|
There are two ways you can do this. Installshield has an ODBC wizard, or you can create the registry entries from a script. What version of Installshield are you using?
|
|
|
|
|
Hi,
I am using InstallShield Profession 6.1
Does this have the wizard or I have to use anyother Installshields?
Thanks for ur time .....
~Statbat( );
|
|
|
|
|
Hmmm, this doesn't answer your question, but why not connect to Access without creating a DSN? Do a search for DSN-less connections on MSDN.
Regards,
Alvaro
|
|
|
|
|
hai
i am getting Exception error & Sharing viloation error while running my application . it's aborting.
what may be the cause.;)
Ashu
|
|
|
|
|
Hello. I am having problems trying to print my vector. When it goes through the add it works, but when i want to use my printfunction it doesnt work. I have created a person struct and when the prompt comes around it is to be entered such as
>"add name @address #number
>"add name @address
>"add name #number
and then it is to print out the vectors at
>print
and it doesnt work for some reason
I have attached my code.
Thanks
karen
kginsberg@hotmail.com
#include <iostream>
#include <string>
#include <vector>
using namespace std;
struct person
{
string name;
string address;
string number;
};
void addfunc(string s, vector<person>& address1, int add)
{
person temp;
int addrindex, phoneindex;
addrindex = s.find('@');
phoneindex = s.find('#');
if(addrindex!=-1 || phoneindex!=-1)
{
if(addrindex<phoneindex)
{
="" temp.name="s.substr(add+3," addrindex-(add+3));
="" temp.address="s.substr(addrindex+1," phoneindex-(addrindex+1));
="" temp.number="s.substr(phoneindex+1," s.length()-(phoneindex+1));
=""
="" }
="" if="" (addrindex="">phoneindex)
{
temp.name=s.substr(add+3, phoneindex-(add+3));
temp.address=s.substr(addrindex+1, s.length()-(addrindex+1));
temp.number=s.substr(phoneindex+1, addrindex-(phoneindex+1));
}
}
if(addrindex==-1)
{
temp.name=s.substr(add+3, phoneindex-(add+3));
temp.address=" ";
temp.number=s.substr(phoneindex+1, s.length()-(phoneindex+1)); //phone index is the pound sign
}
if(phoneindex==-1)
{
temp.name=s.substr(add+3,addrindex-(add+3));
temp.number=" ";
temp.address=s.substr(addrindex+1, s.length()-(addrindex+1));
}
address1.push_back(temp);
//&address1.push_back(temp);
cout<<address1.size();
}
void print1(const="" vector<person="">& address1)
{
for (int i = 0; i < address1.size(); i++)
{
cout << address1[i].name <<address1[i].address<<address1[i].number<<endl;
}
}
="" *
void="" delfunc(int="" input,="" vector<person=""> &addressbook)
{
for (int i = input; i < addressbook.size() - 1; i++)
{
addressbook[i].name = addressbook[i+1].name;
addressbook[i].address = addressbook[i+1].address;
addressbook[i].number = addressbook[i+1].number;
}
addressbook.pop_back();
}
void findf(string input, vector<person> book)
{
int check;
for (int i = 0; i < book.size(); i++)
{
check = book[i].name.find(input);
if (check != string::npos)
//print current person
check = book[i].address.find(input);
if (check != string::npos)
//print current person
check = book[i].number.find(input);
if (check != string::npos)
//print current person
}
}
*/
void main()
{
char a[80];
vector<person> addressbook;
int add=0, print=0;
while (add!=-1)
{
cout<<" >";
cin.getline(a,80);
string s=a;
add=s.find("add");
addfunc(s, addressbook, add);
}
while (print!=-1)
{
cout<<" >";
cin.getline(a,80);
string s=a;
print=s.find("print");
print1(addressbook);
}
/* switch (action)
{
case "add":
addfunc();
break;
case "find":
findf(input, addressbook);
break;
case "del":
del();
break;
case "print":
print();
break;
case "exit":
cout <<"you are now exiting the program\n";
break;
default: cout << "\n> ";
}
*/
}
|
|
|
|
|
Hi
Does anyone know where I can find a nice tutorial about writing a DLL under VC++
Thanks
|
|
|
|
|
www.mindcracker.com
|
|
|
|
|
Thanks
|
|
|
|
|
Can any one tell me how can i create a toolbear with circular buttions?
Br
/
|
|
|
|
|
Your best bet is to check out a library such as BCG (http://www.bcgsoft.com) - it isn't free, but it allows you to create toolbar "skins" and includes an example of a toolbar with round buttons.
Regards.
|
|
|
|
|
I'm wondering if anyone has been successful in getting visual styles to work with a MDI application.
The problem is that toolbars are opaque and not permitting the gradient background to show through. If i set a dialogbar's background to transparent, it will flicker when resizing, and sometimes look like its supposed to. but otherwise, it will also disapear and other bad things.
the normal toolbars likewise do not work at all because of the same problem.
it seems the toolbars have a set background that is being used on the background when WM_PAINT comes down.
\\ Rock
|
|
|
|
|
Hello!
Why doesn't this work? First time it works, second time it returns blanks.
std::stringstream s1(std::stringstream::in | std::stringstream::out);
s1<<"hello";
string x1;
s1>>x1; //x1 contains hello. good
s1<<"more";
string x2;
s1>>x2; //nope. x2 contains blank
Thanks
-Rob
|
|
|
|
|
The code fails because the first 'read' operation on the stringstream results in 'eof'. The following line :
string x1;
s1>>x1;
causes the stream to the 'drained', so 'eof' is set. The next 'write' to the stream does not reset the 'eof' bit, so when you try the next 'read' :
string x2;
s1>>x2;
It fails because the inputbuffer of the stream has it's 'eof' bit set. I am not sure it is possible to work around this - as far as I know, it is not the intention of 'stringstream' to allow constant intermingling of 'reads' and 'writes' to the underlying string. I would think that once the stream has been 'drained', you need to either recreate or reinitialise the stream.
-----------------------
The sermon on the mount...
Man 1 : Hear that? Blessed are the greek.
Man 2 : The greek?
Man 1 : Well apparently, he's going to inherit the earth.
Man 2 : Did anyone catch his name?
|
|
|
|
|
Ah yes, thanks Mike , I added an s1.clear() and it works.
|
|
|
|
|
Must be getting sleepy - should have thought of 'clear()'!!!
-----------------------
The sermon on the mount...
Man 1 : Hear that? Blessed are the greek.
Man 2 : The greek?
Man 1 : Well apparently, he's going to inherit the earth.
Man 2 : Did anyone catch his name?
|
|
|
|
|
I want to create a program without any windows... Just an icon in the systemtray with a menu (when someone rightclicks the icon). Just like the well-known (I think) nail.exe. I can't find any help in MSDN. Can anyone help me?
Sprudling
|
|
|
|