|
Yes , i pass both the parameters username and password but the still same error exists.
I went through the microsoft site , it seems this was a bug in earlier XP versions but that fix was made.
I am using XP version 2002 service pack 2, is this the version in which fix is made or not?
Thanx for reply!!
|
|
|
|
|
Can you create the job manually, and have it run?
"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
|
|
|
|
|
Yes, if i go to that job and specify the password in the properties, the job runs fine , its just that through setAccountInformation I am not able to run that job?
It is picking my default Windows login and not the userID I specify in setAccountInformation.
What could be the reason?
|
|
|
|
|
How are you using the SetAccountInformation() method?
"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
|
|
|
|
|
This is the flow :
hr = pITask->SetApplicationName(pwszApplicationName);
TCHAR pszName[500] = "User";
TCHAR pszPwd[500] = "Password";
hr = pITask->SetAccountInformation((LPCWSTR)pszName, (LPCWSTR)pszPwd);
hr = pITask->CreateTrigger(&piNewTrigger,&pITaskTrigger);
hr = pITaskTrigger->SetTrigger (&pTrigger);
hr = pIPersistFile->Save(NULL,TRUE); // Here Error is getting Logged in SchedLgU
|
|
|
|
|
What is the value of hr ?
"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
|
|
|
|
|
hr = -2147216619
This is the value it gives while saving thru IPersistFile->Save
|
|
|
|
|
I think that value resolves to SCHED_E_SERVICE_NOT_RUNNING .
"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
|
|
|
|
|
fatal error C1076: compiler limit : internal heap limit reached; use /Zm to specify a higher limit
in #include "stdafx.h"
?????
|
|
|
|
|
it also occurs in the line #include "assert.h"
|
|
|
|
|
anybody know how to clear this error??
|
|
|
|
|
Off MSDN:This Site[^]
Visual C++ Concepts: Building a C/C++ Program
Fatal Error C1076
compiler limit : internal heap limit reached; use /Zm to specify a higher limit
Probable cause
Too many symbols
Possible solutions
Use the /Zm option to set the compiler memory limit.
Eliminate unnecessary include files.
Eliminate unnecessary global variables, for example, by allocating memory dynamically instead of declaring a large array.
Eliminate unused declarations.
Split large functions into smaller functions.
Split large classes into smaller classes.
Split the current file into smaller files.
If C1076 occurs immediately after the build starts, the value specified for /Zm is probably too high for your program. Reduce the /Zm value.
The only programmers that are better that C programmers are those who code in 1's and 0's
Programm3r
My Blog: ^_^
|
|
|
|
|
Hi friends,
i want to delete the data of file, by using the file operations
Ex:(like through file operations we can create file, we can write in file, Append the File,But How to Delete the Content of File)
varun
|
|
|
|
|
|
Open the file and call ZeroMemory()
Or open the file using CreateFile passing the CREATE_ALWAYS flag.
Waldermort
|
|
|
|
|
WalderMort wrote: call ZeroMemory()
Did you really mean that? ZeroMemory is related to memory content, right?
- NS -
|
|
|
|
|
varun01 wrote: How to Delete the Content of File)
Use CreateFile() with CREATE_NEW or CREATE_ALWAYS . There's also DeleteFile() .
"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
|
|
|
|
|
...or CreateFile() with the TRUNCATE_EXISTING flag if you want to keep the file but
empty its contents.
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
hai.dear.
i opened win32 application...and i had 3 cpp files which reqd windows.h ...so i added windows.h in win32 files...
now i have one cpp file which is mfc support file..mfc support means using Cstring datatype..and AFxBeginthread and some other also...
so..now i have added that mfc support cpp file to my project...
which is having header files #include afx.h #include afxwin.h and etc..related to mfc..
now i builded my program...it is throwing this error...
fatal error C1189: #error : WINDOWS.H already included. MFC apps must not #include
what to do for this error..how to solve this..
|
|
|
|
|
Remove the windows.h and use the afxwin.h
- NS -
|
|
|
|
|
hai..
already i tried this.., still it is throwing error. becos i am using MSMQ in my project. it requires mq.h header file. this requires the windows.h header file.
|
|
|
|
|
But afxwin.h includes the windows.h
- NS -
|
|
|
|
|
D.Mani wrote: it requires mq.h header file.
So include that in the project's stdafx.h file, below the Afx-related includes.
"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
|
|
|
|
|
use #pragma once or ifndef / ifdef precompiler instructions to avoid repetitions
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
|
|
|
|
|
Nelek wrote: use #pragma once or ifndef / ifdef precompiler instructions to avoid repetitions
mfc doesn't allow you to include Windows.h with it! so ifndef/ifdef will be of no use!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow Never mind - my own stupidity is the source of every "problem" - Mixture
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|