.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 access output parameters from workflow

Posted By:      Posted Date: September 16, 2010    Points: 0   Category :WPF
hi, i am using sequential work flow, now i need to acess the reuslt from the workflow to the host(in my case windows forms).  i can access workflowcompletedeventargs , yes i can acess in the workflow completed event but i need those values to be set to my FORM (it si giving me thread exception) if i  try to acess my form object in workflow completed event can any one give me an example   thanks shankar.

View Complete Post

More Related Resource Links

can a Workflow access a stored procedure and pass the parameters from the list data to the stored pr

The reason that I would like to consider this functionailty is because my table architecture is complicated and I do not want to modify my master table to accept all of this data where some of the data should be normalized into sub tables.  Has anyone see evidence of the stored-procedure parm approach?  Is this best accomplished through VS 2010 or can I do it through SPD? Thanks

Output parameters in OLEDB Command component - SSIS 2008

I have a package that I developed in SSIS 2005 and recently ported to 2008. Everything runs great except an OLE DB Command component that calls a stored procedure that uses output parameters. When I try to run this, I get this error: Error: 0xC0202009 at Data Flow Task, OLE DB Command [100]: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005. An OLE DB record is available. Source: "Microsoft SQL Server Native Client 10.0" Hresult: 0x80004005 Description: "Syntax error, permission violation, or other nonspecific error". Error: 0xC004701A at Data Flow Task, SSIS.Pipeline: component "OLE DB Command" (100) failed the pre-execute phase and returned error code 0xC0202009. When I do the same thing in SSIS2005, it works fine. So I setup a new package with 1 data flow. In that data flow, I added a source component, an OLE DB Command, and a destination.  I then tested this with a stored procedure that took no parameters. It worked fine. I then tested it with a stored procedure with 1 parameter defined as OUTPUT. This generated the error.   Is there an issue with output parameters in an OLE DB Command in SSIS 2008?   Thanks!http://bobp1339.blogspot.com

Workflow Instance ID field in MS Access

Hello, please help! When I open a SP list with MS Access (Action > Open with Access), the Workflow Instance ID field is available with no data.  How can I get this field to display so I can create queries within MS Access using joins/relationships?  Thank you!

Entity Framework and stored procedures with OUTPUT parameters (suggest API)

EF does handle stored procedures with OUTPUT parameters, but the generated methods are not the easiest to work with or safest you could ask for. The ObjectParameter objects you have to create, pass to the method and extract the value from are not type checked and reallyObjectParameter nameParam = new ObjectParameter( "Name", typeof(string)); ObjectParameter ageParam = new ObjectParameter( "Age", typeof(int)); context.GetPersonsNameAndAge( personId, nameParam, ageParam); string name = Convert.IsDBNull(nameParam.Value) ? null : (string)nameParam.Value; int? age = Convert.IsDBNull(ageParam.Value) ? null : (int?)ageParam.Value; is not what I would want to have to write.The ObjectParameter objects do make some sense for stored procedures that return both a resultset and some OUTPUT parameters, because in that case the OUTPUT parameters are only available after the resultset has been consumed and therefore you need some objects that will be populated after the ObjectResult<...> gets processed but for the stored procedures that do not return any resultset, there is no reason not to create the ObjectParameter objects within the method and extract the values there as well. So that the procedure above may be called asstring name; int? age; context.GetPersonsNameAndAge( personId, out name, out age); Things are not so simple for procedures returning both. I'm

Access Denied/The workflow could not copy the item workflow error after Sharepoint 2010 upgrade

