.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

How to get Email of Current User Data View Web Part Sharepoint 2010 and pass to WebService data sour

Posted By:      Posted Date: September 28, 2010    Points: 0   Category :SharePoint
I have to pass in the email address of the current user to a web service data source (run time) of a Data View Web Part.

My Question is:

a) How can I get Email address of current user based  in DVWP.
I know we can get the CurrentUser using the CurrentUserName but how do we get the Email for the Current User.

b) After getting the Email how do we pass to the Web Service.

View Complete Post

More Related Resource Links

format-number issues with the Data View Web Part in SharePoint 2010

I have a number column named @Year_x0020_1_x0020_Revenue in the data view web part in SharePoint Designer 2010. In the Xpath expression builder - @Year_x0020_1_x0020_Revenue previews "500,000" If I use the format-number in the Xpath expression builder ==> format-number(@Year_x0020_1_x0020_Revenue, '$#,##0.00;-$#,##0.00'), it returns NaN. Is there any reason? 

Data View Web Part in SharePoint Designer 2010

Is Data View Web Part (aka Data Form Web Part) in the SharePoint 2010 has changed from the SharePoint 2007 or Is it working differently in the SharePoint Designer 2010? In SharePoint Designer 2007, whenever you have data view web part on the page, there is little handle to click on the top right of the data view web part to show Common Common Data View Tasks. Also for each cell, there was a handle to show xsl:value-of tasks which was great for formatting. Is that option is gone in the SharePoint Designer 2010?

Creating a SharePoint 2010 Web Part That Can Read and Write Data to an External Data Source

Learn to use Visual Studio 2010 to create a Visual Web Part that uses a BCS external content type in SharePoint Server 2010 to read and write data to the AdventureWorks sample database.

Sample: Creating a SharePoint 2010 Web Part That Can Read and Write Data to an External Data Source

Explore the code in this visual how-to article as you learn to use Visual Studio 2010 to create a Visual Web Part that uses a BCS external content type in SharePoint Server 2010.

Quick Note: Accessing Data in a SharePoint 2010 Web Part by using LINQ

In this exercise, you develop and deploy a visual Web Part that reads data from two lists by using a LINQ query and displays it in a DataGrid control.

How to get "Current Date" on SharePoint Designer for Invoice Ageing Data View Report??

Hi Experts, I would like to know how can i get/show "Current Date" in SharePoint Designer ?? Any good tutorial ? FYI, I need this "Current Date" for my Ageing Data View Report, Purpose To offset with "Invoice Receive Date" to get total days of payment payable for the invoice. Please assists, Thanks

Data-Bound Design: Create a Silverlight 4 Web Part for SharePoint 2010

When building custom SharePoint 2010 solutions, it makes a lot of sense to take advantage of Silverlight 4 on the front end. We'll walk you through the process of building a Silverlight Web Part with Visual Studio and Expression Blend.Paul StubbsMSDN Magazine September 2010

Collect Data From User in Sharepoint 2010



I am trying to run a task where I collect data from a user, simple YES/NO choice selection, within SPD.

I have created the workflow and it does run, however the Output to returns the List Item Id, which is fine, I understand this is the Task ID.

But I cannot work out how to get the result from my YES/NO to use further in the workflow so as to change the status of another list item.

I have read the guide for 2007 (http://office.microsoft.com/en-us/sharepoint-designer-help/collect-data-from-a-user-in-a-workflow-HA010209808.aspx#BM5) but this guide does not follow for SPD 2010.

Can anyone point me in the direction of a guide/example or explain what I am missing.  I would prefer to be able to complete this task within SPD, rather than VS2010.

Thanks in advance


Pass information from one web service to another web service in the same data-view-web-part


In Data View Web Part.

Is it possible to pass information from one web Service data source connection to another web service data source connection within the same Data Form Web Part to get information from second web service?

What I am trying to achieve is to get user email address from the User Profile Web Service and pass in to another web service to get information.

Please advise if it is possible.

Calendar View for External Data List in SharePoint 2010?


I'd like to create a calendar view from data contained in an External List.  My external content type has a Start Date, End Date, and other calendar fields.  Is this possible using the out of the box BCS?

For extra credit - I'd like to then use this calendar as an overlay on other calendars within my SharePoint 2010 application.

Thanks for your help!

Sharepoint Designer 2010 - Collect Data from User Issue


I am currently running Sharepoint 2010 Foundation and Sharepoint Designer 2010

I am creating a custom workflow where I am asking 1 user for input using collect data from user.  Following this I am asking a different user the same question using another collect data from user.

Since these creates 2 tasks (1 for each user) I wanted to store the information in the same column, but I seem unable to do so.  Each collect data from user seems to create it's own column even if you name both the same (you end up with 2 columns with the same name but different column id's).

