hi andy
assuming that are you are in a network using active directory
check out the following jScript about getting the logged in user name.
//Create a WScript.Network object, which provides access to the user data
var objNetwork = new ActiveXObject("WScript.network");
//Retrieve the UserName and write it into the my:UserName field
XDocument.DOM.selectSingleNode("/my:myFields/my:UserName").text =
objNetwork.UserName;
//Retrieve the UserDomain and write it into the my:UserDomain field
XDocument.DOM.selectSingleNode("/my:myFields/my:UserDomain").text =
objNetwork.UserDomain;
//Retrieve the ComputerName and write it into the my:ComputerName field
XDocument.DOM.selectSingleNode("/my:myFields/my:ComputerName").text =
objNetwork.ComputerName;
cheers
Bart
> Is there anyway that I can get the current logged in user of a sharepoint
> server in infopath form ??
Zuerk - 19 Apr 2005 21:38 GMT
This is also assuming this is a trusted form or that you have the
security permissions to run Active X controls on this form.
riya choudhary - 28 Apr 2005 08:23 GMT
Thanks Bart!!!!!!!11
I wanted this!!