We have a sharepoint designer workflow that copies a document from one library to another on the same site.  Before the upgrade to 2007 it worked fine, but now with 2010 it gives an error and cancels the workflow when it gets to the copy list item step.   The error on the workflow page: The workflow could not copy the item. Make sure the source and destination lists have the same columns and column settings.  Access Denied   Specifically it is the "copy list item current item to documentlibrary" sharepoint designer workflow action.   I have given the system account full permissions to the library and double checked that all columns are the same in both libraries. These are the verbose trace logs:   09/01/2010 09:46:04.05 w3wp.exe (0x17C4) 0x093C SharePoint Foundation Workflow Infrastructure 72er Medium System.UnauthorizedAccessException: <nativehr>0x80070005</nativehr><nativestack></nativestack>Access denied. at Microsoft.SharePoint.SPFile.UpdateInternal(Boolean migrationSemantics, Boolean reGhost) at Microsoft.SharePoint.Workflow.SPWinOEWSSService.CommitCopyFile(Transaction txn, Object[] transData) 09/01/2010 09:46:04.05 w3wp.exe (0x17C4) 0x093C SharePoint Foundation Workflow Infrastructure 72fe High Error in commiting pending workflow batch items: Sys

Interesting problem with getting OUTPUT parameters from SQL Server using C#

 I have the following SP: Create procedure dbo.example(@test INT OUTPUT)ASBEGINSET @test = 5SELECT * from UsersENDGO  and when I try calling it from C# using an SqlCommand with adding an output parameter and getting it's value, I get that the value is NULL. (I should mention that I use ExecuteReader)However,  if I alter the SP and remove the select line, the c# code works and returns the value 5. 

Input parameters from Workflow No-Code Or Xaml Only

I have many activities and a customized workflow Only Xaml and I can not pass a value to a property of a custom activity, following the example of Workflow1.xoml   <pre lang="x-xml"><SequentialWorkflowActivity x:Name="Workflow1" xmlns:ns0="clr-namespace:CustomActivities;Assembly=CustomActivities, Version=, Culture=neutral, PublicKeyToken=null" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/workflow"> <ns0:ReadLineActivity x:Name="readLineActivity1" InputText="" /> <ns0:WriteLineActivity x:Name="writeLineActivity1" OutputText="{ActivityBind readLineActivity1,Path=InputText}" /> </SequentialWorkflowActivity> based on this workflow I pass a value for the property InputText activity readLineActivity1   Thanks a lot!

Cannot access Workflow from List Item menu: "Value does not fall within the expected range."


We are using Sharepoint 2007 sp2.

I am using Sharepoint Designer 2007 to create workflow for some List, suddenly I cannot acess some list items' workflow,and was informed  "Value does not fall within the expected range." , but other items are all ok.

I don't know whether this is concerned with the service pack 2, I installed sp2 yesterday.

Access denied when starting workflow


I have a workflow that when started by a site collection admin, allows it to start. But if a user starts it they get access denied. I've set the user up with full access to the document library, tasks and workflow settings and still the same. If I then add the user as a site collection admin all is well.

The workflow has been created using sharepoint designer.

I've tried everything I can think of, so any ideas welcome.




Passing parameters of type List<> from a web application to the Receive activity of a workflow servi



I have a Recieve activity with the following parameters in the Content property.  Using generic parameter names here:

- parameter1 of type Object1 assigned to Parameter1 variable

- parameter2 of type List<Object2> assigned to Parameter2 variable.  Note - default value of Parameter2 variable = New List(Of Object2)()

- parameter3 of type Object3 assigned to Parameter3 variable

In my web application, I create a service reference and create a client as such:


SomeWFServiceClient client = null


 client = new
 List<Object2> listOfObject2 = new
 List<Object2> { new
 Object2 {Id=1, Name="SomeName"
, Type="Customer"
 }, };

client.ProcessSomething(Object1, listOfObject2, Object3);


I have a breakpoint at the Receive activity.  When I look at the values that get assigned to the Receive activity parameters, I see that parameter1 and parameter3 ge

Access Services - The query has too many output columns.


Trying to port a database from Access (2000 or older! via an intermediate upgrade to 2010) to use Access Services on Sharepoint 2010.  The main data entry table contains 41 columns of data and I'm getting this error when trying to load it as a web form: "The query has too many output columns. The maximum number of output columns is 40."

I take it the database needs re-designing to split some of the data off into separate tables to be accessed on-demand?  Or is there a setting inside Sharepoint I can tweak to get the form to display?

Workflow does not run when list item updated with MS Access



I have created a workflow in SharePoint Designer 2007 that copies the list item from one list to another archive list. The workflow is copies the list item when a field is updated to archive. This works fine when updating the list item within SharePoint.

