i got it...
I forgot to put () after c_str
thanks a lot :-)
Type: Posts; User: ketu1
i got it...
I forgot to put () after c_str
thanks a lot :-)
Hi
This is my codde
iResultCompare=ldap_compare_s(ld,strDN.c_str,vAttTypeFromFile_m[iCntAtt].c_str(),vAllAttValFromFile_m[iCntAtt][iCntVal].c_str());
and error is
error C2664:...
Hi All
I want to convert string into PCHAR.
How can I do that?
Please help..
Thanks
Ketu
Thanks a lot Todd burch.
Is this means that there is no such method in STL library?
I mean predefined method in STL...
Hello evervbody
How to get value at particular index from a vector?
Thanks in advance
Ketu
Thanks a lot matsp.
It is solved now.
Final program is as below:
#include<vector>
#include<iostream>
using namespace std;
int main()
Thanks A Lot.
Is there any such function available?
Thanks a lot CornedBee
Yes.
But In my program I have two vectors.
One for storing keys and other for storing values.
So I need index as well.
#include<vector>
#include<iostream>
using namespace std;
typedef vector<string> vString;
vector<vString> vBig;
vString vSmall;
vString vType;
vString::iterator itr;
bool bPresent =false;
string type="phone";
string val="857867";
Thanks a lot nvoigt. :-)
What I am implementing here is reading the data from LDIF file and add entries into iPlanet directory server accordingly.
Yes... i want to implement that only.
But not getting which way should I follow.
First I tried implementation using multimap.
In that case storing data was OK.
But i was not able to retrive the...
Also how to get index number?
i.e. I want to know at what location string "phone" is stored in vector<string> v1.
How I will get that?
Please help.
Is there any simple method to search whether a particular stringis present in a vector<string> v1?
Can we have vector of vector?
e.g.
vector <vector<string>>vBig;
Yes .. But I'll not be knowing how many keys are there in a file.
Like I am reading keys fro file.
The file data may be like below:
telephoneNumber: 435
telephoneNumber: 5345
telephoneNumber:...
If I'll use std::map<std::string, std::vector<std::string> >
How I'll come to know how many vectors are required?
Please help.
thanks in advance.
But every time it is returning single value and not all the values for that key.
Out of this Following is the code where I am tring to read values from multimap:
mapAttributes.insert(pair<const char *,const char *>(pchAttType,pchAttValue));
}
} ...
Hi
I tried it using multimap.
But I am not able to find all the values of a particular key using multimap.
Thanks a lot.
But I'll not be knowing how many vectors will be required at run time.
Because i'll be reading this data from text file. For example -
# entry-id: 5
dn:...
Hi ,
I want to store data which is in key value pair.
Here one key can have many values.
example:
email : [email protected]
[email protected]
phone : 9877766655
...