Click here to Skip to main content
16,006,535 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Generalplz. help rectify LogonUser(...) ImpersonateUser problem Pin
r i s h a b h s20-Jan-03 17:39
r i s h a b h s20-Jan-03 17:39 
Generalamazing............................... Pin
r i s h a b h s20-Jan-03 23:06
r i s h a b h s20-Jan-03 23:06 
GeneralRe: amazing............................... Pin
xxhimanshu20-Jan-03 23:29
xxhimanshu20-Jan-03 23:29 
GeneralRe: amazing............................... Pin
xxhimanshu20-Jan-03 23:56
xxhimanshu20-Jan-03 23:56 
Generalatlast some inspiration!!!!!!!!!!! Pin
r i s h a b h s21-Jan-03 17:37
r i s h a b h s21-Jan-03 17:37 
GeneralCreating controls during runtime Pin
Baatezu20-Jan-03 14:00
Baatezu20-Jan-03 14:00 
GeneralRe: Creating controls during runtime Pin
xxhimanshu20-Jan-03 19:28
xxhimanshu20-Jan-03 19:28 
GeneralRe: Creating controls during runtime Pin
Baatezu20-Jan-03 19:41
Baatezu20-Jan-03 19:41 
I found the answer. Smile | :)
I was setting the pointers equal and when I deleted I freed the chunk of memory both were pointing to, and when I created new it created a new chunk. Took a few to get out of sync.
I just had to add in a for loop and it works all better now.
Thanks for anyway working to try and get me an answer.

I changed the IF statement structure section to this

---BEG CODE---
if(cnt < 1)
{
StaticArr = new HWND[++cnt];
}
else if(cnt > 0)
{
temp = new HWND[cnt];
for(loopctr=0; loopctr < cnt; loopctr++)
{
temp[loopctr] = StaticArr[loopctr];
}
delete [] StaticArr;
StaticArr = new HWND[++cnt];
for(loopctr=0; loopctr < cnt; loopctr++)
{
StaticArr[loopctr] = temp[loopctr];
}
delete [] temp;
}
---END CODE---

The wisest of the wise may err. - Aeschylus
GeneralReturn between CStrings Pin
Sunnygirl20-Jan-03 13:36
Sunnygirl20-Jan-03 13:36 
GeneralRe: Return between CStrings Pin
Tim Smith20-Jan-03 14:01
Tim Smith20-Jan-03 14:01 
GeneralRe: Return between CStrings Pin
Thomas Lau20-Jan-03 14:23
Thomas Lau20-Jan-03 14:23 
GeneralRe: Return between CStrings Pin
Thomas Lau20-Jan-03 14:27
Thomas Lau20-Jan-03 14:27 
GeneralVideo Window Pin
Callisto20-Jan-03 12:27
Callisto20-Jan-03 12:27 
GeneralRe: Video Window Pin
Daniel Strigl20-Jan-03 20:05
Daniel Strigl20-Jan-03 20:05 
GeneralTurning the pc off Pin
Li Mu Bai20-Jan-03 11:37
Li Mu Bai20-Jan-03 11:37 
GeneralRe: Turning the pc off Pin
User 665820-Jan-03 11:44
User 665820-Jan-03 11:44 
GeneralStatus Bar Pin
Paddy20-Jan-03 10:33
Paddy20-Jan-03 10:33 
GeneralRe: Status Bar Pin
georgiek5020-Jan-03 13:44
georgiek5020-Jan-03 13:44 
GeneralRe: Status Bar Pin
Paddy22-Jan-03 10:02
Paddy22-Jan-03 10:02 
Generalsubclassed mfc control Pin
Tym!20-Jan-03 9:41
Tym!20-Jan-03 9:41 
GeneralRe: subclassed mfc control Pin
Navin20-Jan-03 10:44
Navin20-Jan-03 10:44 
GeneralYet another dll question Pin
VanHlebar20-Jan-03 9:01
VanHlebar20-Jan-03 9:01 
GeneralStart Menu Shortcut Pin
Ken Mazaika20-Jan-03 8:52
Ken Mazaika20-Jan-03 8:52 
GeneralRe: Start Menu Shortcut Pin
Todd Smith20-Jan-03 8:59
Todd Smith20-Jan-03 8:59 
GeneralRe: Start Menu Shortcut Pin
Ken Mazaika20-Jan-03 9:04
Ken Mazaika20-Jan-03 9:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.