Attaching Files to SmartObjects via InfoPath

  • 7 December 2007
  • 6 replies
  • 0 views

Badge +9
I have created a SmartObject that has a property of type 'File'.  I have bound this SmartObject to an InfoPath form, but the 'File' property shows up as two fields:  Name (Text), and Content (Picture?).  How do I bind a file attachment to these values?

6 replies

Badge +8

An infopath file attachment field can be directly tied to the content smartobject field.  The Name parameter is optional and in my tests will get populated with the file name when no value is supplied.


 I hope that helps.


-Eric

Badge +10
This is something that I have not tried.  Has anyone else done this?
Badge +8

It worked for me in my test but it was a very simple test.

Badge +9
I've been sidetracked, but I will revisit this shortly.  Ultimately all that I am trying to accomplish is to have a file as a part of the workflow, for example, the user starts a process that involves answering a few questions and attaching a file.  Then, their answers and the file attachment go to their supervisor who either approves or rejects their information.  Is using the InfoPath form as the container for the file with a smart object behind it the right way to go?  Do I even need a smart object field for this?
Badge +8

Sorry for the delayed reply.


 You wouldn't need to have a smartobject field for the file because you could just have the main infopath datasource hold the attachment and it will get passed to the approver.  If the file attachment is large and you don't want it stored as a part of the form then you could use a smartobject field to represent the attached file and only load it when necessary.


 -Eric

Badge +9
Yeah, that makes sense now.  Thanks!

Reply