Getting sharepoint id or NTID of person

Jul 9, 2007 at 12:37 PM
Edited Jul 9, 2007 at 12:54 PM
Hi,

I want to get the Sharepoint ID or NTID of person who has modified the document.
In OOB Content Query Webpart,we can get the NTID of person by using

<xsl:value-of select="@x007B822c78e3x002D1ea9x002D4943x002Db449x002D57863ad33ca9x007D " />

But this property does not seems to be available in ECQWP.

Does anyone knows any other way to access it??

Thanks

Amit
Jul 10, 2007 at 11:08 AM
Hi,

In a document library (or where one can access e.g. the Author field) I'm retrieving the ID in the following way:

In itemstyle.xls add the following

at the beginning:

xmlns:ddwrt="http://schemas.microsoft.com/webparts/v2/dataview/runtime"


afterwards:

<xsl:variable name="userID" select="ddwrt:userLookup(string(@Author), 'ID')"/>
<xsl:value-of select select="$userID"/>

Regards,
DD


tutejaamit5 wrote:
Hi,

I want to get the Sharepoint ID or NTID of person who has modified the document.
In OOB Content Query Webpart,we can get the NTID of person by using

<xsl:value-of select="@x007B822c78e3x002D1ea9x002D4943x002Db449x002D57863ad33ca9x007D " />

But this property does not seems to be available in ECQWP.

Does anyone knows any other way to access it??

Thanks

Amit

Jul 11, 2007 at 10:10 AM
HI DD,

i am facing problem in accessing the id of person who has modified the doc. within xsl.
The above appproach worked on my machine but it is not working on other machines.
I tried using your approach,but whenever i add this in itemstyle.xsl the webpart crashes with an error.

the namespace was already there,and error came on adding following
<xsl:variable name="userID" select="ddwrt:userLookup(string(@Author), 'ID')"/>

Am i doing anything wrong?
Amit
Jul 12, 2007 at 11:16 AM
Hi,

I was able to do it.earlier i tried it through OOB Content Query Webpart,but it worked on some systems,but was not working on other systems.A strange problem.But nevermind the above solution worked on ECQWP.

thanks for greatt webpart

Amit