|
Does anyone know of any macros or other technics which would make it easier to debug BSTR and SAFEARRAY. Both are combersome structures to deal with and "dumping" their contents either dynamically via a debug macro of somekind or statically so that you could view them in debugger watch window.
|
|
|
|
|
The question states.
Write the following code and discuss what exactly results.
enum logical { no, maybe, yes };
I get the enum part, no = 0, maybe = 1 and yes = 2. But what is the 'logical' part? A logical |, or perhaps a logical &
Thanks for a push in the right direction.
|
|
|
|
|
McGahanFL wrote:
But what is the 'logical' part?
It's the name of the set (i.e., type).
As an added bonus, how would your answer change, if at all, if I were to change the statement to:
enum logical { no, maybe = 3, yes };
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Are you saying I can replace the word 'logical' with types like int or CString? I don't think that is what you mean.
bonus question no = 0, maybe =3, yes = 4
-------------------------
logical operator &&(logical a, logical b);
thansk
|
|
|
|
|
McGahanFL wrote:
Are you saying I can replace the word 'logical' with types like int or CString?
No, not at all. The word following the enum keyword is the name of your new type, like animal, position, or vehicle.
McGahanFL wrote:
bonus question no = 0, maybe =3, yes = 4
Very good. You have a firm grasp on the subject.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
OK, thanks. Let me work with that for a while.
|
|
|
|
|
my situation :
In my application i have to start another exe. In that other application the user has to make a choice and has to press the button ok or cancel. Now what i want is to receive the choice of the user in my calling app.
Application 1 --> starts up Application 2
In App2 the user choses ok or cancel
Is there a way to return the value from the choice to my App1 ??
|
|
|
|
|
Timothy1982 wrote:
Is there a way to return the value from the choice to my App1 ??
Have a look at GetExitCodeProcess() .
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
thx for the help ;)
|
|
|
|
|
if it's a dialog app, shouldn't it be:
if(dlg.DoModal == IDOK)<br />
else<br />
[insert witty comment here]
bdiamond
|
|
|
|
|
When I make a main window fullscreened, the taskbar sometimes won't hide itself under my window. It does that arbitrarily it seems.
I'm doing this right now:
ModifyStyle(WS_OVERLAPPEDWINDOW, 0);
ShowWindow(SW_MAXIMIZE); Is there a better way to make a window fullscreened?
--
Arigato gozaimashita!
|
|
|
|
|
I have seen similar problems with XP. Try Start->Run->Accessabilty Wizard. Just hit next on all questions. Restart you program. Is the problem still there?
|
|
|
|
|
Hello,
I need to show 2 dialog window and I need to show them side by side how can I do that?
|
|
|
|
|
You've not privided enough information to generate a specific answer. For example, who owns each of the two dialog boxes? Will both need to be active at the same time (i.e., how does the modality of one affect the modality of other)?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
is there anyone there that knows of a control that
is a CCheckListBox with the functionality of a
CDragListBox?
|
|
|
|
|
Hi,
I just want to execute an .exe program already read by myself in memory, say:
:
uchar *buf = (uchar*)malloc(file-byte-size);
FILE *fp = fopen("test.exe", "rb");
fread(buf, 1, file-byte-size, fp);
// do some specific codes here
run-exe-image(buf); // This is what I want
:
Seemingly, I could't find any API function so far to do this.
All execution functions require .exe file name. (e.g. CreateProcess, ShellExecute, spawn..., exec..., what else?)
I have a need to modify some data in the binary image on the fly without using external parameter file nor modified version of the .exe in temporary folder because of security reasons.
Could someone point me out or lead to links?
Thanks in advance.
mich
|
|
|
|
|
mich2 wrote:
Seemingly, I could't find any API function so far to do this.
Probably because one does not exist. This question has been asked many times over the years, and to date, I've never heard of a solution. Good luck.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
then you didn't read carefully. I'm sure I've already given an answer to this question. It is possible!
You need to build a custom PE loader. There is one at http://mitglied.lycos.de/yoda2k/[^].
Have a look at section "Code Snippets", the code is called "InConEx 1.0".
Don't try it, just do it!
|
|
|
|
|
If it works and solve the OP's problem, then great.
Alexander M. wrote:
then you didn't read carefully. I'm sure I've already given an answer to this question.
Where might I find said answer?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Alexander M. wrote:
then you didn't read carefully. I'm sure I've already given an answer to this question. It is possible!
Oh, Yah?
I tried many keyword searches, all day long today!!
Many thanks to you, and also David.
OK, I gonna dig into that!
|
|
|
|
|
i have an app I wrote that stores files in bytes in a SQL Server database. When the user chooses to open one, my program creates a folder in the current directory of my app called 'temp' then I write the bytes to a file and do a shellexecute. It's seamless and very fast. When my app closes, I have a CleanTempFiles() function that goes through that directory and deletes all the files. This may not be what you wanteed, but that's the best a novice like myself can do.;)
[insert witty comment here]
bdiamond
|
|
|
|
|
Thanks for your reply.
I often do the same kind of things, but this time I can't make use of a temporary file creation as I noted.
Anyway, thanks.
|
|
|
|
|
I posted a similar query a month ago on this forum, and got the same response. So far, I am unable to solve the problem. I am looking for PE headers stuff. If you (or anyone) are able to run the exe image from memory, then please guide me in right direction.
ARSALAN MALIK
|
|
|
|
|
Hi, all
Let me post the same topic again.
Last day (for me), Alex indicated me the exact way to execute an .exe in memory buffer. (Also thanx to the author, yoda.)
After a few digging, I found I can't take the way unfortunately because it's only applied for an .exe that has "Relocation Information" included, while my ones do not.
Does anyone have alternatives?
Thanks again, in advance.
mich
|
|
|
|
|
Does any1 have any expiriance with shareware programming. I'm especially interested in some sort of SERIAL NUMBER PROTECTION. Any tutorials or source examples to be seen?
Tnx for an answer.
Love is the law, love under will.
|
|
|
|