 |
|
 |
|
Next: Spybot S&D updates
|
| Author |
Message |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 1) Posted: Tue Jul 03, 2007 2:28 pm
Post subject: why ntuser.dat file time stamp is not updated for over a year? Archived from groups: microsoft>public>windows>file_system, others (more info?)
|
|
|
Hello,
I am trying to find out under what circuimstances ntuser.dat
registry file will not be time stamped, even when user login into Windows
daily and performs regular tasks such as running programs.
I have checked on my 3 computers running Win XP and soon after I start
Windows, few minutes later, ntuser.dat will update time stamp to the current
date.
However, over last few years I had few situations, when the persons using
Windows XP had their usernt.dat file time stamp not updated for 500 or more
days!
How is that possible?
Jack >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Oct 14, 2005 Posts: 430
|
(Msg. 2) Posted: Tue Jul 03, 2007 3:33 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
"Jack" wrote in message
> Hello,
> I am trying to find out under what circuimstances ntuser.dat
> registry file will not be time stamped, even when user login into Windows
> daily and performs regular tasks such as running programs.
> I have checked on my 3 computers running Win XP and soon after I start
> Windows, few minutes later, ntuser.dat will update time stamp to the
> current date.
> However, over last few years I had few situations, when the persons using
> Windows XP had their usernt.dat file time stamp not updated for 500 or
> more days!
> How is that possible?
> Jack
>
You're probably looking in the wrong profile folder. >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 3) Posted: Tue Jul 03, 2007 4:28 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
No.
It is not me who is looking, but my code.
And my code is looking at ntuser.dat located in the current user profile.
"C:\Documents and Settings\<current user name>\ntuser.dat"
<Current User Name> is determined by API call.
It works 99.5% of the time but .remaining 05% is the reason I would like to
find the answer.
Jack
"Pegasus (MVP)" wrote in message
>
> "Jack" wrote in message
>
>> Hello,
>> I am trying to find out under what circuimstances ntuser.dat
>> registry file will not be time stamped, even when user login into Windows
>> daily and performs regular tasks such as running programs.
>> I have checked on my 3 computers running Win XP and soon after I start
>> Windows, few minutes later, ntuser.dat will update time stamp to the
>> current date.
>> However, over last few years I had few situations, when the persons using
>> Windows XP had their usernt.dat file time stamp not updated for 500 or
>> more days!
>> How is that possible?
>> Jack
>>
>
> You're probably looking in the wrong profile folder.
> >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Oct 14, 2005 Posts: 430
|
(Msg. 4) Posted: Tue Jul 03, 2007 5:36 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
You should have a look here to make sure you're looking at
the right profile folder:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\hivelist\
\REGISTRY\USER\S-1-5-21-4233798886-620521722-3728218106-1004
"Jack" wrote in message
> No.
> It is not me who is looking, but my code.
> And my code is looking at ntuser.dat located in the current user profile.
> "C:\Documents and Settings\<current user name>\ntuser.dat"
> <Current User Name> is determined by API call.
> It works 99.5% of the time but .remaining 05% is the reason I would like
> to find the answer.
> Jack
>
> "Pegasus (MVP)" wrote in message
>
>>
>> "Jack" wrote in message
>>
>>> Hello,
>>> I am trying to find out under what circuimstances ntuser.dat
>>> registry file will not be time stamped, even when user login into
>>> Windows daily and performs regular tasks such as running programs.
>>> I have checked on my 3 computers running Win XP and soon after I start
>>> Windows, few minutes later, ntuser.dat will update time stamp to the
>>> current date.
>>> However, over last few years I had few situations, when the persons
>>> using Windows XP had their usernt.dat file time stamp not updated for
>>> 500 or more days!
>>> How is that possible?
>>> Jack
>>>
>>
>> You're probably looking in the wrong profile folder.
>>
>
> >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 5) Posted: Tue Jul 03, 2007 5:36 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Also, by the exchanging emails with the user I confirmed that the user name
is correct.
There must be something else causing that.
Jack
"Pegasus (MVP)" wrote in message
> You should have a look here to make sure you're looking at
> the right profile folder:
> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\hivelist\
> \REGISTRY\USER\S-1-5-21-4233798886-620521722-3728218106-1004
>
> "Jack" wrote in message
>
>> No.
>> It is not me who is looking, but my code.
>> And my code is looking at ntuser.dat located in the current user profile.
>> "C:\Documents and Settings\<current user name>\ntuser.dat"
>> <Current User Name> is determined by API call.
>> It works 99.5% of the time but .remaining 05% is the reason I would like
>> to find the answer.
>> Jack
>>
>> "Pegasus (MVP)" wrote in message
>>
>>>
>>> "Jack" wrote in message
>>>
>>>> Hello,
>>>> I am trying to find out under what circuimstances ntuser.dat
>>>> registry file will not be time stamped, even when user login into
>>>> Windows daily and performs regular tasks such as running programs.
>>>> I have checked on my 3 computers running Win XP and soon after I start
>>>> Windows, few minutes later, ntuser.dat will update time stamp to the
>>>> current date.
>>>> However, over last few years I had few situations, when the persons
>>>> using Windows XP had their usernt.dat file time stamp not updated for
>>>> 500 or more days!
>>>> How is that possible?
>>>> Jack
>>>>
>>>
>>> You're probably looking in the wrong profile folder.
>>>
>>
>>
>
> >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 6) Posted: Tue Jul 03, 2007 5:36 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
The API call I use is:
GetUserName()
http://msdn2.microsoft.com/en-us/library/ms724432.aspx
This is a recommended method by Microsoft to obtain the current user name.
Jack
"Pegasus (MVP)" wrote in message
> You should have a look here to make sure you're looking at
> the right profile folder:
> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\hivelist\
> \REGISTRY\USER\S-1-5-21-4233798886-620521722-3728218106-1004
>
> "Jack" wrote in message
>
>> No.
>> It is not me who is looking, but my code.
>> And my code is looking at ntuser.dat located in the current user profile.
>> "C:\Documents and Settings\<current user name>\ntuser.dat"
>> <Current User Name> is determined by API call.
>> It works 99.5% of the time but .remaining 05% is the reason I would like
>> to find the answer.
>> Jack
>>
>> "Pegasus (MVP)" wrote in message
>>
>>>
>>> "Jack" wrote in message
>>>
>>>> Hello,
>>>> I am trying to find out under what circuimstances ntuser.dat
>>>> registry file will not be time stamped, even when user login into
>>>> Windows daily and performs regular tasks such as running programs.
>>>> I have checked on my 3 computers running Win XP and soon after I start
>>>> Windows, few minutes later, ntuser.dat will update time stamp to the
>>>> current date.
>>>> However, over last few years I had few situations, when the persons
>>>> using Windows XP had their usernt.dat file time stamp not updated for
>>>> 500 or more days!
>>>> How is that possible?
>>>> Jack
>>>>
>>>
>>> You're probably looking in the wrong profile folder.
>>>
>>
>>
>
> >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 7) Posted: Tue Jul 03, 2007 11:01 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
I have tried that key.
On my computer the value is:
\Device\HarddiskVolume1\Documents and Settings\Jacek\ntuser.dat
How to translate that path to the generally accepted format?
Jack
"Pegasus (MVP)" wrote in message
> You should have a look here to make sure you're looking at
> the right profile folder:
> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\hivelist\
> \REGISTRY\USER\S-1-5-21-4233798886-620521722-3728218106-1004
>
> "Jack" wrote in message
>
>> No.
>> It is not me who is looking, but my code.
>> And my code is looking at ntuser.dat located in the current user profile.
>> "C:\Documents and Settings\<current user name>\ntuser.dat"
>> <Current User Name> is determined by API call.
>> It works 99.5% of the time but .remaining 05% is the reason I would like
>> to find the answer.
>> Jack
>>
>> "Pegasus (MVP)" wrote in message
>>
>>>
>>> "Jack" wrote in message
>>>
>>>> Hello,
>>>> I am trying to find out under what circuimstances ntuser.dat
>>>> registry file will not be time stamped, even when user login into
>>>> Windows daily and performs regular tasks such as running programs.
>>>> I have checked on my 3 computers running Win XP and soon after I start
>>>> Windows, few minutes later, ntuser.dat will update time stamp to the
>>>> current date.
>>>> However, over last few years I had few situations, when the persons
>>>> using Windows XP had their usernt.dat file time stamp not updated for
>>>> 500 or more days!
>>>> How is that possible?
>>>> Jack
>>>>
>>>
>>> You're probably looking in the wrong profile folder.
>>>
>>
>>
>
> >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jul 04, 2007 Posts: 8
|
(Msg. 8) Posted: Wed Jul 04, 2007 12:12 am
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Jack wrote:
> The API call I use is:
> GetUserName()
> http://msdn2.microsoft.com/en-us/library/ms724432.aspx
>
> This is a recommended method by Microsoft to obtain the current user name.
That is the recommended way to get the current user name but NOT the
recommended way to get the current user profile path. Please note that
there is no guarantee that the the current user path is C:\Documents and
Settings\<current user name>, if for example the ntuser.dat in the user
profile is damaged in some way and cannot be loaded when the user logs
on the user will get a new profile with a new path. Same goes if there
is already another directory present with the name C:\Documents and
Settings\<current user name> when the user logs on for the first time.
Either do like "Pegasus" said, look at the
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\hivelist registry
key for loaded hive files or use the GetUserProfileDirectory() API.
--
Olof Lagerkvist
ICQ: 724451
Web: http://here.is/olof >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 9) Posted: Wed Jul 04, 2007 12:12 am
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Olof,
Thank you for the insight. I see I have not explained all
properly.
I do not use a hardcoded path.
What I do is:
In Windows registry I look up the path to 'Desktop'
HKEY_CURRENT_USER/"Software\Microsoft\Windows\CurrentVersion\Explorer\Shell
Folders\"
From that key I extract path, then I add the current user name (returned
from API) and that is the way I create path to the ntuser.dat file.
What can be wrong with that approach?
Thanks,
Jack
"Olof Lagerkvist" wrote in message
> Jack wrote:
>
>> The API call I use is:
>> GetUserName()
>> http://msdn2.microsoft.com/en-us/library/ms724432.aspx
>>
>> This is a recommended method by Microsoft to obtain the current user
>> name.
>
>
> That is the recommended way to get the current user name but NOT the
> recommended way to get the current user profile path. Please note that
> there is no guarantee that the the current user path is C:\Documents and
> Settings\<current user name>, if for example the ntuser.dat in the user
> profile is damaged in some way and cannot be loaded when the user logs on
> the user will get a new profile with a new path. Same goes if there is
> already another directory present with the name C:\Documents and
> Settings\<current user name> when the user logs on for the first time.
>
> Either do like "Pegasus" said, look at the
> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\hivelist registry key
> for loaded hive files or use the GetUserProfileDirectory() API.
>
> --
> Olof Lagerkvist
> ICQ: 724451
> Web: http://here.is/olof >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Oct 14, 2005 Posts: 430
|
(Msg. 10) Posted: Wed Jul 04, 2007 3:24 am
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
To remove any doubt about the location of this file, do this while
the user is logged on:
- Unhide it (this will work).
- Try to rename it to "ntuser.dat" (this won't work while the user is logged
on).
"Jack" wrote in message
>I have tried that key.
> On my computer the value is:
> \Device\HarddiskVolume1\Documents and Settings\Jacek\ntuser.dat
> How to translate that path to the generally accepted format?
> Jack
>
> "Pegasus (MVP)" wrote in message
>
>> You should have a look here to make sure you're looking at
>> the right profile folder:
>> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\hivelist\
>> \REGISTRY\USER\S-1-5-21-4233798886-620521722-3728218106-1004
>>
>> "Jack" wrote in message
>>
>>> No.
>>> It is not me who is looking, but my code.
>>> And my code is looking at ntuser.dat located in the current user
>>> profile.
>>> "C:\Documents and Settings\<current user name>\ntuser.dat"
>>> <Current User Name> is determined by API call.
>>> It works 99.5% of the time but .remaining 05% is the reason I would like
>>> to find the answer.
>>> Jack
>>>
>>> "Pegasus (MVP)" wrote in message
>>>
>>>>
>>>> "Jack" wrote in message
>>>>
>>>>> Hello,
>>>>> I am trying to find out under what circuimstances
>>>>> ntuser.dat registry file will not be time stamped, even when user
>>>>> login into Windows daily and performs regular tasks such as running
>>>>> programs.
>>>>> I have checked on my 3 computers running Win XP and soon after I start
>>>>> Windows, few minutes later, ntuser.dat will update time stamp to the
>>>>> current date.
>>>>> However, over last few years I had few situations, when the persons
>>>>> using Windows XP had their usernt.dat file time stamp not updated for
>>>>> 500 or more days!
>>>>> How is that possible?
>>>>> Jack
>>>>>
>>>>
>>>> You're probably looking in the wrong profile folder.
>>>>
>>>
>>>
>>
>>
>
> >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jul 04, 2007 Posts: 8
|
(Msg. 11) Posted: Wed Jul 04, 2007 2:23 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Jack wrote:
> Olof,
> Thank you for the insight. I see I have not explained all
> properly.
> I do not use a hardcoded path.
> What I do is:
> In Windows registry I look up the path to 'Desktop'
> HKEY_CURRENT_USER/"Software\Microsoft\Windows\CurrentVersion\Explorer\Shell
> Folders\"
> From that key I extract path, then I add the current user name (returned
> from API) and that is the way I create path to the ntuser.dat file.
> What can be wrong with that approach?
Still the same problem. You are using the user name returned by
GetUserName() and may not necessarily be part of the path to the user's
profile.
Think about this situation:
You have a user 'user1' and log on that user. A profile 'C:\Documents
and Settings\user1' is created and the ntuser.dat is then 'C:\Documents
and Settings\user1\ntuser.dat'. Your technique will find the ntuser.dat
successfully because you get the path 'C:\Documents and
Settings\user1\Desktop' from the registry and the user name 'user1' from
GetUserName(), you extract 'C:\Documents and Settings' and then add
'\user1\ntuser.dat' and that will work.
Now, example 1:
Someone renames the user account 'user1' to 'user2'. The profile is
still 'C:\Documents and Settings\user1' but the GetUserName() function
will return 'user2' and your approach will no longer work.
Example 2:
Someone changes the location for the user's desktop from 'C:\Documents
and Settings\user1\Desktop' because he wants to share the desktop of
another user's profile and set it to 'C:\Documents and
Settings\anotheruser\Desktop'. Your method will find the wrong directory
in this case too.
Example 3:
Someone adds the computer to the domain 'domainname' and makes a domain
logon with a domain account that also has the name 'user1'. A new user
profile is created for this domain account 'C:\Documents and
Settings\user1.domainname'. GetUserName() will return just 'user1'...
etc...
--
Olof Lagerkvist
ICQ: 724451
Web: http://here.is/olof >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 12) Posted: Fri Jul 06, 2007 2:17 am
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Olof,
What is your opinion about using:
SHGetFolderPath() with CSIDL_PROFILE?
I appreciate your comments,
Jack
"Olof Lagerkvist" wrote in message
> Jack wrote:
>> Olof,
>> Thank you for the insight. I see I have not explained all
>> properly.
>> I do not use a hardcoded path.
>> What I do is:
>> In Windows registry I look up the path to 'Desktop'
>> HKEY_CURRENT_USER/"Software\Microsoft\Windows\CurrentVersion\Explorer\Shell
>> Folders\"
>> From that key I extract path, then I add the current user name (returned
>> from API) and that is the way I create path to the ntuser.dat file.
>> What can be wrong with that approach?
>
>
> Still the same problem. You are using the user name returned by
> GetUserName() and may not necessarily be part of the path to the user's
> profile.
>
> Think about this situation:
>
> You have a user 'user1' and log on that user. A profile 'C:\Documents and
> Settings\user1' is created and the ntuser.dat is then 'C:\Documents and
> Settings\user1\ntuser.dat'. Your technique will find the ntuser.dat
> successfully because you get the path 'C:\Documents and
> Settings\user1\Desktop' from the registry and the user name 'user1' from
> GetUserName(), you extract 'C:\Documents and Settings' and then add
> '\user1\ntuser.dat' and that will work.
>
> Now, example 1:
> Someone renames the user account 'user1' to 'user2'. The profile is still
> 'C:\Documents and Settings\user1' but the GetUserName() function will
> return 'user2' and your approach will no longer work.
>
> Example 2:
> Someone changes the location for the user's desktop from 'C:\Documents and
> Settings\user1\Desktop' because he wants to share the desktop of another
> user's profile and set it to 'C:\Documents and
> Settings\anotheruser\Desktop'. Your method will find the wrong directory
> in this case too.
>
> Example 3:
> Someone adds the computer to the domain 'domainname' and makes a domain
> logon with a domain account that also has the name 'user1'. A new user
> profile is created for this domain account 'C:\Documents and
> Settings\user1.domainname'. GetUserName() will return just 'user1'...
>
> etc...
>
> --
> Olof Lagerkvist
> ICQ: 724451
> Web: http://here.is/olof >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
External

