Hello,
I have a need to reference the attachments data card in one of my formulas, but I can't figure out which syntax is correct, as none of them seem to work. Can someone please tell me how to proceed?
Thank you
Solved! Go to Solution.
@AuburnMist as i am not at my PC I can't verify what I think should work.
Try this
If(CountRows(Datacardvalue25_1.Attachments) = 0, Blank(), false)
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Thank you for continuing to work on this. When I thought I had it, I actually didn't!
I ended up with this, and it works perfectly.
If(IsBlank(DataCardValue1_1.Text)&(DataCardValue9_1.Text),(DataCardValue7_1.Selected.Value),(DataCardValue6_1.Selected.Value),(DataCardValue4_1.Selected.Value),(DataCardValue8_1.Selected.Value),(DataCardValue10_1.Text),Disabled,Edit) & If(CountRows(DataCardValue25_1.Attachments) = 0, Disabled, Edit)
@AuburnMist could you provide some more details. Where do you need to reference the datacard and whats the purpose?
@AuburnMist I am asking because datacardvalue25_1.Attachments is actually a Table. So you cant just reference this in Lets say a Label...
Definitely, let me elaborate further;
I am writing a formula in the DisplayMode function of my Submit button.
The Submit button must remain in Disable mode until such a time as all of the fields are filled in. When all the fields are filled in, the button becomes 'enabled' (Edit).
If(IsBlank(DataCardValue1_1.Text),(DataCardValue9_1.Text),(DataCardValue7_1.Selected.Value),(DataCardValue6_1.Selected.Value),(DataCardValue4_1.Selected.Value),(DataCardValue5_1.SelectedDate),(DataCardValue8_1.Selected.Value),(DataCardValue10_1.Text),Disable,Edit)
Please disregard. I found the problem!
I was using DataCardValue instead of ThisItem.
I rewrote the formula and for the attachments, I used ThisItem.Attachments, and my issue is gone.
Thank you
@AuburnMist as i am not at my PC I can't verify what I think should work.
Try this
If(CountRows(Datacardvalue25_1.Attachments) = 0, Blank(), false)
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
@AuburnMist Just had a look at your formular....This actually can't work...
@AuburnMist Please consider to change your formular to this pattern
If(Or(IsBlank(DataCardValue1.Text),IsBlank(DataCardValue5.Text)),Disable,Edit)
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Thank you for continuing to work on this. When I thought I had it, I actually didn't!
I ended up with this, and it works perfectly.
If(IsBlank(DataCardValue1_1.Text)&(DataCardValue9_1.Text),(DataCardValue7_1.Selected.Value),(DataCardValue6_1.Selected.Value),(DataCardValue4_1.Selected.Value),(DataCardValue8_1.Selected.Value),(DataCardValue10_1.Text),Disabled,Edit) & If(CountRows(DataCardValue25_1.Attachments) = 0, Disabled, Edit)
@AuburnMist I am really sorry to tell but your formular can't work
Plese have a look at the If Syntax: If( Condition1, ThenResult1 [, Condition2, ThenResult2, ... [ , DefaultResult ] ] )
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.