SharePoint, ડીઝાઈનર — વપરાશકર્તા વ્યાખ્યાયિત C # કાર્યો ચલાવવા માટે કસ્ટમ પ્રવૃત્તિ

અપડેટ: આ અહીં કોડપ્લેક્સ માટે પ્રકાશિત કરવામાં આવ્યું છે: http://www.codeplex.com/spdwfextensions

અપડેટ: તાજેતરની પ્રકાશન નોંધો માટે અહીં જુઓ: http://paulgalvin.spaces.live.com/blog/cns!1CC1EDB3DAA9B8AA!381.entry

અપડેટ: આ પ્રોજેક્ટ commercializing પર મારા વિચારો માટે અહીં જુઓ: http://paulgalvin.spaces.live.com/blog/cns!1CC1EDB3DAA9B8AA!569.entry

This project provides a custom activity in SharePoint Designer. Use this custom activity to invoke (રવાનગી) any C# function that you incorporated into the linked assembly.

અંતમાં ઓક્ટોબર તરીકે, 2007, this is just an initial version of the project. I plan to expand it with a number of additional functions, શબ્દમાળા સહિત, અનુક્રમણિકા, બદલવું, invoking web services and anything that seems useful or interesting. I also plan to post this to codeplex once I have my act together on that front. This will also be deployable as a solution at some point.

જો તમે કોઇ ટિપ્પણી કરવી હોય તો, પ્રશ્નો અને સૂચનો, ટિપ્પણીઓ તેમને રજા અથવા મને ઇમેઇલ કરો.

દાવો જતો કરવો:

I make absolutely no claims as to the suitability of this for any purpose. Use at your own risk.

સ્થાપન પગલાંઓ (ફાર્મ દરેક WFE માટે અનુસરવામાં આવશે):

1. આ. ઝિપ ડાઉનલોડ કરો અને કાઢવા.

2. Install the .dll into the GAC. I usually open c:\વિન્ડો વિધાનસભા Windows Explorer નો ઉપયોગ કરીને અને તેને ત્યાં નકલ.

3. સુરક્ષિત નિયંત્રણોનો વિધાનસભા ઉમેરવા web.config બદલો:

<System.Workflow.ComponentModel.WorkflowCompiler>
<authorizedTypes>

<authorizedType Assembly="SpdGenericInterface, આવૃત્તિ 1.0.0.0 =, સંસ્કૃતિ = તટસ્થ, PublicKeyToken = abe076fd8125f3c4" Namespace="Nivlag" TypeName="*" Authorized="True" />

4. Copy "SpdGenericInterface.actions" C નો:\કાર્યક્રમ ફાઈલો સામાન્ય ફાઈલો માઈક્રોસોફ્ટ વહેંચાયેલ વેબ સર્વર એક્સ્ટેન્શન્સ 12 TEMPLATE 1033 વર્કફ્લો

ઉપરોક્ત પાંચ આંકડાના US સ્થાન ઇંગલિશ ભાષા સ્થાપનો માટે વિશિષ્ટ છે કે જે નોંધ.

5. બંધ શેરપોઈન્ટ ડિઝાઈનર (તે પહેલાથી જ ખોલી હોય તો).

6. iisreset

7. એસપીડી ખોલો અને નવી વર્કફ્લો બનાવો.

બધા સારી રીતે જાય તો, તમે ક્રિયા એક નવી શ્રેણી સાથે rewarded જોઇએ:

છબી

નોંધો:

