Can you use HTML formatting on a pulldata() response?

1521
10
09-26-2017 06:25 AM
Nicholas_Stokes
New Contributor II

I have a note field that returns the contact information for a person. Is there a way to use HTML formatting on this response? I'd like to have it centered with the label.

0 Kudos
10 Replies
by Anonymous User
Not applicable

It seems like you should just be able to add the "center" tag into the Header2 and that should take care of the centering when looking at your coding?

You have <H1><center> text blurb</H1><H2> text blurb</H2> and it seems like it should be <H1><center> text blurb</H1><H2><center>text blurb</H2>

This is just a guess and nice setup with the image in the background.

0 Kudos
Nicholas_Stokes
New Contributor II

Hi Mike, thanks for the suggestion. I tried formatting the HTML as you suggested, unfortunately it's still sending my pulldata() request to the left.

Updated HTML to:

 <b><H1><center>Welcome to the Eagle Ford South Meet & Greet!</b></H1></center><b><center><H2>Your Landman is :</b></center></H2>

0 Kudos
by Anonymous User
Not applicable

Nicholas,

I wonder if it has to do with the fact that you are not referencing the answer within the line of HTML code? I wonder if you tried to create a new "note" field that had a concat() function that would use the answer returned from the pulldata().

So, you would have a new note field that uses the answer to the pulldata() note. For sake of conversation, we'll call your original note "orig_note" and we will call the new note "new_note"

You would add in the "new_note" field that you can pass the returned value into and concatenate the value with the HTML string.

Something like this -

concat('<b><H1><center>Welcome to the Eagle Ford South Meet & Greet!</b></H1></center><b><center><H2>Your Landman is :'${old_note},'</b></center></H2>')

0 Kudos
JamesTedrick
Esri Esteemed Contributor

I believe Mike has something close to the right answer, though his function looks to have a small typo- a comma is needed to separate the first html text and the variable:

concat('<b><H1><center>Welcome to the Eagle Ford South Meet & Greet!</b></H1></center><b><center><H2>Your Landman is :',${old_note},'</b></center></H2>')

I also would suggest using a calculate or hidden field to get the initial pulldata function response, so that it's not visible on the form.  See the attached version (use a 31201 as a sample value)

by Anonymous User
Not applicable

James,

I tried the example with the value you referenced and this is what happens for me? Left justified still...I unzipped the folder into the users/username/ArcGIS/My Survey Designs/ 

0 Kudos
JamesTedrick
Esri Esteemed Contributor

Yes, it's still left justified in the form - I was testing on the web app.

0 Kudos
Nicholas_Stokes
New Contributor II

Thank you Mike and James for the suggestions.

James can you confirm that this isn't a functionality if you aren't using the web app? For this form I will not be utilizing the web app. If this functionality isn't available, is this something that could possibly be added in a future update?

0 Kudos
Nicholas_Stokes
New Contributor II
0 Kudos
JamesTedrick
Esri Esteemed Contributor

Hi Nicholas,

My apologies on the delay- yes, it's currently only in the webform with support.  I've filed an issue to see if it can be supported.