This is a migrated thread and some comments may be shown as answers.

how to set path to umageURL in serverside to radBinary?

1 Answer 53 Views
BinaryImage
This is a migrated thread and some comments may be shown as answers.
Abhi Shinde
Top achievements
Rank 1
Abhi Shinde asked on 03 Aug 2011, 04:02 PM
HI,

I am trying to bind image to radBinaryImage in serverside. but its not working.
Please refer my code.

string BefFileNAMe, AftFileName;
       if (e.Item.ItemType == RadListViewItemType.DataItem || e.Item.ItemType == RadListViewItemType.AlternatingItem)
       {
           RadBinaryImage imgBeforePhoto = (RadBinaryImage)e.Item.FindControl("imgBeforePhoto");
           imgBeforePhoto.ImageUrl = Server.MapPath("~/Image/5SLanding/Before/") + beforePhoto.FileName;
        }

It is giving following error in Chrome debugger.
Not allowed to load local resource: path/Image/5SLanding/Before/82before-5s.JPG
I cheked the path. The path is correct.
Please help me to solve this. 
Thanks

1 Answer, 1 is accepted

Sort by
0
Andrew Galea
Top achievements
Rank 1
answered on 22 Oct 2011, 06:39 PM
*deleted*
Tags
BinaryImage
Asked by
Abhi Shinde
Top achievements
Rank 1
Answers by
Andrew Galea
Top achievements
Rank 1
Share this question
or