.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

HTMLEditor: Add text to the current cursor position

Posted By:      Posted Date: September 28, 2010    Points: 0   Category :ASP.Net


i am currently using the HTMLEditor and i would like to add a text to the current cursor position in the Editor.

The reason is, i want to add replacement tags when selecting an item from a dropdownlist.


Is that possible at all with the editor component?


I am appreated for any help.


View Complete Post

More Related Resource Links

How to align text to top position on Ribbon buttons?

Hello SharePoint Experts, I have a custom masterpage which is derived from v4.master and it uses the default SP Foundation 2010 Ribbon. As you all know,the default Ribbon buttons such as New Document,Upload Document,Alert Me,etc, have text at the bottom below the icons. Ribbon buttons such as CheckOut,CheckIn,etc have their text aligned to the right of the icons. My requirement is to have all the text on Ribbon groups and buttons aligned to the top such that the image is below the text.(By default it is the other way round). I tried manipulating the CMDUI.XML file located at 14\TEMPLATE\GLOBAL but no use. I also tried overriding the Ribbon CSS(from COREV4.CSS) but it was of no use as well. Does anyone have inputs on how to get this done? Any help is appreciated. Thanks.Regards, Gautam Kaikini, MCTS WSS 3.0 Application Development.

Blurry text in WPF - current status?

Hi,   I was trying to find out if the blurry text I'm seeing in my WPF application could be due to something I'm doing wrong. But then I realized that other people's examples have it as well, and discovered several reported issues with blurry text rendering in WPF (all of them from some time ago) and I tried to find out whether a solution exists now. But I couldn't.   So, I guess this is the right place to ask: has this issue with blurry text rendering in WPF been addressed by now? Or do we really need to live with it (and hopefully our customers too)?   Although I noticed it right away, I never paid much attention to it because I thought "it's probably a setting somewhere", but so it seems not? Or has this changed?   Here at home, I'm on an "old" analog 19" monitor (1280x1024), and I tried all combinations of "smooth edges of screen fonts". It also shows on the Vista-based machine at the office with a 24" LCD screen.   What am I missing?   Koen   ---------- System specs: CPU: AMD XP 2400+ RAM memory: 1024 MB Graphics card: ASUS V9520 VS OS: Windows XP SP2 DirectX: 9.0c

Cursor Position not working on Form_Load

This is the only line of code in my Form_Load event and the cursor does not move to the submit button.I've tried to point it at other controls on the form and I get the same result...the cursor moves but to an area on the form (somewhat bottom left) where no control exits. System.Windows.Forms.   Cursor.Position = new Point(btnSubmit.Location.X, btnSubmit.Location.Y);Paul Reed

Move cursor position during drag drop operation



I know how to change to a custom cusor or visual instead of a standard cursor during drag and drop operations.  I know how to get the current mouse position during drag and drop methods (often there is a GetPosition method, or alternatively I can use p/invoke or System.Windows.Forms.Cursor.MousePosition getter).

My question is, how can I (or is it not possible) to change the mouse position programmatically during the drag/drop operation, ideally just before the drop occurs so that items are dropped at the point of the programmatically set cursor position? 

I tried to to use the System.Windows.Forms.Position setter and SetCursorPos both in the source's PreviewQueryContinueDrag handler and the target's PreviewDrop handler but neither affected the position of where the items were dropped.  In the case of PreviewQueryContinueDrag, the mouse visually moved to the programmatic location after the items were dropped, even though the PreviewQueryContinueDrag handler was called before the item was dropped (and before PreviewDrop).

Any ideas?



Move cursor position during drag drop operation



I'm enhancing the behaviour of out of the box WF designer drag/drop experience.  One of the things I'm trying to do (in part) is when a toolbox item is drag over an existing activity designer and then dropped, I want the toolbox item's activity to be dropped close to the activity designer on which it was to be dropped, but not directly on top of the designer.

To accomplish this, I detect when a drop operation is about to occur and then I attempt to move the cursor position next to the activity designer.  The problem I'm having is moving the cursor during the drop operation.  I've tried various ways to do this programmatically, but nothing seems to work.  Or, perhaps it is getting moved but then the workflow designer (and in particular the flowchart designer) does something special with mouse position or otherwise ignores it. 

