Not applicable

Cannot use hyperlink field in variable

I'm using workflow online to send an email that contains a link to a document.  This link to a document exists as a hyperlink field in my list.  I've tried including this field value in the email body, setting a string variable as the field value, and setting a hyperlink variable as the field value.  I even tried doing a lookup to the list item instead of using Current Item. No matter what, I get this error message

System.InvalidCastException: The value 'd/results(0)/Link_x0020_To_x0020_Document' cannot be read as type 'String'. at Microsoft.Activities.GetDynamicValueProperty`1

The only format option I have when reading this field value is String, it does not give me other options (such as hyperlink).  No matter what variable type I create, the only option is String and the error is always the same.  Is there a workaround so that I can include this hyperlink in an email?

0 Kudos
Reply
5 Replies
Not applicable

Re: Cannot use hyperlink field in variable

Clint,

Can you please confirm the type of column by sending us a screenshot of the column configuration?

Regards,

Andrew Beals

0 Kudos
Reply
Not applicable

Re: Cannot use hyperlink field in variable

LinkToDocument.gif

Reply
Not applicable

Re: Cannot use hyperlink field in variable

Clint,

Thanks for doing that - I have been able to reproduce this issue. Would you mind creating a case with support asking it to be assign to me? I am currently chasing this issue internally and would like to add your case to the report.

Cheers,

Andrew Beals

Reply
eharris04
Workflow Hero

Re: Cannot use hyperlink field in variable

I don't have much to contribute but was able to reproduce the issue as well.  Andrew thanks for taking this one on.. Glad to have awesome support working the community site.

Reply
sjferguson
Nintex Newbie

Re: Cannot use hyperlink field in variable

Thought I'd throw this in even though it's been open for a while - have you tried the lookup using a collection variable to hold the result and then referencing that variable in a build string? (could be an extraneous : though). That has parsed through uncast data for me before without throwing a tantrum.

I found this by emailing myself the collection variable when testing a workflow a while ago

0 Kudos
Reply