Is there a way to point them both to the same column?  Is there a better way to do this?


More the less I am asking the both persons a yes/no question.  in my workflow if they both say yes I send an e-mail but wanted to have only 1 column in the vew to see the results on the tasks.




How to Pass data(not the part of model) from View to Controller?


How Can I Pass data(not the part of model) to Controller from View?
View Code

<%= Html.ActionLink(item.Name, "ActionName", "ControllerName", new { companyID = Html.Encode("abc"), ID = Html.Encode("xyz") })%>

Controller Code

public ActionResult ActionName(string companyID , string ID)

Any idea?

Content Query Web Part Sharepoint 2010 AND Customize the data presentation


In fields to display you have a Title field. We will like to show two columns (Section Name and Status) in the title field, but only the fist one is displayed in the result.We use this syntax:

Column [Group];Column [Group]

When I use this formula

Section Name [Agresso R&D Base Columns] ; Status [Agresso R&D Base Columns ]

in the title field, the Section Name is displayed, and no Status, When I use this formula

Status [Agresso R&D Base Columns ]; Section Name [Agresso R&D Base Columns] ;

in the title field the Status field is displayed, and no section name. Is this a bug? or is it an other way to show both columns in the title field?


Fields to display Depending on the scope of your query, you can select one or more site or list columns whose values you want to show in the display slots for this style. To specify a column from a particular group, type the name of the group in square brackets after the column name, for example, Column [Group]. Be sure to separate each column you enter with a semi-colon.


Data Form Web Part - Sharepoint Dropdown List as a field in Edit View - Possible?


Hi guys,

I'm building a Sharepoint page with a data form web part that uses custom SELECT and UPDATE statements with an SQL Server connection in order to retrieve and store records of information.

I'm getting along fine, records seem to update how they should etc, but I've ran into a problem with one thing: Sharepoint dropdownlists in 'Edit Template'

So the issue is this: if I replace a textbox field with a dropdown list that is populated with a separate SQL datasource, the dropdown list seems to be unable to show the current value of the field.

E.g. I have a dataview which has a field "FruitID", which I can update just fine by setting the ID value to different numbers. The SQL datasource uses the FruitID to display a list of all available Fruits, (e.g. 1 = Banana, 2 = Apple, 3 = Cherry, etc).

If i open the dataview in editmode, the default value in the dropdown is null, despite the real value of the field being "2", which should show "Apple" in the dropdown.

I can select a fruit and click save, and it will update just fine. But the initial display needs to show the correct value to start with.

Is there a custom binding I should be coding to make this work? I can't configure dropdown <items> on an individual level as they are populated from the SQL server. I can't set "SelectedI

How to pass current user to bdc list to filter data.

Hi all,

I have a bdc list which I want to load on the basis of the currently logged in user. I've tried to use the Current User Filter Web Part provided OOB but it doesn't seem to solve the problem cu'z I can't bind the current user value of the webpart to any column of the bdc list.

The problem is, I want to load the records based on the current user by passing the user name to Stored Procedure. Does any one know how to do that ???? Please F1.



Accessing SharePoint 2010 Data with Server-Side APIs

Accessing SharePoint data in server-side solutions is one of the most common tasks that you will perform as a SharePoint developer. SharePoint 2010 provides powerful server-side APIs that enable you to retrieve, add, edit, and delete SharePoint data programmatically. SharePoint 2010 also includes the new LINQ to SharePoint technology that enables you to work with SharePoint data efficiently and easily.

Linq - add data to database then email user the details


Hi all

I'm not sure how to structure the code for this but what I want to do is be able to add data to a database, and once this has completed successfully, then email the user to say the details have been added successfully to the database.

I need to:

1. Check that the relevant data has been added into the database then

2. Email the details of the relevant data when completed. 


Thanks in advance for your help,




ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend