I have progressed with the event code and I am gaining confidence in it. Now I am stuck with below.
I am able to read the component(if condition is working fine, the logs shows that it enters in the if code) with the following code:
if ((compPresentationCurrent.Component.Content["Thumbnail"] != null) &&
(compPresentationCurrent.Component.Content["Thumbnail"].Attributes[3].Value != string.Empty))
{
//The below two lines is throwing error as i do not know how to get the multimedia image
// attached to this component.
// I tried to convert to string and again to object but in vain
object objComponent = (object)compPresentationCurrent.Component
.Content["Thumbnail"].Attributes[3].Value;
Component tempComp = (Component)objComponent;
}
But I want to read the multimedia component attached to that component,
So my component
compPresentationCurrent.Component.Content["Thumbnail"]
has a image which is multimedia component and I want to read the image path and the image size and for the same. In tridion 2009 event code I did it like below:
//compCurrent is a type of Component, and is the main component which holds
//various multimedia components(i.e. images).
if ((compCurrent.Fields["thumbnail"] != null) &&
(compCurrent.Fields["thumbnail"].value.Count > 0))
{
Component component3 = (Component)compCurrent.Fields["thumbnail"].value[1];
string strthumbnailimagepath = publication.MultimediaURL + "/" +
this.GetImagePublishPath(component3.Multimedia.Filename,
component3.ID);
}
But in new event code it is throwing error.
Can anyone suggest how to do that. Also I am looking for TOm.NET API Documentation, I searched on google and got this link https://stackoverflow.com/questions/10585437/sdl-tridion-tom-net-documentation but no lucks as it is not showing the exact methods and ways to do in event code. Is there any .chm file as it was in TOM API?