.NETGURU
Losing code in InitializeComponent() and Page Errors
Messages   Related Types
This message was discovered on ASPFriends.com 'aspngrichtextbox' list.


Adam Cohen
Hello,

I've experienced a few weird symptoms since I've incorporated the RTB control into my ASP.NET / C# project. The details follow. Any help would be appreciated.

1. Whenever I change the HTML in design view I lose code in the InitializeComponent() procedure. This is the procedure that typically ties controls to events, such as Page_Load. It took me over an hour to figure this out and since I have figured it out it's been very frustrating. Any clues on how to resolve this?

2. The pages with the control are functional / don't exhibit errors, but in the lower left of IE 6 the warning indicator (exclamation mark on yellow sign) appears. When I click on it, it informs me that there is a Syntax Error, Char: 4, and some line number which doesn't correspond to my code. I figure this must be in the controls code. Any ideas?

I don't have this problem with the Sample.aspx page. I registered the control by adding the license key in my Web.config as follows (with the appropriate value):

<appSettings>
<add key="RichTextBoxLicense" value="..." />
</appSettings>

The Web.config is in a subdirectory of the app. I am using Forms authentication on it.

Do I need to copy the bin directory to the subdirectory I'm in?

3. I too experienced the control scrolling the page to where it is placed. The way I found to pseudo fix this was to put the following code in the HTML before the closing body (</body>) tag in the HTML:

<script language="JavaScript">
scrollTo(0,0);
</script>

I don't like the scroll effect but it's better than having the page display where I put the RTB control.

Thanks in advance. I will be out of the office Friday - Saturday

Adam Cohen
Systems Developer / Web Master
City of North Las Vegas (http://www.CityOfNorthLasVegas.com)
Reply to this message...
 
    
Ollie Cornes

[Original message clipped]

This looks to be a Visual Studio .NET issue, so I'd suggest posting a
message to this list:
http://www.aspfriends.com/aspfriends/aspngvs.asp
I have seen code disappear in VS.NET a fair amount, but much less so
since the betas were replaced with v1.0. I don't think I've seen the
problem you are describing. Sorry :(

[Original message clipped]

It sounds like a script error in the page. Can you see what the error
text is and what the character is within that line? I'm not aware of any
problems with the control that cause script errors, but it may be the
control is failing to tolerate some script you have in the page. Do you
have any additional script in the page? If so, try removing it and see
if the problem still occurs.

[Original message clipped]

You just need the RichTextBox DLL in the bin folder in the root of the
web application. But if the control is appearing in the page, the
installation is working fine.

Ollie
--
http://www.richtextbox.com/
The no. 1 content editor for ASP.NET

Reply to this message...
 
 
System.Windows.Forms.RichTextBox




ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
Ad


Need Dot Net Interview Questions?
Ask ExamGuru, Inc. for advice and help on Passing .Net Interviews
.Net Projects
Best-of-breed application framework for .NET projects, developed by ExamGuru, Inc. and ExamGuru IT
Free .net Help
Commission ExamGuru, Inc. and his team for your next bespoke software project
FogBUGZ
The only bug tracking system carefully crafted with one goal in mind: helping teams create great software.
Awesome Tools
If you don't know about these, you're missing out... IT Certification Questions
IT Interview Questions
Free Oracle 10g Training
MCSE Boortcamp
Cisco Study Guides
Cheap Study Guides
Exact Questions
Dot Net Interview Questions
Oracle OCP
Cheap Travel
Designer Perfumes - Wholesale Prices
Free Programming Tutorials
 
ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
 Copyright © ExamGuru, Inc. 2001-2006
Contact Us - Terms of Use - Privacy Policy - www.dot-net-guru.com - www.examguru.net - www.oraclesource.net - www.itinterviews.net - www.examguru.net/ITCertification