Welcome to WebmasterWorld Guest from 54.156.90.21

Forum Moderators: ocean10000

Message Too Old, No Replies

invalid property assignment error

     
7:34 pm on Jan 24, 2011 (gmt 0)

Junior Member

5+ Year Member

joined:Sept 11, 2009
posts: 108
votes: 0


Hi All,
I'm getting an "invalid property assignment error" on this small piece of code:

<%=RsNews(RTrim,10("story")) %>

Can anyone see my error?
4:53 am on Jan 25, 2011 (gmt 0)

Full Member

10+ Year Member

joined:May 14, 2001
posts:262
votes: 0


You probably mean:
<%=RTrim(RsNews("story")) %>

But I don't know what you are trying to do with the ",10"
9:25 am on Jan 29, 2011 (gmt 0)

New User

5+ Year Member

joined:Jan 29, 2011
posts: 2
votes: 0


I'm taking a stab and saying that KRM probably means


<%= mid(RsNews("story"),1,10) %>


It would help if you told us exactly what you're looking to do.;) The code I provided you returns only the first ten characters of RsNews("story").
11:31 am on Jan 29, 2011 (gmt 0)

Junior Member

5+ Year Member

joined:Sept 11, 2009
posts: 108
votes: 0



Hi guys,
Thanks for the replies. It was actually <%= Left(RsNews("storydetails"),100) %> I was looking for to return the first 100 characters of the field. Is that the correct statement?

Thanks :)
11:59 am on Jan 29, 2011 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member

joined:May 24, 2002
posts:894
votes: 0


That is the correct statement
1:47 pm on Jan 29, 2011 (gmt 0)

New User

5+ Year Member

joined:Jan 29, 2011
posts: 2
votes: 0


Yup...that's correct.

The function that I mentioned in my previous post does a fairly similar function. It will return the characters between your start index and length....so to accomplish the same thing you did, you'd use:


<%= Mid(RsNews("storydetails"),1,100)%>