જુઓ અહીં (http://blogs.msdn.com/sharepointdesigner/archive/2007/03/15/adding-activities-to-spd.aspx) બનાવવા માટે પ્રક્રિયા એક જબરદસ્ત ઝાંખી માટે, આ જેમ એક ઉકેલ સ્થાપિત કરવા અને રૂપરેખાંકિત કરવા.

આ. ઝીપ તમે કેચ સીધા બહાર કાઢવા માટે રચાયેલ છે:\ drive. If you do this, તમે આ પ્રોજેક્ટ ખોલી શકે છે અને બધા રસ્તાઓ સુસંગત હશે.

વિઝ્યુઅલ સ્ટુડિયો આ ઉપયોગ માટે, you probably need to install "Extensions for Windows WF".

The initial upload contains just one "dispatcher function", "ToLower()". To add more functionality, બતાવ્યા પ્રમાણે પદ્ધતિ ચલાવવા માટે તેને ઉમેરી:

 રક્ષિત ઓવરરાઇડ ActivityExecutionStatus
          બજાવવું(ActivityExecutionContext executionContext)
        {

            સ્ટ્રિંગ functionToDispatch;
            = functionToDispatch .DispatchFunction.ToLower();

            સ્વીચ (functionToDispatch)
            {
                કેસ "tolower()":
                    {
                        .OutResult1 = .InParam1.ToLower();
                        ફોડવું;
                    }

                મૂળભૂત:
                    {
                        .OutResult1 = "Unknown function: [" + .DispatchFunction + "].";
                        ફોડવું;
                    }
            }

            પાછા ActivityExecutionStatus.બંધ;
        } // ActivityExecutionStatus

    }

તે પછી, re-build the project and copy the assembly to the GAC. I expect an iisreset would be required.

9 પર "વિચારોSharePoint, ડીઝાઈનર — વપરાશકર્તા વ્યાખ્યાયિત C # કાર્યો ચલાવવા માટે કસ્ટમ પ્રવૃત્તિ

  1. ગેરી વિટવર્થ
    I followed his directions and everything seemed to work until I choose the action in SP Designer. The designer did not paste the code in the workflow. I sent this guy an email and I guess he is too busy to respond.
    હું મારી જાતે સમસ્યા હલ.
    Past the actions from "SpdGenericInterface.actions" into the "WSS.actions" file and it everything worked. I hope this helps others.
  2. Marco mancinelli
    તે સારી લાગે છે, પરંતુ હું એક્સ્ટેંશન ઇન્સ્ટોલ કરી શકે છે =(
    મારા ડીઝાઈનર કોન તેને જોઈ, પરંતુ હું તેના પર ક્લિક કરો ત્યારે કંઈ દેખાય છે… મદદ કરો… tnx.
  3. માઇક Mongeau

    ચોક્કસપણે એક સારો વિચાર જેવી લાગે છે. હું કાર્યો વપરાશ અને પરીક્ષણમાં સામેલ પ્રેમ કરશો. તે સ્ટ્રિંગ કાર્યો એસપીડી મર્યાદિત છે કે સાચું છે, but the "Dynamic String Builder" ખૂબ શક્તિશાળી છે.

    <એક href ="http://dataformwebpart.com">-Monjo </એક>

  4. Bernard Lambeth

    I’m using this custom activity to Replace() કાર્ય. The farm is SharePoint 2007, with load-balanced web front-ends. I am getting intermittent failure to start errors, but the workflows usually restart in 5 – 15 min. I believe the timer jobs Workflow and Workflow Failover are restarting the workflows. I reviewed the SharePoint logs, and finally caught this error.

    RunWorkflow: Microsoft.SharePoint.SPException:
    at Microsoft.SharePoint.Workflow.SPNoCodeXomlCompiler.LoadXomlAssembly(String assmNameIn, SPWeb વેબ)
    at Microsoft.SharePoint.Workflow.SPWinOeHostServices.CreateInstance(Guid trackingId, SPWorkflow workflow)
    at Microsoft.SharePoint.Workflow.SPWinOeEngine.RunWorkflow(Guid trackingId, SPWorkflowHostService host, SPWorkflow workflow, Collection`1 events, TimeSpan timeOut)
    at Microsoft.SharePoint.Workflow.SPWorkflowManager.RunWorkflowElev(SPWorkflow originalWorkflow, SPWorkflow workflow, Collection`1 events, SPRunWorkflowOptions runOptions)

    I found a reference to this error on another blog, http://www.kentd.com/index.php/all-blog/218-nivlag-and-spdgenericinterface. The author indicated he was using the custom actitivity Replace(), as well. Have you seen this error? Do you have any suggestions on how to resolve it?

એક જવાબ છોડો Marco mancinelli જવાબ રદ કરો

તમારું ઇમેઇલ સરનામું પ્રકાશિત કરવામાં આવશે નહીં. જરૂરી ક્ષેત્રો ચિહ્નિત થયેલ છે *