I started out posting this question on the WPF forum, but now I'm beginning to wonder if perhaps there is something unique to  the WF/flowchart designer that's causing the mouse not to move (or to move back to the original position perhaps) rather than a general issue with moving the mouse during drag/drop operations.

Can anyone provide any guidance?



how to find any text in current page with java script like (CTRL + F) ie or firefox .



i have a page with datalist and more label

and i have an input text and a html button in my page.

i need a javaScript code for find text in my page like ( ctrl + f ) in ie or firefox . ?!


Pagelaod - fill in text box with current date


I want to fill in a text box with current date when the page is loading in the format of:



today is 11 October 2010

fill in as


Changing the cursor Position


Hello all,
On Image Click how to move the mousecursor position in web application???

In case of windows application on button_click i have written the following code:

Point p = new Point();
p.X = 41;
p.Y = 400;
Cursor.Position = p;

This works fine & cursors position also change.

but how to do that on aspx page or in web application?????

In my case on Image click i have to move the cursors position.

But I have to move the cursor with clienside script i.e Java Script . How to do that????
Any help
will be appreciated.

Thanks in advance,

Chandrakant Tale.

is there any way to know the position of my cursor - in TextBox control ?


i have in my C# (WinForms) program TextBox control

if i have this text in: `abcd efg hijklmnop`

and i stand with my cursor between `c` and `d`  = position 3

or i stand with my cursor between `h` and `i`  = position 10

how to get this position ?

thank's in advance

Set cursor position in TextBox


Im writing Custom control in asp.net

after AutoPostBack , one Textbox of Custom Control always is focused, but cursor position always is in the first position of TextBox

anything idea that make it at the right of the string in Textbox ?

Thanks a lot !

Accessing a text file in the current directory?


I want to distribute a text file with my WPF application. When the application starts the text file is automatically read in the loading event.

What I would like to do is to place this text file in the application directory. However using the click once installer the application is installed in a random directory that reads '\appData\localapp\....' I am not able to know in advance what the installation directory will be.  

What I would like to do is to be able to get the directory of where the ClickOnce application is placed? This way users can place the Clickonce files anywhere they want and I can also have the text file placed in the same directory Then when my application starts I can read the text file.



AutoCompleteStringCollection for text box in DataGridView 2.0

I have been searching for a way to have autocomplete in a DataGridTextBox
object. There does not appear to be an obvious way to do this like you would
for a TextBox outside of a grid using the AutoCompleteCustomSource. Any
thoughts on how I can add this collection? :)

Creating Sites/Lists/List Items under Current User Context in SharePoint By Using SPUserToken

Usually we do this by performing the action under RunWithElevatedPrivileges method and updating the listitem using SPListItem.SystemUpdate() method (see here). but this approach has its own flaws like (RunWithElevatedPrivileges will run under system account, we cannot use SystemUpdate for SPSite,SPWeb,SPList, since it runs under system we will "CreatedBy" by as SystemAccount).

Built-in Functions - Text and Image Functions in SQL Server

Text and image functions operate on TEXT, NTEXT and IMAGE data types. These data types are deprecated with SQL Server 2005 and should be replaced by VARCHAR(MAX), NVARCHAR(MAX) and VARBINARY(MAX) when possible. Alternatively you can also consider storing large string values using XML data type. Text and image functions are nondeterministic.

Future versions of SQL Server will not support TEXT, NTEXT and IMAGE data types. Columns with TEXT / NTEXT data type do not support commonly used string functions such as LEN, LEFT, RIGHT, etc. Furthermore, due to the large size of TEXT data you''re likely to see performance issues if you store such data in the database. However, at times you can''t help but use the TEXT / NTEXT / IMAGE data types (for example when supporting 3rd party databases when you cannot change the schema) - this is when text and image functions come in handy.

Cursor Functions

A cursor allows looping through a record set and performing a certain operation on each record within the set. SQL Server supports three functions that can help you while working with cursors: @@FETCH_STATUS, @@CURSOR_ROWS and CURSOR_STATUS. Cursor functions are non-deterministic.

Built-in Functions - Text and Image Functions

Text and image functions operate on TEXT, NTEXT and IMAGE data types. These data types are deprecated with SQL Server 2005 and should be replaced by VARCHAR(MAX), NVARCHAR(MAX) and VARBINARY(MAX) when possible. Alternatively you can also consider storing large string values using XML data type. Text and image functions are nondeterministic.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend