|
i want output as nodes visited while searching..i have defined function print node info in that..
but its not giving me any output
|
|
|
|
|
Why don't you fire up the debugger and find out for yourself?
(VS6): "Debug build", Set a breakpoint (F9), and press F5
You would have saved 1 hour, 40 minutes...
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|
|
yes i did everything.
but its not working and thats why im asking you people for help..
im fighting with this from last 15 days ..
tried each and every option
|
|
|
|
|
s chiddarwar wrote: yes i did everything.
Including single-stepping your program in the debugger? While inspecting the values of the interesting variables? And watch the flow of the program?
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|
|
i did single stepping debug..
it gives me error C:\WINNT\system32\kernel32.dll', no matching symbolic information found.
and
it gives me output as goal node not found search terminated...
please some one help me
-- modified at 6:03 Thursday 26th April, 2007
|
|
|
|
|
can you send my please the A star algoritm to look at it
|
|
|
|
|
Hey,
I am trying to write a program that will run on about 40 computers at my work to monitor the processes. The way I would like to do it is run a small program in the background that receives notifications events from the kernel every time a process is created or terminated and then reports the information to a server computer. I am able to handle the communication with the server fine, but the receive notification events is causing me a bit of trouble. I have been trying to use http://www.codeproject.com/threads/procmon.asp <-- this example to do just that but it does not always report the process name, sometimes only the process id. If anyone is able to give me an example that works or point me in the write direction would be great.
Thanks in advance
Lepon
|
|
|
|
|
hello all,
i have made a sdi application, on button click event i have done some operations (which include starting of various ui threads).
Now my problem is when i click it some times it give don't send error and when i degug it using breakpoints it gives error
Unhandeled exception in xx.exe 0x0000005:Access violation
on doing ok another window pops up
Please enter the path for DBGHEAP.c
can anybody please tell me what kind of problem it can be and how to remove it
thanks in advance
|
|
|
|
|
neha.agarwal27 wrote: Unhandeled exception in xx.exe 0x0000005:Access violation
It is very difficult to guess the problem, without seeing code.
But, somewhere in your code, memory is handled/used in wrong way. Possibly, written out of boundry. So, check, how you have handled it.
Prasad
MS MVP - VC++
|
|
|
|
|
This is an excellent time to use your debugger. Follow the call stack until it reaches code that you have written. There you will find the cause of the error.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|
|
Can you post some code snippet for other's to see and check? It's very hard to tell with the information that you provide now. As said above it is possible that you may be writing to an invalid memory location causing the application to crash.
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
neha.agarwal27 wrote: Please enter the path for DBGHEAP.c
You are trying to delete a pointer that's not yours or not allocated properly or deallocated before.
|
|
|
|
|
Hello friends,
For one of my projects I need to call jar files from the visual c++ application. Can anyone tell me how this can be done. If sample code is there then it will help a lot or the API if there is any.
Thanks for your reply.
Nikhs
Nikhil Trivedi
|
|
|
|
|
|
I dont wanna call c++ function from java but wanna call jar file from visual c++. BTW, thank you for your reply.
Nikhs
Nikhil Trivedi
|
|
|
|
|
Nikhil Trivedi wrote: For one of my projects I need to call jar files from the visual c++ application
If you just want to unpack the jar file then use ShellExecute .
Prepare a command string like "Cmd.exe YourJarFilePath.jar -Arg1 - Arg2" , then pass it to ShellExecute .
|
|
|
|
|
This might be a bit helpful. Can you send me a sample code say I want to call a jar file at location C:\psae.jar with the parameter "world" then the syntax from command prompt is :
java -jar C:\psae.jar world
How the command string should look like for this one ?
Thanks for your reply
Nikhs
Nikhil Trivedi
|
|
|
|
|
Nikhil Trivedi wrote: java -jar C:\psae.jar world
So in this case the command will be the same...
Look up ShellExecute in MSDN .
The lpFile parameter should be "java.exe" and lpParameters should be "-jar C:\psae.jar world".
|
|
|
|
|
Thanks Dear friend. It really will help a lot.
Nikhs
Nikhil Trivedi
|
|
|
|
|
Nikhil Trivedi wrote: It really will help a lot.
Did it work.
|
|
|
|
|
It didn't work. When I use debuger, it shows me the return value of the shellexecute as 2 and the value for getlasterror is the same. I dont knokw how to deal this ?
I am using the following code snippet :
HINSTANCE hInst;<br />
hInst= ShellExecute(NULL,reinterpret_cast<LPCWSTR>("open"),reinterpret_cast<LPCWSTR>("C:\j2sdk1.4.2_12\bin\java.exe"),reinterpret_cast<LPCWSTR>("-jar C:\psae.jar WORLD"),NULL,SW_SHOWMAXIMIZED);<br />
and even try with this one :
hInst= ShellExecute(NULL,reinterpret_cast<LPCWSTR>("java"),reinterpret_cast<LPCWSTR>("C:\j2sdk1.4.2_12\bin\java.exe"),reinterpret_cast<LPCWSTR>("-jar C:\psae.jar WORLD"),NULL,SW_SHOWMAXIMIZED);<br />
both shows the same error.
Error no. 2.
|
|
|
|
|
Why all of the reinterpret_cast() code? Aren't you forgetting to use double backslashes in your string literals?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
I didn't get the point you raised. Can you explain me that with some example ?
Thanks for your reply.
Nikhs
Nikhil Trivedi
|
|
|
|
|
What's not to understand?
HINSTANCE hInst = ShellExecute(NULL, "open", "C:\\j2sdk1.4.2_12\\bin\\java.exe", "-jar C:\\psae.jar WORLD", NULL, SW_SHOWMAXIMIZED); If you are using Unicode, just precede the string literals with an L .
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Got it. Thanks to remind me about that. Can you help me how can i send a java command to command prompt through visual c++. I want to unpack a jar file which can be done from command prompt by passing a command like :
java -jar C:\myfile.jar para
Appreciate your advice.
Nikhs
Nikhil Trivedi
|
|
|
|