Since: Jul 04, 2007 Posts: 8
|
(Msg. 13) Posted: Fri Jul 06, 2007 3:09 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
|
|
| Back to top |
|
 |  |
External

Since: Jun 13, 2007 Posts: 12
|
(Msg. 14) Posted: Fri Jul 06, 2007 3:09 pm
Post subject: Re: why ntuser.dat file time stamp is not updated for over a year? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
|
|
|
Thank you.
Jack
"Olof Lagerkvist" wrote in message
> Jack wrote:
>
>> Olof,
>> What is your opinion about using:
>> SHGetFolderPath() with CSIDL_PROFILE?
>> I appreciate your comments,
>
>
> That should work (as long as you specify the SHGFP_TYPE_CURRENT flag), or
> you can use GetUserProfileDirectory().
>
> Either of them should return the same, currently correct, user profile
> path.
>
> --
> Olof Lagerkvist
> ICQ: 724451
> Web: http://here.is/olof >> Stay informed about: why ntuser.dat file time stamp is not updated for over a y.. |
|
| Back to top |
|
 |  |
| Related Topics: | merging reg file - Hi. Does anybody know how to restore double clicking on .reg file to merge it. When I double click on it Notepad opens. The only way I can merge a .reg file is to open regedit and import it. Thanks David Smith
Cannot find file on startup - On startup get 2 messages stating cannot find and then remove file "E:CDSETUP.EXE". How do I get rid of these pop-ups? Looked at regedit.exe but didn't understand it at all and was warned not to mess with it.
Problem with File Associations - I've created a program similar to Winzip. It takes command line arguments like this: zip file1 file2 ... fileN I've added this Keys to Registry: HKEY_CLASSES_ROOT\*\Shell\MYZIP HKEY_CLASSES_ROOT\*\Shell\MYZIP\Command = "[PROGRAM_PATH]\Myzip...
Where is the registry file located? - And what is the file name? Just curious, Rob
What is the shell entry to print an eml file? - Hi everyone, What is the shell entry to be used to print an eml file? Ie, to be able to print a file stright away from the explorer we need to add a shell command for each file type. Does anyone know what is the command to be used for an eml file? .. |
|
You can post new topics in this forum You can reply to topics in this forum You can edit your posts in this forum You can delete your posts in this forum You can vote in polls in this forum
|
|
|
|
 |
|
|