|
i already answered...
you wrote this :
look.Format("Original text: <<font color=red>%s</font>>\n"
"Uppered: <<font color=red>%s</font>>\n"
"CompareNoCase says they differ!\n"
"Lowered again: <<font color=red>%s</font>>\n\n"
"Conclusion: CompareNoCase doesn't work correctly!");
but where are the parameters ?!!!
TOXCCT >>> GEII power
[VisualCalc 3.0 updated ][Flags Beginner's Guide new! ]
|
|
|
|
|
sorry I put up the wrong text...
I don't have any parameters so it's:
look.Format("Original text: \n"
"Uppered: \n"
"CompareNoCase says they differ!\n"
"Lowered again: \n\n"
"Conclusion: CompareNoCase doesn't work correctly!");
Kitty5
-- modified at 9:18 Friday 16th June, 2006
ok yes... i am an idiot... maybe i should get more coffee...
|
|
|
|
|
Look at the answer from toxcct (above).
-- modified at 9:14 Friday 16th June, 2006
Twice, now.
|
|
|
|
|
OK... I am working with an IDispatch -based interface that needs to be completely automation capable (i.e. it uses the Typelib Marshaller - no custom marshalling).
Now, AFAICT:
o I can pass structures over an IDispatch -based interface as the structures consist solely of automation-capable types
o I can pass arrays of automation-capable types over IDispatch -based interfaces using SAFEARRAY (possibly wrapped within a VARIANT )
(For now, ignore the fact that some clients, like VBScript , may be unable to handle these kinds of parameters.)
However, I cannot seem to find information telling me that both are possible at the same time. IOW, I want to pass an array of structures across an IDispatch -based interface. The only information I can find regarding passing arrays of structures indicates that I will have to serialize the data to a byte stream and then send the raw bytes over the wire wrapped in a SAFEARRAY of VT_I1 types.
While I am sure I can make that work, and can provide clients with information on how to decode the structures, this feels kinda 16-bit-ish to me, and not just a little quick-n-dirty.
So, does anyone know if it is possible to pass arrays of structures over IDispatch-based interfaces, or do I have to do the byte-stream route? If so, please point me to the relevant documentation.
Adva[Thanks]nce! (Cheesy, I know... )
Peace!
-=- James If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! DeleteFXPFiles & CheckFavorites (Please rate this post!)
|
|
|
|
|
plz tel me how to change the color of text in a edit control or static control and also tem how to change color of edit control plz tem me some example (code to understabd is easy) plz.....................
Please mail me
-- modified at 8:34 Friday 16th June, 2006
|
|
|
|
|
In OnCtlColor function add this block of code :
Define in the header file as follows in the public section:
COLORREF m_color;
HBRUSH m_brush;
if (pWnd->GetDlgCtrlID () == IDC_EDIT1)
{
pDC->SetBkColor(m_color);
hbr = m_brush;
}
if (pWnd->GetDlgCtrlID () == IDC_EDIT2)
{
pDC->SetBkColor(m_color);
hbr = m_brush;
}
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
-- modified at 8:18 Friday 16th June, 2006
|
|
|
|
|
<br />
HBRUSH CAnswerDlg::OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor)<br />
{<br />
HBRUSH hbr = CDialog::OnCtlColor(pDC, pWnd, nCtlColor);<br />
pDC->SetTextColor(RGB(54,97,200));
return hbr;<br />
}<br />
whitesky
|
|
|
|
|
THIS WILL WORK BUT HOW I CAN CHANGE THE COLOR OF EDIT CONTROL AS U TEL BKCOLOR IT WILL CHANGE ONLY TEXT BACKGROUND BUT SIDE OF TEXT DOES NOT CHANGE
Please mail me
|
|
|
|
|
yes see DavidCrow answer its very good and for how to use WM_CTLCOLOREDIT see Here[^]maybe it is some helpful to you
whitesky
|
|
|
|
|
Just respond to the WM_CTLCOLOREDIT message.
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
yogendra wrote: plz tel me how to change the color of text in a edit control or static control and also tem how to change color of edit control plz tem me some example (code to understabd is easy) plz.....................
Better way to Subclass both the Controls you can do whatever you want and use those classes.
Following link directs you for subclassing
Extended Edit and Static controls[^]
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
Hi!
I'm trying to accomplish the following:
A main app having a derived CStatic class called CPauseAdm.
A regular MFC DLL having a derived CPauseAdm class called CPauseTestAdm.
I want to make a form of plugin system where the CPauseTestAdm can be used instead of CPauseAdm without being forced to recompile the main app.
So far, I have been able to contruct the CPauseTestAdm class in my main app and call a number of its member functions. But when I try to create the window of CPauseTestAdm the Create function always return 0 and I get just a hwnd=NULL. Could somebody tell me what I'm doing wrong ?
BTW. The CPauseTestAdm object is created by the DLL through a wrapper function. I have tried to create it's window in both the main app and through a wrapper function exported by the DLL but none of these methods worked. Create returns 0 either way...
|
|
|
|
|
You may do this by creating the Generalised class(i mean templates class) in you application so that you can create object of the class whatever you want
just pass the class name into template and use that class..
Hope i understood your question.
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
Huum, I don't understand what you mean by templates class ?
The class I'm deriving from is defined in the main app...
The derived class is successfully created by the DLL so that does not seem to be the problem but when I try to create it's window using Create(...), with parent set to the main apps window, the functions returns 0. Could there be some form of resource problem even though the class derived in the DLL is just a CStatic ?
|
|
|
|
|
Check whether the provided parent of the main apps is correct is valid in the DLL.
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
Yes, the provided parent has correct type (CView) and seems valid.
|
|
|
|
|
How to Create Array of Labels on the Run-Time ?
Best Regards...
|
|
|
|
|
Use new or a vector from the STL.
Now if you want a more precise answer, you have to ask a precise question also. What is a label exactly (it can be a lot of different things). And describe your problem in detial.
Cédric Moonen
Software developer
Charting control
|
|
|
|
|
A label is a static control :
Assuming you mean a static control when you say label.....
CStatic *st=new CStatic();
st->Create("hello",SS_SIMPLE,CRect(0,0,100,100),this,-1);
st->ShowWindow (SW_SHOW);
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
-- modified at 8:01 Friday 16th June, 2006
|
|
|
|
|
Where's the array?
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
I want to create Label on run time. (Create dynamically)
And I want this Label must be array like (I use 22 label)
lblArray[0]
lblArray[1]
lblArray[2]
lblArray[3]
lblArray[4]
.....
Thanks..
|
|
|
|
|
This sample create an array of 10 labels:
CArray< CStatic * > mArrayOfLabels;
for( int i = 0; i < 10; ++i)
{
CStatic * label = new CStatic();
label->Create("Label", WS_VISIBLE, CRect(CPoint(0, i * 32), CSize(100, 32)), this, IDC_STATIC);
mArrayOfLabels.Add(label);
}
|
|
|
|
|
Its Not work
I use .NET 2005
Not: .2005 not accept * instead of I use ^
|
|
|
|
|
(The sample was for C++ ordinary MFC projects).
-- modified at 8:40 Friday 16th June, 2006
I think you can post a question in "(Managed) C++/CLI" forum.
|
|
|
|
|