|
An ellipse doesn't have a click event.
Here's the closest example I can think of, using the MouseLeftButtonDown event:
<Grid Width="200" Height="200" Background="White" >
<Ellipse Width="100" Height="100" Stroke="SteelBlue" StrokeThickness="4" Fill="Aquamarine" MouseLeftButtonDown="Ellipse_MouseLeftButtonDown" >
<Ellipse.RenderTransform>
<TranslateTransform x:Name="EllipseTranslateTransform" />
</Ellipse.RenderTransform>
</Ellipse>
</Grid>
private void Ellipse_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
{
EllipseTranslateTransform.X = 30;
EllipseTranslateTransform.Y = 30;
}
What are you trying to do?
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Do you experience sound echo problems when running in full screen mode? I get this in both Firefox and IE. If so, is there a workaround?
Kevin
|
|
|
|
|
No problems with echos either in window or full screen mode on channel 9 videos...have you tried checking your sound card control panel for weirdness?...I know soundblaster has this 'what U hear' thing that uses the speaker out as a recording input.
|
|
|
|
|
I only get this with Silverlight, not with other video types. I haven't checked out Silverlight videos outside Channel9 recently to see whether it's a general problem.
Kevin
|
|
|
|
|
I only keep my system on plain jane stereo...maybe you have it set for 5.1/7.1 surround or something?
|
|
|
|
|
No problems experienced here.
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I do encounter it but only when I am on RDP. If I run the video on my host machine, it runs perfectly.
Regards,
My Blog
My Articles
Computers are incredibly fast, accurate, and stupid; humans are incredibly slow, inaccurate and brilliant; together they are powerful beyond imagination. - Albert Einstein
|
|
|
|
|
Hi .
I've created an UserControl, then I've added its DLL file to my references.
When I've pressed F5 it works, but I can't see the Design of my WPF APP in VS2008 SP1.
The following errors have occurred :
Error 1
Assembly 'CustomToolTip' was not found.
Verify that you are not missing an assembly reference.
Also, verify that your project and all referenced assemblies have been built.
D:\My works\C#\tooltip\WpfApplication1\WpfApplication1\Window1.xaml
4 21 WpfApplication1
Error 2
The type 'myToolTip:UserControl1' was not found.
Verify that you are not missing an assembly reference and that all
referenced assemblies have been built.
D:\My works\C#\tooltip\WpfApplication1\WpfApplication1\Window1.xaml
21 10 WpfApplication1
By the way, I've tried Blend2 , with it I can see the Design of my App without any problems.
this is my App XAML code :
<Window x:Class="WpfApplication1.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:myToolTip="clr-namespace:CustomToolTip;assembly=CustomToolTip"
Title="Window1" Height="600" Width="800">
<Grid x:Name="rootGrid" RenderTransformOrigin="0.5,0.5">
<Grid.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="1" ScaleY="1"/>
<SkewTransform AngleX="0" AngleY="0"/>
<RotateTransform Angle="0"/>
<TranslateTransform x:Name="rootGridXY" X="0" Y="0"/>
</TransformGroup>
</Grid.RenderTransform>
<Rectangle Margin="26,34,496,374" Name="rectangle1" Stroke="Black"
Fill="Coral" MouseLeave="rectangle_MouseLeave" MouseMove="rectangle_MouseMove" />
<Rectangle Fill="Lavender" Margin="537,29,53,376" Name="rectangle2"
Stroke="Black" MouseMove="rectangle_MouseMove" MouseLeave="rectangle_MouseLeave" />
<Rectangle Fill="Peru" Margin="192,391,186,37.995" Name="rectangle3"
Stroke="Black" MouseMove="rectangle_MouseMove" MouseLeave="rectangle_MouseLeave" />
<myToolTip:UserControl1 UserControlTextBlockToolTip="Some texts"
UserControlToolTipTitle="Title"
Visibility="Hidden"
x:Name="customToolTip" />
</Grid>
</Window>
Could you guide me ?
Thank you
|
|
|
|
|
|
I have been looking over WPF lately as I am trying to make the decision if I am going to move in that direction and away from standard Windows Forms stuff. It seems to get me some very nice control rendering (where before I used to have to use owner draw junk) and the binding is looking far better than standard data binding...
The only thing that is starting to get to me, after looking over every video tutorial I can find and a ton of blogs (I have not bought a book YET but plan to soon) I am seeing a ton of repetitive markup in the xaml with respect to creating styles, templates, and other stuff that really looks to me like it belongs in a project wide scope similar to that of a CSS.
Is there a context for this? I have to assume there is... I get the feeling that you would be able to put the project wide stuff into the application.xaml file?
I can't wait to get a break from my last class work to try this stuff out...
|
|
|
|
|
You can put your application wide resources into a ResourceDictionary. You then link to the resource dictionary in like this (assuming you're placing it in App.xaml:
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary Source="MyResourceDictionary.xaml" />
</ResourceDictionary>
</Application.Resources>
|
|
|
|
|
|
hi friends,
I've an user control in WPF. It looks like an image in 2-Dimensional (ex. a washer). i want to know how to change that control like a 3-Dimensional image control and that should be rotatable if we scroll with scroll bars.
can any one help me out in this?
Thanks & Regards,
-Ravi
|
|
|
|
|
As I explained when I answered to you the last time you asked this question[^], you can't convert a 2D image into a 3D image in WPF automatically. You need to convert the model into a 3D mesh using a 3D tool. You can get Blender[^] for free, and this outputs to XAML.
|
|
|
|
|
but to work on blender we need a guide.it's somewhat difficult to work with out guide
|
|
|
|
|
ravi.vellanky wrote: but to work on blender we need a guide.it's somewhat difficult to work with out guide
And there are tutorials on the site. Bottom line - if you're not working on an image that can be height mapped, you need to :
a. get a copy of the software and invest the time in learning it
b. hire somebody to do it for you
or
c. buy a prebuilt model
There are plenty of blender tutorials scattered all over the web, so there should be something to help you there.
|
|
|
|
|
HI all,
kindly i ask you the right way how allocate/distribute a Wpf application on more computer and connect to the server...i try to make me understand ,i will develop a software(app.exe) in Wpf with Linq toSql and Sql Server ,after develop it i will install the software on about 10 computers that of consequence would connect to the server to Add,Edit,Delete data and etc.etc. sincerely i don't know how work out/handle this step... i have not idea ,
i tried to search some information but maybe i wrong the subject of the research so i'm here to ask some useful advice to help my research ...if you need more details as me i will answer as soon as possible.
Thanks
Have a fun.
Bye
|
|
|
|
|
One way to do this would be to set this up to use ClickOnce[^] as the install mechanism.
|
|
|
|
|
HI Pete,
how are you?
I tried ClickOnce for create a file.exe of the software and to install it in another computer,meantime i get on my computer the server with Database(both computer are connect in Lan) i could install the application correctly but when i use the it to see or save a record it got stuck with an error that couldn't connect to the server.
Now i get a doubt where i must set up the option to allow the client app to connect to the server ???
or the error is caused from another source???
I read the topic on MSDN about ClickOnce but i did not see about how set up the server and so on...
However thanks a lot for your support
Have a fun
Bye
|
|
|
|
|
I'm fine thanks. How are you?
ascotravel wrote: I tried ClickOnce for create a file.exe of the software and to install it in another computer,meantime i get on my computer the server with Database(both computer are connect in Lan) i could install the application correctly but when i use the it to see or save a record it got stuck with an error that couldn't connect to the server.
Could you post the exact error message that you get?
Pete
|
|
|
|
|
Hi Pete,
me too fine ,
I'm not in office now ,because i installed that application in the computer in the office ,within few hours i will come back to the office (to work too) and i will post the error.
I forget to tell you the same software that i create with ClickOnce after i installed it on my laptop and it is right i can add,delete,edit new records and navigate without error that's because i have installed on my laptop also the server of database???.
Have a fun.
BYE
|
|
|
|
|
HI Pete,
here is morning and i begin to work ,
i post the error that you asked me :
"A network-related or instance-specific error occurred while establishing a connection to Sql Server..."
In the software there is a file app.config with the string to connect to the SqlServer :
< ?xml version="1.0" encoding="utf-8"? >
< configuration >
< configSections >
< /configSections- >
< connectionStrings >
< add name="Card3D.Properties.Settings._3DCardConnectionString"
connectionString="Data Source=CHICHI\ERUSYAKO;Initial Catalog=3DCard;Integrated Security=True"
providerName="System.Data.SqlClient" />
< /connectionStrings >
< /configuration >
SqlServer stay on my laptop and both computer are connect in Lan(Intranet)...
maybe i wrong in this step that follow during the creation of the file.exe with ClikcOnce :
How will users install the application?
There are 3 option
1 - From a Website.
2 - From a UNC path or file share
3 - From a CD-ROM or DVD-ROM .
I choose the number 3 ....that 's right or not?
I hope my details can help you to understand where i wrong
However i wish you happy health.
Bye
modified on Thursday, January 22, 2009 8:35 PM
|
|
|
|
|
Try the steps in this[^] post. Let me know if this doesn't resolve your issue.
ascotravel wrote: How will users install the application?
There are 3 option
1 - From a Website.
When we supply applications for general use, this is what we do.
ascotravel wrote: 2 - From a UNC path or file share
That's the one we tend to go with for client site installs. That way, your users can get access to the application with the minimum of hassle.
|
|
|
|
|
Good Morning Pete,
I will follow your way ,now i read carefully the link above
and i will let you know the result..
Thanks
Bye
|
|
|
|
|
I'm back right,
i followed carefully that link and i set up my SQLServer with the same parameters of the link...
I have Vista on my laptop instead on the client computer there is Windows XP servive pack 2 (maybe that can help you )..
I Create one more file.exe with CLickOnce but i go the same error.
What i must do now?
Thanks!!!
Bye
|
|
|
|