Search:
Namespaces
Discussions
.NET v1.1
Feedback
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
Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us
-
Terms of Use
-
Privacy Policy
-
www.dotnet247.com