Zum Hauptinhalt gehen

Municipal Addresses - Part 2

Kommentare

7 Kommentare

  • John Nerge
    Usually the trick to using the Combo Box output is to use the .ToString() command to convert the Object to a String.

     

    Any chance you can post your workflow xaml here? It'll be easier to troubleshoot if we can play around with it.
    0
  • Permanently deleted user
    Hi John,

     

    Thanks for your response.  Forgive my "newb-iness", but what is the best way to post in the forum?

     

    g
    0
  • John Nerge
    Great question. If your workflow is short enough, you can just open the xaml in a text editor and paste it directly. But these posts have a character limit, so that doesn't always work. 

     

    I prefer to store my workflows in a Google Drive folder (GitHub and other sites where you can store code are fine, too):

     

    https://drive.google.com/open?id=0B_hHHiqcTKMfWUYybFN0UG1CNXM

     

    Posting them this way also makes it easier for me to find workflows I've posted vs. having to search my past posts.

     

    I save my workflows as .txt files so that if someone downloads and opens them they don't try to execute. Instead you can just open a text editor, paste the code in, and save the new file as a .xaml and voila, new workflow.
    0
  • John Nerge

    Ah, okay, so you're using the syntax of the Where Clause used in the Display Form. But for Query Task, you should use a regular SQL query format.

     

    So if you're trying to select the record where the street name and number match, here's what your Query Task Where Clouse should look like using your output arguments from the Display Form:

     

    "Street_Nam = '" & resultStreetName & "' AND " & "Street_Num = '" & resultMuniNumber & "'"

     

    So if your user used the street name Main St, and the number 100, that Where Clause would calculate to:

     

    Street_Nam = 'Main St' AND Street_Num = '100'
    0
  • Permanently deleted user

    Hi John,

     

    Thanks for breaking down the QueryTask Clause for me.  I am still running into a compiler error (screenshot below).

     

    Is this error occuring because the resultMuniNumber variable has been defined as an Object and needs to be convert to a string before it can be included in the Clause?

     

    Thanks again for you assitance and patience.

     

    Gary

     

    _img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=907f2000000g05e&feoid=Body&refid=0EMf2000000kCyP" _/_img_
    0
  • John Nerge
    Whoops, my bad, forgot to include the .ToString() in the sample I posted. Here's the corrected version:

     

    "Street_Nam = '" & resultStreetName & "' AND " & "Street_Num = '" & resultMuniNumber.ToString() & "'"
    0
  • Permanently deleted user
    Hi John,

     

    Looks like that did the trick!  Thanks for all your help.

     

    Gary
    0

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.