the list is also linked to a Microsoft Access database, the workflow does not even start when updating the field within Access. Can anyone tell me why this is and how I can get the workflow to start when updating the list item with MS Access?

MOSS 2007 version



SPD 2007 Manually Start Workflow access denied


Im having  a isssue i have encountered before, however the fix seems to either have sliped my mind or the fix i thought should fix it seems to be having a issue as well.


I have created a workflow in SPD 2007 to manually start and update a list item, however before i can even get to the "start" page i get access denied with EVERY user except the Site collection administrator.

The fix i had: Check the workflow out in SPD and check back in, BUT im also getting a error with ANY File upon trying to check back in "Cannot perform this operation. the file is no longer checked out or has been deleted" BOTH are not true.

So any input would be greatly appreciated.

Interesting problem with getting OUTPUT parameters from SQL Server using ASP


I had an sqldatasource. I had set its parameter as follows

<asp:SqlDataSource ID="FvDs" runat="server"
InsertCommand="INSERT INTO [Type] ([ShortName], [LongName], [Version]) VALUES (@ShortName, @LongName, @Version);

Then i had retrived the value in OnInserted event of the datasource

protected void FvDs_OnInserted(object sender, SqlDataSourceStatusEventArgs e)
        FvDs.SelectParameters["ID"].DefaultValue = e.Command.Parameters["@ID"].Value.ToString(); 

For the above code it is working fine.

But now i changed the code as follows:

<asp:SqlDataSource ID="FvDs" runat="server"

and here is the code for my stored procedure

ALTER PROCEDURE dbo.usp_InsertData
	@ShortName varchar(20),
	@LongName varchar(50),
	@Version varchar(20),
			INSERT INTO [Type] ([ShortName], [LongName], [Version]) VALUES (@ShortName, @LongName, @Version)

Multiple Parameters Error OLEDB MS Access SSRS



I have created an SSRS in BIDS 2008 with OLEDB Provider so as to access MS Access 2010 DB. My report is working fine. But the only problem is when am sending multiple parameter it raises error. I have enabled AllowMultiple Value checkbox.

ERROR : "Cannot add multi value parameter '@parametername" for DataSetName because it is not supported by the data extension".

My query is "SELECT * FROM tablename WHERE ([columnname] in (@parametername))"

Thanks in advance



DATE Output Parameters for SPROC


Hello everyone,

I have a question.

How do we define date output parameters for a stored procedure?

before you answer,I should mention that I am not referring to the sql syntax definition ,which is @mydate datetime output.


I am repeating that I do I am not referring to the sql definition .

I would appreciate your help.

Thank you

How to call a Stored procedures with varchar output parameters in LINQ


I have a stored procedure with the following structure:

CREATE procedure EditFeriodigiesForm
@EditID int,
@producer varchar(50) output,
@IssuedDate datetime output,
@stadio varchar(50) output,
@Method varchar(50) output,
@Monades_N varchar(50) output,
@Monades_P varchar(50) output,
@Monades_K varchar(50) output,
@comments varchar(100) output,
@responsible varchar(50) output
Begin Try
	Begin tran
SELECT @IssuedDate=IssuedDate,@producer=ProducerID,@stadio=KalliergitikoStadio,@Method=Method,@Monades_N=Monades_N,@Monades_P=Monades_P,@Monades_K=Monades_K,@comments=Comments,@responsible=Responsible from ferti_odigies WHERE FertOdigiesID=@EditID
end try
	Begin catch
	if @@error>0
declare @ErrMsg varchar(4000),
		@ErrSeverity int
Select @ErrMsg=Error_Message(),

Raiserror(@ErrMsg ,@ErrSeverity,1)

end catch 

Now i need to call it in LINQ.I have done the mapping thing and the SPROC is ready to be called in my form.aspx.cs form, as following:
  int id = Edit_id;
            int? producer;
            DateTime date =Convert.ToDateTime(txtdate.Text);
            string stadio;
            string method="";
            string monadesn="";
            string monadesp="";
            string mo
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