Link to home
Start Free TrialLog in
Avatar of Rad1
Rad1

asked on

Html Editor inside ASP.Net Gridview

I have Gridview and I need to add HTML EDITOR to it such as Ajax Editor.  The Editor needs to replace the textBox that displays when I click on the Edit Gridview.  
The gridview has Edit, Delete, Select control.


I have used the below code to re size the Textbox that displays when I click on Edit, but I am unable to replace the TextBox with the Html Editor control.

Any idea to make it work?

Thank you!

 if ((e.Row.RowState & DataControlRowState.Edit) > 0)
            {
                // Comments
                AjaxControlToolkit.HTMLEditor.Editor comments =    (AjaxControlToolkit.HTMLEditor.Editor)e.Row.Cells[7].Controls[0];
                //comments.TextMode = AjaxControlToolkit.HTMLEditor.Editor.MultiLine;
                //comments.Height = 100;
                //comments.Width = 400;


                // Comments1
                TextBox comments1 = (TextBox)e.Row.Cells[8].Controls[0];
                comments1.TextMode = TextBoxMode.MultiLine;
                comments1.Height = 100;
                comments1.Width = 400;


                // Comments2
                TextBox comments2 = (TextBox)e.Row.Cells[9].Controls[0];
                comments2.TextMode = TextBoxMode.MultiLine;
                comments2.Height = 100;
                comments2.Width = 400;


            }
        }
Avatar of kblau
kblau

Are you putting the Ajax control in the aspx page?  Maybe try the free rich text box.
SOLUTION
Avatar of Ramkisan Jagtap
Ramkisan Jagtap
Flag of Finland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Rad1

ASKER

Hi,

I tried the links above but I could not get it to work.

Basically, I need a TextBox that will support link added to it such as www.yahoo.com
It does not have to be html Editor.

Any idea?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Rad1

ASKER

It has to be small and does it work?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Rad1

ASKER

Quest if anyone knows:
When I drag and drop the Ajax Editor in VS2010 to the page, nothing happens.
The editor control seams like nothing there?

Any idea?