|
IDC_LIST2, which is a List control.
|
|
|
|
|
So the variable is a CListCtrl type?
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
It's a CListCntrl. Yes.
I am actually trying to access it from a function with in the app.
|
|
|
|
|
FISH786 wrote: I am actually trying to access it from a function with in the app.
Is that function a method of the class that owns the list control?
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
|
So why would you be expecting it to work then? Technically you can make it work, but not without having to jump through several hoops first.
You would be much better served by using a property sheet (which simply replaces the dialog) with two or more property pages instead.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
Thank you. realised that when I answered no. thank again.
|
|
|
|
|
hi,
this is a part of a mail function that uses CDO.
function works well with normal fields & settings and sends mail very good
but i cound not set the header part of a e-mail.
so , Importance is one of headers that i want to set .
but it does not work
could you help me to set importance header with this code block.
the bold part of code what i did so far but no succeed.
thanks in advance
note: i did not add whole function because it is too long
--------------------------------------------------------
CoInitialize(NULL);
HRESULT hr = NULL;
IMessage *pMsg;
IConfiguration *pConfig;
Fields *pFields;
Field *pField;
hr = CoCreateInstance(__uuidof(Message),
NULL,CLSCTX_INPROC_SERVER,__uuidof(IMessage),reinterpret_cast<void**>(&pMsg));
hr = CoCreateInstance(__uuidof(Configuration),
NULL,CLSCTX_INPROC_SERVER,__uuidof(IConfiguration),reinterpret_cast<void**>(&pConfig));
pConfig->get_Fields(&pFields);
COleVariant sFname((LPCTSTR)"urn:schemas:mailheader:Importance");
pFields->get_Item(sFname.Detach(),&pField);
COleVariant sImportance((LPCTSTR)"high");
pField->put_Value(sImportance.Detach());
pFields->Update();
pMsg->put_Configuration(pConfig);
hr = pMsg->Send();
if (FAILED(hr))
{
_com_error err(hr);
szReturnVal = err.ErrorMessage();
}
if (pFields)
{
pFields->Release();
}
if (pField)
{
pField->Release();
}
if (pMsg)
{
pMsg->Release();
}
if (pConfig)
{
pConfig->Release();
}
CoUninitialize();
|
|
|
|
|
Hello,
I want to retrieve the data field from the segment in HL7 message. For e.g. If i want a data field Patient name from the segment Patient Identification(PID), then how can i retrieve this. I know the coding method through Regular Expression, but is there any free toolkit or library available in VC++ or in C++. I gone through Google for library, but not getting in C++(i found it in Java).
e.g
MSH|^~\&|ADT1|MCM|LABADT|MCM|198808181126|SECURITY|ADT^A01|MSG00001|P|2.4
EVN|A01|198808181123
PID|||PATID1234^5^M11||JONES^WILLIAM^A^III||19610615|M||2106-3|1200 N
I want "JONES" from PID
Thanks
|
|
|
|
|
If you are using MFC, how about AfxExtractSubString() , like:
CString strPID("PID|||PATID1234^5^M11||JONES^WILLIAM^A^III||19610615|M||2106-3|1200 N");
CString strName;
AfxExtractSubString(strName, strPID, 5, '|');
CString strLast;
AfxExtractSubString(strLast, strName, 0, '^');
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
We've been there before[^] - he'd rather find a library to do all his work for him than consider doing it himself, even though there's not really anything out there...
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
Stuart Dootson wrote: ...even though there's not really anything out there...
His (HL7) data looks similar to EDI data that I used to deal with back when I worked for a health-related company (some 10+ years ago). Tools were available back then for most of the EDI formats (e.g., insurance, financial, remittance), so I can only imagine more exist today, although they may not be free.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
sorry sir, but i search on google but i am not getting library for VC++, i got it in java. That's why post it again.
but the following method is essay one....
CString strPID("PID|||PATID1234^5^M11||JONES^WILLIAM^A^III||19610615|M||2106-3|1200 N");
CString strName;
AfxExtractSubString(strName, strPID, 5, '|');
thanks for your reply.
|
|
|
|
|
thank u sir.
i think it is the easiest way. Because i not getting any free library and your method works fine.
thanks again..
|
|
|
|
|
Hi,
I want to create one utility to find new email message(Notification) in outlook express 6(Like oema software). But i can't find the solution for "how to access Outlook Express MailBox". Is there any API or classes available to do this using VC 6.0.
Thanks,
Ganesh Kumar R
|
|
|
|
|
You may find this article[^] useful.
Do not trust a computer...
Always check what computer is doing
regards,
Divyang Mithaiwala
Software Engineer
|
|
|
|
|
But that document explaining how to access Microsoft Office and I
did not understand how to access the OE.
Please Explain me
|
|
|
|
|
Are you sure that Outlook Express supports Automation?
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
No. Not sure.
Do not trust a computer...
Always check what computer is doing
regards,
Divyang Mithaiwala
Software Engineer
|
|
|
|
|
ganesh.dp wrote: Is there any API or classes available to do this using VC 6.0.
Have you tried MAPI?
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
Does this CP article[^] help?
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
|
|
|
|
|
I have two independent C++ classes, A and B. I have a non-static public function in class A
void display(char *msg);
I want to have its function pointer as a public member of class B, without information that it belongs to class A, e.g in class B, I have:
void (*display)(char*);
I have a member of class B in class A, and I am trying to set function pointer as:
B b;
b.display = &A::display;
I get the following compiler error:
error: '=' : cannot convert from 'void (__thiscall A::* )(char *)' to 'void (__cdecl *)(char *)'
I am using Visual Studio 2005. Can any one let me know a proper way of doing this?
ARSALAN MALIK
|
|
|
|
|
Firstly, your approach using void (*display)(char*); doesn't work as it points to a global or static class member function, not a member function.
One way to to do it is the following, assuming the function to be called is always display :
- Define an interface that contains the function:
class ICallable
{
public:
virtual void display(char *msg) = 0;
};
Note the function is a pure virtual function. - Derive the classes that have the function to be called from it:
class A : public ICallable
{
public:
virtual void display(char *msg)
{
}
}; - Your pointer now looks like the following:
ICallable *pPointer; - The call through the pointer like this:
pPointer->display("Hello world!");
Steve
|
|
|
|
|
Thanks a lot for the hint, perhaps I was thinking too much in C
ARSALAN MALIK
|
|
|
|
|
What is your requirement?
Is it ok if you have static "display" function in class A?
Parag Patel
Sr. Software Eng, Varaha Systems
|
|
|
|