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

ILoad Visibility Issue

1 Answer 114 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Anju
Top achievements
Rank 1
Anju asked on 03 Dec 2010, 10:06 AM
Sir,
          I have an issue with Rad-active I Load control.While uploading the image, it will display sometimes. Sometimes it won't display the image message and show a java script error in IE.The sample code for this application is shown below,


<script type="text/javascript">
                //<![CDATA[

    function ILoad1_ValueChanged(controlId, webImage) {
        
        if (webImage) {
            var resize = webImage.GetResizeByName("Image2");
            var str = "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" style=\"width:90px; height:90px;\"><tr><td align=\"center\" valign=\"middle\">";
            str += "<a href=\"javascript:void(0);\" onclick=\"Radactive.WebControls.ILoad.ShowImagePreview('<% =this.ILoad1.ClientID %>'); return false;\">";
            str += "<img src=\"" + resize.FileUrl_NoCache() + "\" alt=\"\" style=\"border:none;\" />";
            str += "</a>";
            str += "</td></tr></table>";
            document.getElementById("ILoad1_Image2").innerHTML = str;
            

        }
        else {
            var str = "<table border=\"1\" cellpadding=\"0\" cellspacing=\"0\" style=\"width:90px; height:90px;\"><tr><td align=\"center\" valign=\"middle\">";
            str += "<a href=\"javascript:void(0);\" onclick=\"Radactive.WebControls.ILoad.ShowImagePreview('<% =this.ILoad1.ClientID %>'); return false;\">";
            str += "<img src=\"../Images/CompanyLogo/noimage.jpg\"  height=\"110px\" width=\"90px\" alt=\"\" style=\"border:none;\" />";
            str += "</a>";
            str += "</td></tr></table>";   
            document.getElementById("ILoad1_Image2").innerHTML = str;
          }
    }

    var ILoad1_PageLoad_Done = false;
    var ILoad1_ControlInitialized_Done = false;
    function ILoad1_PageLoad() {
        if (ILoad1_PageLoad_Done) {
            return;
        }
        ILoad1_PageLoad_Done = true;

        var controlId = "<% =this.ILoad1.ClientID %>";
        ILoad1_ValueChanged(controlId, Radactive.WebControls.ILoad.GetValue(controlId));
    }
    function ILoad1_ControlInitialized(controlId, webImage) {
        ILoad1_ControlInitialized_Done = true;
   
        listenEvent(window, "load", ILoad1_PageLoad);
    }
                //]]>   
</script>
<script type="text/javascript">
                //<![CDATA[
    if (ILoad1_ControlInitialized_Done) {
        ILoad1_PageLoad();
    }
                //]]>   
</script>




The control creation is like this,


 <RAWCIL:ILoad ID="ILoad1" runat="server" Appearance="Button" ForeColor="#0C55B1"
                                    CssClass="button-new" Width="100px" Height="25px"><Configuration ManualTemporaryFolder="False"
                                    OnCompleteBehavior="KeepFilesInTemporaryFolder"
                                    WebPublishedDestinationFolder="True" CutMode="Manual" KeepSourceImage="False"
                                    GenerateIconImage="False" GenerateSelectedImage="True"
                                    GenerateIndexXMLFile="True" InternalCode="" Title="">
                                    <TemporaryFolder Path="" UrlMode="Automatic" ManualUrl=""></TemporaryFolder>
                            <DestinationFolder Path="" UrlMode="Automatic" ManualUrl=""></DestinationFolder>
                            <WebImageDefinitions>
                             <Radactive.WebControls.ILoad.Configuration.WebImageDefinition InternalCode="Default" Title="Default"><SizeConstraint Mode="FreeSize">
                             <FixedSizeData Size="400, 300"></FixedSizeData>
                             <FixedAspectRatioSizeData Size="400, 300" LimitedDimension="Width">
                               <Limits>
                                 <LowLimit Enabled="False" Value="300"></LowLimit>
                                 <HiLimit Enabled="False" Value="400"></HiLimit>
                               </Limits>
                             </FixedAspectRatioSizeData>
                             <FreeSizeData>
                               <LimitsW>
                                 <LowLimit Enabled="False" Value="300"></LowLimit>
                                 <HiLimit Enabled="False" Value="400"></HiLimit>
                               </LimitsW>
                               <LimitsH>
                                 <LowLimit Enabled="False" Value="300"></LowLimit>
                                 <HiLimit Enabled="False" Value="400"></HiLimit>
                               </LimitsH>
                             </FreeSizeData>
                             </SizeConstraint>
                             <OutputOptions FormatMode="Custom" Format="b96b3cae-0728-11d3-9d7b-0000f81ef32e" JPEGQuality="92" JPEGForceRecompression="False"></OutputOptions>
                             </Radactive.WebControls.ILoad.Configuration.WebImageDefinition></WebImageDefinitions><WindowsAppearance><ImageUploadWizardWindow WindowTitle="RADactive I-load" TopLogoImageUrl="" ShowWelcomePage="True" ShowSummaryPage="True" WelcomePageText="" ShowImagePreviewBeforeFileUpload="True" ShowSaveButtonDuringImageEdit="True" CropperCanvasColor="White" HTMLCropperCanvasColor="White" AutoZoomCropperView="True"></ImageUploadWizardWindow><PreviewWindow WindowTitle="RADactive I-load - Preview" AllowImageDownload="True" AllowImagePrint="True"></PreviewWindow></WindowsAppearance><InputOptions><UploadableFileSizeLimits><LowLimit Enabled="False" Value="1"></LowLimit><HiLimit Enabled="False" Value="2097152"></HiLimit></UploadableFileSizeLimits><SourceImageSizeLimitsW><LowLimit Enabled="False" Value="300"></LowLimit><HiLimit Enabled="False" Value="400"></HiLimit></SourceImageSizeLimitsW><SourceImageSizeLimitsH><LowLimit Enabled="False" Value="300"></LowLimit><HiLimit Enabled="False" Value="400"></HiLimit></SourceImageSizeLimitsH><FileExtensionValidator DefaultBehavior="AcceptAll" AcceptedFileExtensions="" NotAcceptedFileExtensions=""></FileExtensionValidator></InputOptions><ImageCropperOptions AllowImageResize="True" AllowImageZoom="True" AllowImageRotate="True" AllowImageFlip="True"></ImageCropperOptions></Configuration></RAWCIL:ILoad>            
                                       
                                        <div style="text-align:middle" id="ILoad1_Image2" class="ILoad_CustomAppearance_DivImage"
                                            onmouseover="this.className='homeimghover'" onmouseout="this.className='ILoad_CustomAppearance_DivImage'">
                                        </div>


The screen shot for the error message is attached below. Please reply ASAP.


Thanks in Advance
Anju S Chandran


1 Answer, 1 is accepted

Sort by
0
Kamen Bundev
Telerik team
answered on 04 Dec 2010, 09:14 AM
Hello Anju,

The RADactive I-Load control has nothing to do with RadControls for ASP.NET AJAX, you can check the RADactive srl website.

All the best,
Kamen Bundev
the Telerik team
Browse the vast support resources we have to jumpstart your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
General Discussions
Asked by
Anju
Top achievements
Rank 1
Answers by
Kamen Bundev
Telerik team
Share this question
or