|
No I am afraid it doesn't work without the
CREATE_NEW_CONSOLE MACRO either. I have tried pretty much everything. Even different
API's like ShellExecute e.t.c.
I agree with you it must be something to
do with TerminateProcess, but there is no
other way, is there? I mean ExitProcess
just terminates the process/thread where
it is called from. Is it possible to terminate a child process via means other than the TerminateProcess?
|
|
|
|
|
If you have to Terminate a Process Cause it is Hanged up , then there is no other way but to Terminate the Process except for calling TerminateProcess
but i can't see that happening 200 times
i think you need to rethink ur app design
if you want to terminate an application then you can use Events (SetEvent) to signal a termination request.
Live as if your were to die tomorrow. Learn as if you were to live forever.
-Mahatma Gandhi
|
|
|
|
|
Well if the program frezees there is no way it will respond to a terminate signal.
Thanks anyway though!
|
|
|
|
|
hi all,
i m generating a log file for network printer in win 2000 .
when i did not set any user name & password ,the log file was generated successfully.
but when i set the username (administrator) with blank password and then when i m running the application , it was unable to create log file for printer.
is it registry problem.
shall i go to registry ???? to check ?
if so what is the registry path to set the user name & password as my program reads the username from registry.
please help.
skpanda
|
|
|
|
|
|
I get the following error, after i complie from release mode to debug mode, I aslo go for full rebuild, but still i
get the below stuff,
CAN any one explain me what this error is and how to resolve this error!!!
Linking...
LINK : LNK6004: Debug/MMCt.exe not found or not built by the last incremental link; performing full link
LINK : error : Internal error during ReadSymbolTable
ExceptionCode = C0000005
ExceptionFlags = 00000000
ExceptionAddress = 004622E0
NumberParameters = 00000002
ExceptionInformation[ 0] = 00000000
ExceptionInformation[ 1] = 0059F218
CONTEXT:
Eax = FFFFFFFF Esp = 0012E6BC
Ebx = 00000002 Ebp = 0059DE98
Ecx = 032E0164 Esi = 00000271
Edx = 00000BB4 Edi = 403EF0CC
Eip = 004622E0 EFlags = 00010206
SegCs = 0000001B SegDs = 00000023
SegSs = 00000023 SegEs = 00000023
SegFs = 00000038 SegGs = 00000000
Dr0 = 0012E6BC Dr3 = 00000002
Dr1 = 0059DE98 Dr6 = 032E0164
Dr2 = 00000000 Dr7 = 00000000
Error executing link.exe.
Tool execution canceled by user.
/* and i never canceled the execution but still i get "Tool execution canceled by user." WHY?
|
|
|
|
|
What version of VC sre you using ?
try to complie on another machine
Live as if your were to die tomorrow. Learn as if you were to live forever.
-Mahatma Gandhi
|
|
|
|
|
thanks,
I am using VC 6.0/Win2000 and P-3 with 256 RAM, but why do i get this error?
|
|
|
|
|
While Compiling ur Program the compiler Screwed up !
check ur project settings
are you using any external lib files , check them
and try it on another PC
Live as if your were to die tomorrow. Learn as if you were to live forever.
-Mahatma Gandhi
|
|
|
|
|
finally,
I happen to solve it in different fashion,
I delete debug version, copied the release version and checked all the option for debug and it worked, its pathetic.
regards
Balkrishna talele
|
|
|
|
|
Well this may be almost a decade too late but in case anyone else is experiencing this problem, I found the solution by changing code optimisation settings from Max Speed to Default in the C++ tab of VC6.
|
|
|
|
|
thanks for the answer, even though late not an issue, but it is logical answer, once again thanks
regards
Balkrishna Talele
|
|
|
|
|
Hi,
I have already posted this question on 17Dec and thankfully I got the reply from one Mr.Steve S, as well.
Just to recall, I need to start an SQLSERVERAGENT service in a system through program.
As said in that reply I implemented it successfully by using the LSA (Local Storage Authority) subsystem, from LsaOpenPolicy(), AddAccountRights() etc . Thnx....
But now the problem is,it is not effective in WindowsXP os. It fails in that operating system(I am not able to start the SQLSERVERAGENT service in WindowsXP). How to resolve it?The thing that I implemented is only for WindowsNT,2000.
How to make it work in WindowsXP?
thnx....
AK.
********
|
|
|
|
|
Nobody knows how to solve this problem??
|
|
|
|
|
Alright, I've managed to get buttons and all that working just fine, but I can't figure out how to get just a bitmap in the toolbar... In the google toolbar, for example, they have that lovely google logo over a button... I'd like that, but without the button. I've even gone so far as to make a button, and make it TB_INDEFINITE (or whatever it is, I'm not looking at my code), but I don't want it greyed out like that. I want it full color, but not clickable at all. I mean, I can have a button, but I don't want it to "click". Any thoughts, anyone?
|
|
|
|
|
Vermithrax wrote:
Any thoughts, anyone?
Custom draw on a separator sounds like your best bet. Alternately, you could float a static control over a separator.
Zno one puts flowers on a flower's grave
|
|
|
|
|
Hi,
I have following questions:
1. How do I create a directory in MFC?
2. When my application exists I want to delete the directory. How to do that?
3. In the directory I want to keep a feh html files. Users can look at the htmls when the application is running. When the applications exists I want to do the following
a) check any of those html files are open...How?
b) close them ...how?
c) delete them...how?
e) delete the parent directory.
Please advise.
|
|
|
|
|
|
|
hey well This can be done very easy. Just u make use of the system(command)
This system function is used to execute the dos commands. So u have to specify like system("md directoryname"); This will execute the dos command so that ur directory would created to delete do the same. to open the file just use _open to read or write the file just use _read or _write. I hope u better refer the msdn where u could be clear man. Just try this i hope this would be helpfull for u.
Bye .....
Shanmuga Sundar.V
|
|
|
|
|
Hi,
I'm writting an app the writes an undo log to disk. 99 times out of 100 this will be fine, but I want to detect when the disk space is running low.
I imagine that XP sends a message, when/before the 'low disk' prompt is displayed to the user, is this true, and can anyone tell me what message I need to catch?
I'd also like a solution that will work on 98SE and 2000, but I don't want to have to be checking disk space regularly. Can anyone suggest a better way?
tia,
hugh
|
|
|
|
|
You will have to Create a Disk Cleanup Handler
search MSDN for "Creating a Disk Cleanup Handler"
or try this URL
here[^]
Live as if your were to die tomorrow. Learn as if you were to live forever.
-Mahatma Gandhi
|
|
|
|
|
Is there any way to fix toolbar to stay no more than 2 rows when you make window smaller just like microsoft word. Right now when you make window smaller tool bar aligned to left size becomes 4 rows.
Thanks in advance
|
|
|
|
|
Look at an example in MSDN!
Hello World!
|
|
|
|
|
i'm trying to communicate with a relay box connected with a serial cable. you send a command of N1 to open the first relay, N2 to open the second, etc... i've tested it with hyperterminal and it works fine. i'm usin a c++ mfc app in vs.net03. i've just added code to my program, if there are any settings that i have to set, then i don't know about them. i'm using the CSerial class
http://www.codeproject.com/system/serial.asp
portName and relay are both CStrings. anyone know what's wrong??
CSerial link;
link.Open(portName); //either COM1 or COM2
//set the port settings
link.Setup(CSerial::EBaudrate(9600), CSerial::EDataBits(,
CSerial::EParity(NOPARITY), CSerial::EStopBits(ONESTOPBIT));
if(relay[0]=='1')
relay.Delete(0,1);
link.Write(relay); //writing "N1" or whatever
//find time for pump to stay open
runtime=drinklist[num].amount[x]*MULTIPLIER;
Sleep(runtime*1000);
relay.Delete(0,1);
relay.Insert(0,"F");
link.Write(relay);
link.Close();
thanx
|
|
|
|