.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

watermark in InkCanvas

Posted By:      Posted Date: September 26, 2010    Points: 0   Category :WPF


is there a way to get watermark text/image on inkCanvas?


View Complete Post

More Related Resource Links

watermark textbox using Ajax control

This is pretty simple compared to jquery. Since we need refer a dll only. we dont want any script for this. we just include that reference into our website.

probel in using ajax textbox watermark effect

Hi I have been trying to use ajax in my asp .net website developed in 3.5 sp1 2008! The problem is I can see tool kit controls in my tool box but i can not use the controls. like i was using the text box watermark effect but when i run the website the text-box does not show effect and there is no option in text box to add extender. there is only remove extender option. I have code:   <asp:ScriptManager ID="ScriptManager2" runat="server">                </asp:ScriptManager>        <asp:UpdatePanel ID="UpdatePanel1" runat="server">             <ContentTemplate>                                 First name:                 <asp:TextBox ID="TextBox1" CssClass="unwatermarked" Width="150" runat="server" />                 <ajaxToolkit:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender1" runat="server&

Watermark in MVC

I wants watermark text in the textbox field. But the datas are coming from viewmodel. I passed my data using value field, but its not work well. How can i set watermark text in MVC? give ur comments Please see my code as below ----------------------------------------------------------------------------- <div id="hformmn">                        <%= Html.TextBoxFor(model => model.FirstName, new {value="firsname", @class = "hcontifield",@title="firstname" })%>                        <%= Html.ValidationMessageFor(model => model.FirstName)%>                        <%= Html.TextBoxFor(model => model.LastName, new { value = "lastname", @class = "hcontifield", @title = "lastname" })%>                        <%= Html.ValidationMessageFor(model => model.LastName)%>         &nb

watermark disappears after lost focus - using asp.net ajaxcontroltookit

i am having trouble keeping the watermark on the textbox. its very first time when the page loads i see the watermark and if i focus the textbox and move away from textbox than the watermark disappears. how do i make sure that watermark is there after i lost focus from the textbox?<asp:TextBox ID="txtSubject" runat="server" Width="280px"  CausesValidation="false"></asp:TextBox>  <ajaxToolkit:TextBoxWatermarkExtender ID="TBWE1" runat="server" Enabled="true" TargetControlID="txtSubject"   WatermarkCssClass="watermark" WatermarkText="Find by Subject">  </ajaxToolkit:TextBoxWatermarkExtender>  

Date maskedEdit with watermark doesn't update on invalid date


I'm trying to use the TextBoxWatermarkExtender with MaskedEditExtender/Validator and have found a bug (I think).

In the textbox I enter an invalid date such as 55-55-5555 and exits the textbox. I would then expect the watermark to be shown, but it doesn't. Instead the prompchar is shown (like __-__-____).

If I simply give focus to the textbox and then another control, the watermark is shown.

Is there a workaround such as manually force the TextBoxWatermarkExtender to update.

I'm not the best with javascript, I tried to call focus() and blur() on the textbox in the textbox's onBlur event using window.setTimeout. This works in Firefox, but not IE8, also there has to be a better way I think :-)

            <asp:TextBox ID="TextBox5" runat="server" MaxLength="1" onBlur=""/>
            <asp:ImageButton ID="ImgBntCalc" runat="server" ImageUrl="~/images/Calendar_scheduleHS.png" CausesValidation="False" />

        <ajaxToolkit:TextBoxWatermarkExtender ID="TBWE2" run

Inkcanvas Recognizing and replacing shapes

Looking for some sample code or guidance for doing the following below. Thought this would be somewhat common.....

1) Using InkCanvas to allow drawing of shapes
2) Forcing the inkcanvas/inkanalyzer to limit its recognition to specific shapes (ellipses, circle, rectangle) 
3) Replacing the drawn and recognized shape strokes with a proper shape control that has a textbpx inside the shape

