EnterProjectStage - reading GUID from a string variable within Workflow created in Visual Studio 2012.

Hi,
I am creating a Project Server Workflow (site workflow) using Visual Studio 2012.
If i set the "EnterProjectStage" activity with a GUID within quotes the workflow works
(as suggested in the MSDN blog (http://blogs.msdn.com/b/project_programmability/archive/2012/11/07/creating-project-workflows-using-visual-studio-2012.aspx).
However, the GUID of stages will change from environment to environmet (QA, Stage, PROD). So, I tried setting the GUID in a string variable (which i am populating dynamically) and assigned the string variable to the "EnterProjectStage"
activity. However, this dynamic assignment of stage id to "EnterProjectStage" does not work and after deployment the workflow dumps with the following error:
===============================================
Exception Starting Workflow: Sequence contains no elements. Trace: at System.Linq.Enumerable.First[TSource](IEnumerable`1 source) at Microsoft.Office.Project.Server.BusinessLayer.Workflow.<FillWorkflowStatusTableFromXaml>b__47(XElement
e) at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext() at System.Linq.Enumerable.<DistinctIterator>d__81`1.MoveNext() at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection) at System.Linq.Enumerable.ToList[TSource](IEnumerable`1
source) at Microsoft.Office.Project.Server.BusinessLayer.Workflow.FillWorkflowStatusTableFromXaml(String xaml, WorkflowDataSet& ds, Guid projUid) at Microsoft.Office.Project.Server.BusinessLayer.Workflow.StartWorkflow(Guid projectGuid, Guid enterpriseProjectTypeUid,
Boolean isNewProject, Guid previousEntepriseProjectTypeUid, Boolean skipStage, Guid stageToSkipTo):
WorkflowExceptionStartingWorkflow (35115). Details: id='35115' name='WorkflowExceptionStartingWorkflow'
uid='b31d825e-1d00-e411-9466-005056b11412'. 
===============================================
Is there a way the "EnterProjectStage" can be made dynamic so that it reads from a variable.
Thanks,
Amitava.

Arthur,
Thank you for your reply.  But at this point, one of my points of confusion is what software I have available to me.  I wish I had a useful central help desk to call up and just say, "Hey, load me up with all of the professional version(s) of Visual
Studio.  But I do not know what we have license to.  And I kind of need to know what the options are, so that I can ask a specific question of our vast buracracy.
For now, I have downloaded only free versions of Visual Studio client software.  Since my company does have servers running Microsoft SQL Server, I am going to assume that we have proper licensing for those servers.  But does that server license
allow me to get any professional versions of the PC client software for the various Visual Studio(s) 2012?
And if I get a professional version of Visual Studio 2012, does that do away with the three different flavors that I have right now?  I have 2012 versions of SQL Server Management Studio, Visual Studio Express, and Visual Studio Shell (Integrated).
Your feedback is much appreciated.
Thanks!

Similar Messages

  • Escape single quote from a String variable

    Hi,
    I have a String variable called "name" which i am using in my form tag.
    <form name=test action="test.jsp?fname=<%=name%>" method="post">
    But i am getting Javascript error if the "name" variable contains a string with some special characters like single quote( ' ).
    Plz help me to escape this special char from my String variable.
    Thanks..

    You need to url-encode the value using the URLEncoder class.
    http://java.sun.com/javase/6/docs/api/java/net/URLEncoder.html
    For example:
    <form name=test action="test.jsp?fname=<%=URLEncoder.encode(name, "ISO-8859-1")%>" method="post">

  • Reading parameters from Query string : Sender SOAP adapter.

    Hello Experts,
    I have a SOAP to SOAP scenario. Here we will have multiple receivers and dynamic receiver determination is needed.
    The sender will send a Value in Query string of URL to sender SOAP adapter. This value in Query string parameter will decide the receiver at runtime.
    I need to know, how can we read values from Query string of incoming call? I did tried to search blogs & forum threads but unfortunately not able to hit the right links.
    Any inputs will be of great help.
    Should i use "Use Query String" on sender soap channel? I tried it, but i was not able to find any query string parameters in SOAP header or payload.
    Please guide me, its bit urgent.
    Regards,
    Abhi.

    > But the argument provided from their side is: They are using standard XSD and this service is provided out of box with sender application.
    If they can add a URL parameter, they can also add a field to the structure.
    > They cant control the value mapping of parameters in payload to the extent required to implement this change.
    Adding a new field to the structure would not affect any existing mapping.
    > Since they have this custom requirement of multiple receivers & receiver to be determined at runtime, they need to go for Query string.
    This can be done based on any field of the payload.
    > I need to find a way to read the query string in any case.
    This is not supported by SOAP adapter.
    > Can I use one of the header parameters to be mapped to this value  (By selecting "Use Query string" & "Keep Headers" flag in sender CC) & then extract this value from header using Dynamic configuration ?
    This feature works only for XI header fields, like message ID or QoS.
    Not for individual parameters.

  • How to populate an internal table from a string variable

    Hi Experts,
    My internal table contains a field of length 255 characters.
    I have a string variable. I need to populate the internal table from the string variable.
    How should I code for this.
    Thanks,
    Sangeeta.

    Hi Sangeetha,
    <li>Try this way.
    REPORT ztest_notepad.
    DATA: BEGIN OF it_file OCCURS 0,
           data TYPE c LENGTH 255,
          END OF it_file.
    DATA str     TYPE string.
    DATA g_len   TYPE i.
    DATA g_off   TYPE i.
    DATA g_loops TYPE i.
    CONCATENATE
    '1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890x'
    '1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890y'
    '1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890z'
    '12345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789m'
    INTO str SEPARATED BY space.
    g_len   = STRLEN( str ).
    g_loops = g_len / 255.
    g_off = 1.
    DO g_loops TIMES.
      IF g_loops NE sy-index.
        IF sy-index EQ 1.
          it_file-data = str+0(255).
        ELSE.
          it_file-data = str+g_off(255).
        ENDIF.
        APPEND it_file.
        CLEAR  it_file.
        g_off = sy-index * 255.
      ELSE.
        g_len = g_len - g_off.
        it_file-data = str+g_off(g_len).
        APPEND it_file.
        CLEAR  it_file.
      ENDIF.
    ENDDO.
    LOOP AT it_file.
      WRITE:/ it_file-data.
    ENDLOOP.
    Thanks
    Venkat.O

  • Reading values from lookup columns through custom workflow in SharePoint 2013

    We are able to read the values of text, number columns through custom workflow (via coding) in SharePoint 2013. However, we are not able to read values from lookup columns. So, request anyone to provide help on this.
    Thanks & regards,
    Aditya

    Hi,
    According to your post, my understanding is that you want to read values from lookup columns through custom workflow in SharePoint 2013.
    Since the workflow just doesn't get lookup fields, let's give it something static to work with instead. If we can capture the ID of the lookup field and store that as a static value in our list, the workflow can happily use that to look up our related.
    For more information, you can refer to:
    SharePoint 2013 Workflows and Lookup Columns
    Thanks,
    Linda Li                
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Linda Li
    TechNet Community Support

  • Connection String for Oracle from Visual Studio 2012

    I have oracle Connection credentials which is to be connected to Oracle 9i.
    I have Visual Studio 2012... i m trying to connect to the oracle host.. it gives the following error. "ora-12514 tns listener was not given the service_name"
    1. I have installed 32 Bit Oracle Developer Tools for Visual Studio.
    2. I m using Windows 7 OS 32 Bit
    Please advice
    Hai

    Maybe this one helps.
    https://community.oracle.com/message/2310374
    or possibly ask them here.
    https://www.oracle.com/communities/index.html
    Regards, Dave Patrick ....
    Microsoft Certified Professional
    Microsoft MVP [Windows]
    Disclaimer: This posting is provided "AS IS" with no warranties or guarantees , and confers no rights.

  • Dynamic Variable name (for int/long) from a String variable

    Hi,
    I want to give a int/long variable name from a String.
    for ex.
    String str = lookup + "Id";
    lookup is a String variable coming from XML. Now, for instance lookup="name". So str = "nameId".
    Now I want to create a int/long variable by nameId.
    Could anybody tell me the way how to do. Please don't tell to use MAP.
    Edited by: Shah on Dec 5, 2007 3:26 PM

    Well you can't. Use a Map.
    The compiler translates variable names into slot numbers, either within an object or withing the local "stack frame" and these slot numbers are assigned names at compile time. No new slots can be created at run time. Java is not Basic.
    Reflection allows you to find existing field names and methods (not local variables), so it's possible to map, for example, XML attribute names to field names or setters in an object but the names have to be known at compile time.

  • Naming an ArrayList using value from a String variable

    I am trying to name an ArrayList the value of a String variable in this code:
    public void addstudent(String name)
    ArrayList //i need a name here// = new ArrayList();
    I want to use the String //name// that will be used when the method is called. What do I do? I tried using:
    ArrayList (String.valueOf(name)) = new ArrayList();
    That didn't work.
    Thanks in advance for any help.

    Its suppossed to allow the user to input the student's name, grades for 4 specific subjects. Then take that and organize the students by name alphabetically. It is also suppossed to allow the user to search for users by grades, like find everybody with a GPA of 3.7 or higher or find everybody with a GPA of 3.5. This was a project asigned by my intro computer science teacher. I was suppossed to make it with 2D arrays but that was lousy because you were then limited to a specific number of students without editing the code. I'm not familiar with all the different ways of doing this. My computer science teacher said that I could do it with a HashSet.
    Okay. You have a String. Let's suppose it contains "fred" or something like that -- you didn't say what was in it so we have to speculate. Next, you want to create an ArrayList from that? What does that mean? You want to end up with an ArrayList that contains one entry, that string? Or what?
    In your example I would want to start by giving the method "fred" as the name parameter. So right now the String (name) has the value of "fred". I then wanted to make an ArrayList for that student named fred. This ArrayList would have 4 grades for that student fred. This ArrayList for fred would be part of a HashSet for the whole group of students. That way when I wanted to search alphabetically, I would just sort the HashSet. My computer science teacher said this would work.
    Thanks

  • Getting rid of trailing space from a string variable

    I need to delete trailing blank spaces in a string variable. Is there a method that can do the job?
    Thanks

    String.trim(). Example: " booh! ".trim() returns "booh!".

  • How can I convert/read out from a string Hex (8-bit), the bit 0 length 1

    How can I convert/read out from Hex (8-bit), the bit 0 length 1 (string subset!!??) and convert it to decimal.
    With respect to one complement and two complement ?

    Just like Jeff, purely guessing here.
    It almost sounds like you just need to Read from Binary File?
    AND the 8-bit number with 1?
    Need more details.  What exactly do you have to start with?  What exactly are you trying to get out of it?  Examples help.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • Read text from a string control in a compiled LabView executable from C#

    I have a third party complied LabVIEW executable and no source code.  I need to read values from the front panel in C#.  I know that LabVIEW controls and indicators are not actual windows.  Is there a way to programmatically access this information(i.e. without using screenshots and OCR)?  I couldn't find this exact question answered in this forum.  I've read a few things about VI Server doing this from LabVIEW, but I don't think you can access VI Server from C#.  Any help would be appreciated.
    Thanks in advance.

    You should certainly be able to access VI Server from C#. LabVIEW has an ActiveX server built in that allows other applications to access a sizeable subset of VI Server functionality. I would guess you could access ActiveX servers directly from C#, but the worst-case scenario would be to wrap the ActiveX calls into a .NET assembly. I've seen this done before. This blog entry is slightly off topic, but might help you.
    Actually, I do need to revise this answer... If you are working with a LabVIEW DLL, the DLL would have to be compiled with the ActiveX Server option enabled. Otherwise, LabVIEW won't include the code that allows the DLL to be hooked into using this method. So if you don't have the source and you can't recompile it, you might be out of luck. Does the DLL really not have a function that exports this string value?
    Message Edited by Jarrod S. on 10-26-2006 01:39 PM
    Jarrod S.
    National Instruments

  • String variable - within parameters statement

    Hi,
    is it possible to define a string variable like:
       PARAMETERS: var_xxx type string,
    It doesnt works. Why?
    Thanks
    Markus

    HI,
         For patameters you can only use FIXED-LENGTH types' Since String is a data type of variable length you can not use it for declaring parameters. Both string and Xstring cannot be used as both are variable lengths. This only for releses before ERP 2005. From ERP 2005 onwards you can type using string but not using xstring.
    You can create your own type with 
    TYPES: param_type(200) type c.
    PARAMETERS: input type param_type.
    Regards,
    Sesh

  • How to open and read Excel Sheet from SharePoint 2013 Document Library using C# Visual Studio 2012

    Hi,
    To achieve these are the steps that I had followed :
    1. Add the document Library path into Central Admin -> Application Mgmt -> Manage Service App -> Excel Service App -> Trusted File Locations
    2. Add Documnet Library link to Trusted Connection Proivder
    3. Open Visual Studio as Run as Administrator
    4.Create an SharePoint 2013 Empty Project.
    5.Add Service Reference : http:\\<server>\_vti_bin/excelservice.asmx
    6.Service added successfully
    7.Create a class file and add the Service Reference namespace
    There is no such class as ExcelService to call. 
    Please let me know if somebody knows how to open the Excel file into C#(2012)  either using ExcelService or any other way to open. I tried old methods of Sharepoint 2010 server but it's not able to access classes.
    Requirement is :
    Need to read the excel sheet  from Document Library and transfer all data into DataTable.
    Please help asap. 

    Hi,
    This is the forum to discuss questions and feedback for Microsoft Office, I'll move your question to the SharePoint 2013 development forum
    http://social.msdn.microsoft.com/Forums/sharepoint/en-US/home?forum=sharepointdevelopment
    The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.
    George Zhao
    TechNet Community Support

  • Upgrade from SSRS 2008 to visual studio 2012/2013

    Hello,
    Is it possible to upgrade Visual Studio BIDS file/project types from 2008R2 to 2012/2013:
    SSRS *.sln
    SSIS * .dtsx
    *.dbproj
    If it is possible, can the resulting (upgraded) 2012/2013 file/projects be back-ended in 2008R2 SQL Server database engine?
    Or is it necessary to have the version of the back-end SQL Server database engine match the version of the VS BIDS projects?
    thanks,

    Microsoft Visual Studio 2010 does not support Business Intelligence Development Studio Integration Services, Report Services and Analysis Services projects for SQL Server 2008 and SQL Server 2008 R2.
    To work around this issue, you can install Visual Studio 2008 alongside Visual Studio 2010 on the same machine and then open the Business Intelligence Development Studio projects in Visual Studio 2008.
    (we have to follow side-by-side installation of SQL Server 2012 and SQL Server 2008. since you may have
    some issues with BIDS.)

  • How to store SQL sproc, scripts from Visual Studio 2012 in source control TFS?

    I have VS 2012, SQL Management 2012.  From VS 2012, how do I store my sproc and table scripts in TFS source control?

    Hi bthumber,
    Regarding TFS issues, I would like to recommend you post the question in the Visual Studio Team Foundation Server forums at
    https://social.msdn.microsoft.com/Forums/vstudio/en-US/home?category=vstfs
     . It is appropriate and more experts will assist you.
    Thanks,
    Lydia Zhang

Maybe you are looking for