public RtfImage addImageFromUrl(string url, string name, ImageFileType type) { if (!_allowImage) { throw new Exception("Image is not allowed."); } RtfImage block = new RtfImage(url, name, type); addBlock(block); return(block); }
/// <summary> /// Add an image to this container. /// </summary> /// <param name="imgFname">Filename of the image.</param> /// <param name="imgType">File type of the image.</param> /// <returns>Image being added.</returns> public RtfImage addImage(string imgFname, ImageFileType imgType) { if (!_allowImage) { throw new Exception("Image is not allowed."); } RtfImage block = new RtfImage(imgFname, imgType); addBlock(block); return(block); }
public RtfImage addImage(System.Drawing.Image ImageIn, ImageFileType imgType) { if (!_allowImage) { throw new Exception("Image is not allowed."); } RtfImage block = new RtfImage(ImageIn, imgType); addBlock(block); return(block); }
/// <summary> /// Add an image to this container. /// </summary> /// <param name="imgFname">Filename of the image.</param> /// <param name="imgType">File type of the image.</param> /// <returns>Image being added.</returns> public RtfImage addImage(string imgFname, ImageFileType imgType) { if (!_allowImage) { throw new Exception("Image is not allowed."); } RtfImage block = new RtfImage(imgFname, imgType); addBlock(block); return block; }