Welcome Guest Search | Active Topics | Sign In | Register

Disable htmleditor Options
SpongeBert
Posted: Wednesday, August 26, 2009 5:27:39 PM
Rank: Member
Groups: Member

Joined: 8/25/2009
Posts: 10
Hi,

How can I disable the texteditor or make it readonly?

Kind regards
eo_support
Posted: Wednesday, August 26, 2009 7:30:00 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

There isn't any easy way to do that in the current version. However you can easily achieve similar result by using a Literal to display the content. For example, the following code would let user to see the editor and edit some text:

Code: C#
Editor1.Visible = true;
Editor1.Html = "some text";


The following code would let user to view the text only (thus not be able to edit):

Code: C#
Editor1.Visible = false;
Literal1.Visible = true;
Literal1.Text = "some text";


Here Literal1 is a standard ASP.NET Literal control. You can also put it inside a DIV so that you can put a border/size/scroll bars on it:

Code: HTML/ASPX
<div 
style="border: solid 1px gray; width:200px; height:100px; overflow: auto;">
    <asp:Literal runat="server" id="Literal1"></asp:Literal>
</div>


If you wish to disable the Editor directly, you will need to switch the Editor into preview mode. In the current version that can only be done by user clicking the "Preview" button. It can not be done through code. So it is not a valid option. In the future we may allow switching mode through code.

Hope this helps.

Thanks
Vinny
Posted: Monday, August 31, 2009 1:31:09 PM
Rank: Advanced Member
Groups: Member

Joined: 7/21/2008
Posts: 90
Hi,

Thanks for the udpate.
SpongeBert
Posted: Wednesday, September 9, 2009 1:36:48 PM
Rank: Member
Groups: Member

Joined: 8/25/2009
Posts: 10
Can you please send me a newsletter or mail or msg when this gets available. I need it.
The literal thing is too much effort for such a simple property...

Thanks. Keep up the good work
eo_support
Posted: Wednesday, September 9, 2009 1:40:48 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

We won't be able to keep a notifying list for each individual features, but if you subscribe to our announcements forum, you will be notified whenever we have a new release. See here for more details:

http://www.essentialobjects.com/forum/postst4_How-to-receive-notifications-when-a-new-post-is-added.aspx

Thanks!


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.