tag:blogger.com,1999:blog-6140199022860280334.post7094747915341766..comments2024-03-28T13:07:29.449+00:00Comments on Bob Buzzard Blog: Uploading Multiple Attachments via VisualforceBob Buzzardhttp://www.blogger.com/profile/07815472992351343395noreply@blogger.comBlogger43125tag:blogger.com,1999:blog-6140199022860280334.post-63831949313386348382019-04-02T12:27:08.848+01:002019-04-02T12:27:08.848+01:00Hi Bob,
This works perfectly. However my whole pa...Hi Bob,<br /><br />This works perfectly. However my whole page refreshes when I click "add more". Any idea how to solve this?Anonymoushttps://www.blogger.com/profile/14759272868270102893noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-8657435869251297382018-12-05T07:00:23.816+00:002018-12-05T07:00:23.816+00:00Hi bob,
Awsome work. One issue is that the previo...Hi bob,<br /><br />Awsome work. One issue is that the previously selected values gets lost once a new row is added . Anyway around to retain the prev selected values ?Mc Dhttps://www.blogger.com/profile/11428666993065751868noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-43594801873986519352018-09-15T15:17:56.299+01:002018-09-15T15:17:56.299+01:00Hi Bob,
Can't we get the file choosen already...Hi Bob,<br /><br />Can't we get the file choosen already when we click on add more?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-4731338465803093372018-09-11T07:50:40.638+01:002018-09-11T07:50:40.638+01:00Hi Bob , I hav eone question is there any way that...Hi Bob , I hav eone question is there any way that we can prevent page refresh becuase we lost all attachment once we click on Add More. Also , i know do not work with rerender so can you suggest me any workaround ?Anonymoushttps://www.blogger.com/profile/01706827314907816928noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-49305451614090433132018-09-11T07:16:31.253+01:002018-09-11T07:16:31.253+01:00HI , Where can i see the code. The functionality i...HI , Where can i see the code. The functionality is really helpful.Anonymoushttps://www.blogger.com/profile/01706827314907816928noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-64060914380081517222017-01-26T21:02:05.812+00:002017-01-26T21:02:05.812+00:00See this other post from Bob about how to handle t...See this other post from Bob about how to handle this (wasn't possible in 2012 but has been since advent of HTML 5): http://bobbuzzard.blogspot.com/2014/09/check-file-size-on-upload-in-visualforce.htmljimbeauxhttps://www.blogger.com/profile/09836430019054737189noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-4193053571047872662016-09-17T04:28:59.308+01:002016-09-17T04:28:59.308+01:00So Bob, forgive me, but I'm a newbie. If I wan...So Bob, forgive me, but I'm a newbie. If I want to attach the files to an account (integrating this VF page into the account detail page), how do I jigger the apex attribute description in the controller? Thanks!Danhttps://www.blogger.com/profile/11559341480743494756noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-40090962719197798052016-04-14T15:13:19.605+01:002016-04-14T15:13:19.605+01:00Awesome.. Works like a charm.. Thanks a lot for ur...Awesome.. Works like a charm.. Thanks a lot for ur post and for sharing ur knowledge.Harsha Vardhanhttps://www.blogger.com/profile/17051627127397327545noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-22764220120785634082016-04-14T15:10:26.314+01:002016-04-14T15:10:26.314+01:00Awesome.. Works like a charm.. Thanks a lot for ur...Awesome.. Works like a charm.. Thanks a lot for ur post and for sharing ur knowledge.Harsha Vardhanhttps://www.blogger.com/profile/17051627127397327545noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-64462730597581520842016-03-27T08:09:46.500+01:002016-03-27T08:09:46.500+01:00Thanks for this post! I always find your answers h...Thanks for this post! I always find your answers helpful when you comment on the issues I'm working on. If I google and I see your name on the results, I know I'm going to get an answer that works for me.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-32428458187054899472016-01-21T05:18:31.635+00:002016-01-21T05:18:31.635+00:00This is a very good post Bob, but my requirement i...This is a very good post Bob, but my requirement is to add multiple attachments on an Send Email Page. Here the Task Record is not saved and does not have the taskId with which I need to associate the attachments. Is there an easy way to reuse your scripts or how else can I invoke the attachment picker which allows to associated multiple attachments from a Send Email VF Page.amit shttps://www.blogger.com/profile/11913308174290431080noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-71352297560021379432016-01-21T05:17:13.245+00:002016-01-21T05:17:13.245+00:00This comment has been removed by the author.amit shttps://www.blogger.com/profile/11913308174290431080noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-82742122659378795352015-06-16T16:50:31.352+01:002015-06-16T16:50:31.352+01:00Thank you very much for this code. One issue is th...Thank you very much for this code. One issue is that the previously selected values gets lost once a new row is added . Anyway around to retain the prev selected values ? Shameer farookhttps://www.blogger.com/profile/15341195437646892661noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-58008993749970415832015-02-18T06:41:07.853+00:002015-02-18T06:41:07.853+00:00Have you tried to do this for salesforce classic?Have you tried to do this for salesforce classic?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-19502345136198201882014-10-28T11:06:10.941+00:002014-10-28T11:06:10.941+00:00i want similar output on the contact detail page
...i want similar output on the contact detail page <br />what should i do for it<br />what approach should i keep in my controller codingAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-27231471255378945022014-06-26T19:43:13.921+01:002014-06-26T19:43:13.921+01:00Whoops, the formatting for the vf component note d...Whoops, the formatting for the vf component note didn't take:<br />it needs to be a footer facet: apex:facet name="footer"Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-20246157824165817102014-06-26T19:39:03.608+01:002014-06-26T19:39:03.608+01:00Great tool! We were using a free one from the appe...Great tool! We were using a free one from the appexchange, but it's no longer supported by any browser, and was always sketchy on mobile devices.<br /><br />This one works great, especially since there's no java, flash or CSS.<br /><br />Here are a few things I had to do for my org:<br />1.) add a line to the vf component under the button commads so my users wouldn't kill me for not warning them: NOTE: If you need to upload more than 6 files, click "Add More" button before you start browsing for files; the action reloads the page and doesn't remember what you've already selected.<br /><br />2.) Separate the test class out, since in-line testing is no longer admitted. Don't forget to re-declare the static variable: public static final Integer NUM_ATTACHMENTS_TO_ADD=5;<br /><br />3.) Create a button to use on our Opp page (URL): /apex/MultiAttachment?id={!Opportunity.Id}<br /><br />Use the merge field picklist in the button creation page to replace opp id when adding to different objects.<br /><br />4.) Immediately add 5 browse fields upon loading: add "addMore()" to the method called when loading.<br /> public MultiAttachmentController()<br /> {<br /> // instantiate the list with a single attachment<br /> newAttachments=new List{new Attachment()};<br /> addMore();<br /> }<br /><br />If you do this, you'll need to update the test class:<br /><br />System.assertEquals(1, controller.newAttachments.size());<br />needs to be<br />System.assertEquals(6, controller.newAttachments.size());<br /><br />and<br /><br />System.assertEquals(1 + NUM_ATTACHMENTS_TO_ADD, controller.newAttachments.size());<br />needs to be<br />System.assertEquals(6 + NUM_ATTACHMENTS_TO_ADD, controller.newAttachments.size());Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-67876254106646926362014-05-13T20:09:42.992+01:002014-05-13T20:09:42.992+01:00Hey Bob, thanks for sharing this. How we attach th...Hey Bob, thanks for sharing this. How we attach the screenshots to a Standard object record during create since we do not have the ParentID yet? Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-28825716451870953072014-01-17T14:53:05.642+00:002014-01-17T14:53:05.642+00:00Did you get the solution to your issue I also have...Did you get the solution to your issue I also have multiple record on the same vf page and have to attach user defined files to upload to each record.Please let me know.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-59139294003086014192014-01-03T08:01:58.403+00:002014-01-03T08:01:58.403+00:00Custom objects are no different to standard object...Custom objects are no different to standard objects with regard to attachments. The attachment records simply need the id of the custom object as their parentid.Bob Buzzardhttps://www.blogger.com/profile/07815472992351343395noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-72018416367735428812014-01-03T08:00:59.415+00:002014-01-03T08:00:59.415+00:00There's a link at the bottom of the post to th...There's a link at the bottom of the post to the Visualforce, apex and unit tests.Bob Buzzardhttps://www.blogger.com/profile/07815472992351343395noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-18406073254278851652014-01-03T07:30:43.106+00:002014-01-03T07:30:43.106+00:00hi bob can u provide code for about screen shot my...hi bob can u provide code for about screen shot my mail id:sreenathyadavcloud@gmail.comAnonymoushttps://www.blogger.com/profile/01455036420619293767noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-16972039351686503372013-12-12T20:51:08.252+00:002013-12-12T20:51:08.252+00:00hi bob great job...I want how to upload multiple a...hi bob great job...I want how to upload multiple attachments into customobjectAnonymoushttps://www.blogger.com/profile/13692177342451210571noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-57699203882600830902013-11-28T08:43:27.076+00:002013-11-28T08:43:27.076+00:00You can download it from the link in the post.You can download it from the link in the post.Bob Buzzardhttps://www.blogger.com/profile/07815472992351343395noreply@blogger.comtag:blogger.com,1999:blog-6140199022860280334.post-5780240590129151832013-11-28T06:02:29.854+00:002013-11-28T06:02:29.854+00:00Hi can you send the code for Uploading Multiple At...Hi can you send the code for Uploading Multiple Attachments via VisualforceVijayhttps://www.blogger.com/profile/09056286952348644693noreply@blogger.com