(Using 2010)


Gesture recognition on InkCanvas on XP



I'm currently developing a small app in WPF that requires gesture recognition, so I ended up using the InkCanvas. Everything works just fine on my desktop and laptop (running windows 7) but the app must run in another computer (an Asus Eee Top running windows XP). I've read that I had to install the Tablet PC SDK and the Tablet PC Recognition Pack, but I'm unable to install the Recognition pack because it complains about an unsuported OS: apparently it only suports XP up to Service pack 2, and I'm running SP3.

Are there any other alternatives?


InkCanvas Clipboard



I would like to know how to copy ink canvas element to clipboard?

Right now what my application can do is copy element to ink canvas itself.

Thanks in advance.:)

Watermark in mvc


Hi All,

I am new to Asp.net MVC. I want to show watermark in textboxfor where there is no data.

But I am not getting.

Please anybody help me

inkcanvas how to move all selectedobjects and strokes


I have a inkcanvas and some uielements and strokes are selected .


is it possible to move the full selection as it was a single objects?

Problem with selection in InkCanvas



I have following problem. When I use selection with pen (button on the side - Lenova x200 Tablet) inkCanvas does not changes mode to Select, so it added new stroke. With eraser I do not have that problem.

Can I switch mode by my self with some Events or something else...

Tnx in advance

InkCanvas MouseLeftButtonDown event not getting fired


Here I have a very simple problem... i.e i am trying to capure the mouse device with MouseLeftButtonDown event but it seems to be not getting fired...


    private void MyCanvas_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
      Start = e.MouseDevice.GetPosition(MyCanvas);


    <InkCanvas HorizontalAlignment="Stretch" VerticalAlignment="Stretch" 

this code is not getting fired please suggest.....

Prabhanjan Kumar Mahapatra

Adding dynamic watermark to SharePoint 2010 document when open? (on browser view)


hi all,

In Sharepoint 2010, how to adding dynamic watermark to word 2010 when opening?

I thinking,

may be just need configure in sharepoint 2010?

or need sharepoint develop?


What you guys think? Any thoughts are welcome!

Thank you!


Adding watermark or text to images on uploading or displaying


Is there a way to process images once uploaded to my asp.net site, to put a watermark or some text across the image to copyright the images? I would like to do this server-side if possible.

The other option I have discovered here (http://wpglamour.com/how-to-watermark-all-your-uploaded-images/) would be to store the images as they are on the server, but to manipulate the display so it appears the image is watermarked . However, this solution is in PHP. Does anyone know a good PHP to VB.NET translator?! Or does anyone have a good suggested link, idea or code? Or can I add PHP to my ASP.NET site?

watermark textbox



how can i create a watermark textbox?

i saw here a link that suppose to answer this question, but the link is not good...




Multithreading Dynamic Shape Drawing on InkCanvas?


note: Multithreading code adapted from here http://elegantcode.com/2009/07/03/wpf-multithreading-using-the-backgroundworker-and-reporting-the-progress-to-the-ui/


The Problem:  The line is not rendered consistently, only on the mouseleftup event.

Scenario: 1. Michael clicks the Line button on the toolbar

2. Michael brings the mouse over the ink canvas and clicks the left mouse button

3. While moving the mouse to the right to draw a line, he notices that nothing shows up.

4. On releasing the mouses left button, the line finally renders correctly.

I realize that i most likely need to multithread to accomplish this.

To begin i have  a basic WPF setup, menu bars, borders, toolbars, and i have an ink canvas. The goal of this project is to familiarize myself with image editing and drawing programs. I created a basic Line2D class.


 public class Line2D
  BackgroundWorker worker;

  MainWindow window;
  InkCanvas canvas;
  Line lineToBuild;
  public Line2D(InkCanvas curren

saving WPF inkCanvas to image makes black background



i am saving inkcanvas but it saves black image




rtb = new RenderTargetBitmap<

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