|
hi
thank u very much i have implimented ur approach,but i also want to color the scrollbar.I use function
FlatSB_setScrollProp(handle,BACKGROUNDMACRO,color,BOOL)
but color is not appear,Am i missing something,please reply
malik
|
|
|
|
|
rajneshmalik wrote: BACKGROUNDMACRO
Where is that flag?
U can chnage only the channel color of the scroll using FlatSB_SetScrollProp().
|
|
|
|
|
Hi,
I am new to Windows programming.
I am trying to uniquely select and double click an item in the list view (SysListView32) in third party software. This task is somewhat similar to MyProgram trying to double click an item in a ControlPanel-like list view.
To accomplish this I am sending a LVM_FINDITEM message to get the item index of the item to be double clicked.
LVFINDINFO lvfi;<br />
ZeroMemory(&lvfi, sizeof(LVFINDINFO));<br />
lvfi.flags = LVFI_STRING;<br />
lvfi.psz = (LPCTSTR)"Item Name";<br />
<br />
int itemIndex = ::SendMessage( aControlHWnd, LVM_FINDITEM, (WPARAM)(int)(iStart), (LPARAM)(const LVFINDINFO *)(&lvfi));
This send message is causing a runtime error. After going through some forums and message boards I found that this is due to one of the message parameter which is a pointer to a structure, as you cannot pass a pointer-to-memory to another process.
Now I would like to know how to custom marshal this message to the other process?
OR
Any alternative solution to uniquely select and double click an item in the list view.
Any idea or solution to this problem is greatly appreciated. Thanks in advance.
|
|
|
|
|
scody wrote: uniquely select and double click an item in the list view.
So you need to get the list view item when the user double clicks, right?
|
|
|
|
|
No, I need to double click a list view item. Sorry, if it is confusing.. For example, if I want to double click an item named "Item Name", I should be able to click it irrespective of wherever it is positioned in the list, so I called it uniquely(that’s an exaggeration!) select.
|
|
|
|
|
scody wrote: I need to double click a list view item.
Have you added the double clicked event on the listview?
After a list view item being double clicked, what will the program do next?
|
|
|
|
|
I dont have access to the code of the third party software where I am double clicking the item. I just want to invoke the item to perform some task, as if some user is double clicking the item. To cut short I am trying to test the GUI of the third party software.
|
|
|
|
|
I think one possible reason that this doesn't work is that your LVFINDINFO is declared within your application's memory, so other applications won't see this.
|
|
|
|
|
|
And this is possible without any elevated user rights?
Sorry I must leave, the "Security Breach"-Alarm jut got off.
Let's think the unthinkable, let's do the undoable, let's prepare to grapple with the ineffable itself, and see if we may not eff it after all. Douglas Adams, "Dirk Gently's Holistic Detective Agency"
|
|
|
|
|
Hello! everyone!
I had a problem want to be resolved in time!
I make an application in full screen. And I use some class derived from CStatic use to draw some characters and pictures. Now when I change some other window's z-order before this window and then change this window to top, only some part of the class derived from CStatic will be displayed, not all. I want to know how to display all window in this situation?
Thx!
John
|
|
|
|
|
So your problem is how to draw on your window even if other dialogs or windows are on top of it?
|
|
|
|
|
Yes. That's my meaning.
Thx!
|
|
|
|
|
How do you draw to your window? Do you use CDC?
|
|
|
|
|
yes. I use CDC to draw some bitmap file in window. The problem is: I take some other window on this window and then take them below. The area occured by other window is be drawn. The other area isn't be drawn and still be blank. That's all. I hope u and some others can tell me how to resolve it.
Thx!
|
|
|
|
|
I experienced the same thing before. What I did was I made the CDC handler for the window into a global variable. Try that first if it works.
|
|
|
|
|
|
If you are coding in MFC, you can use the pDoc->UpdateAllViews (NULL) as well. If the code in your main view is in the OnDraw () this command will update it, doesn't matters where in the Z-Order is.
Greetings.
--------
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
“The First Rule of Program Optimization: Don't do it. The Second Rule of Program Optimization (for experts only!): Don't do it yet.” - Michael A. Jackson
|
|
|
|
|
Hello, again.
I'm working on a program and i need to execute a command line entry from my program in MFC. My problem is how can I call commad promt and how will I execute an entry from my program. I'm using VC++ 2003.
Please comment on how to do this or found a link for this matter.
Thank you
|
|
|
|
|
try CreateProcess with cmd.exe as the application
|
|
|
|
|
|
|
That has nothing to do with templates - polymorphism works only with pointers or references, not concrete objects. Try this instead:
#include <iostream>
#include <deque>
using namespace std;
class A
{
public:
virtual void test() {cout << "A\n";}
};
class B : public A
{
public:
void test();
};
void B::test()
{ cout << "B\n";}
int main(int argc, char **argv)
{
A* x = new B();
deque<A*>* d = new deque<A*>();
d->push_back(x);
for(deque<A*>::iterator itD = d->begin(); itD != d->end(); itD++)
{
(*itD)->test();
}
delete x, d;
return 0;
}
BTW, why are you creating the deque on the heap?
Programming Blog
utf8-cpp
|
|
|
|
|
Oh, and I don't think the line
delete x, d;
is doing what you think it is doing
|
|
|
|
|
That is one tricky expression!
--
Kein Mitleid Für Die Mehrheit
|
|
|
|