whitespace COMPANY whitespace SERVICES whitespace PRODUCTS whitespace PURCHASE whitespace SUPPORT whitespace CONTACTS whitespace Home whitespace Contact Us whitespace Site Map whitespace
whitespace
SUPPORT
whitespace
FORUM
whitespace
FAQS
whitespace
SUBSCRIPTION
whitespace
REQUEST ON-LINE
whitespace
whitespace

Technical Support Forum

Welcome Guest Search | Active Topics | Log In | Register

Image Uploader ;# characters in column data Options · View
oneilaus
#1 Posted : Wednesday, December 08, 2010 10:11:09 AM
Rank: Newbie

Groups: Registered

Joined: 12/8/2010
Posts: 2
Location: Australia
Hi There,

I am using the image uploader web part and have recently purchased it. I am using it in conjuction with the Expert News Rotator web part which formats announcement lists very nicely.

My problem is that the Image Uploader column formats the link to the image as ;#[linktoimagehere];#;#;#

Why does it do this?

I am trying to pass the link through to the Expert News web part so that it can display the image, but it tries to pass through those funny characters as well.

Is there any easy modification around this?

Thanks,
Chris.
Eugene
#2 Posted : Wednesday, December 08, 2010 2:05:15 PM
Rank: Guest

Groups:

Joined: 7/9/2009
Posts: 3,341
Hello,

We've analyzed Expert News Rotator web part and it seems to read link value in wrong way. It uses ToString() method of field value object which retrieves raw internal value used for DB storing, hence it is not supposed to be publicly used.

Proper way of retrieving the value is the following:

Code:
if (this.TheColumnType.ToString() != "HyperLink")
{
  // INSERT BLOCK START
  SPFieldUrlValue spValue = item[this.ThumbImageURLField] as SPFieldUrlValue;
  if (null != spValue && !string.IsNullOrEmpty( spValue.Url ))
  {
    imageThumbURL = spValue.Url;
  }
  else
  // INSERT BLOCK END
  if (item[this.ThumbImageURLField].ToString().Trim() != string.Empty)
  {
    imageThumbURL = item[this.ThumbImageURLField].ToString();
  }
  else
  {
    imageThumbURL = this.ImageThumbURL;
  }
}


So basically I would suggest you to forward this code (our changes are highlighted with comments) to authors of Expert News Rotator web part to fix their product. With above-mentioned changes images stored by Image Upload should display properly.
oneilaus
#3 Posted : Thursday, December 09, 2010 2:52:02 AM
Rank: Newbie

Groups: Registered

Joined: 12/8/2010
Posts: 2
Location: Australia
Great thanks for your speedy response.

I will contact the authors of the other web part.

Chris.
Users browsing this topic
Guest (3)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Company | Services | Practices | Technologies | Career | Contacts | Privacy
© 2005-2016 ArtfulBits. All rights reserved.