|
Silverlight is, as Pete said correctly, something like the Microsoft-Version of Flash. However, Microsoft has abandoned the technology, meaning that they are not going to support it for a long time. Therefore Silverlight should be left aside in favor of trqaditional Web technologies, as Javascript, HTML etc. are.
Source[^]
Veni, vidi, caecus
|
|
|
|
|
Apart from its just plugin it is used to create Rich UI, games and media based application on internet. It works at client side so there is lot saving of network bandwidth until you are not requesting any data to the server.
Mohit Dharmadhikari
|
|
|
|
|
Mohit Dharmadhikari wrote: It works at client side so there is lot saving of network bandwidth until you are not requesting any data to the server.
Wat, you imply the data is on the client - wrong, the UI and presentation code is on the client, the data is still requested from the server - but only the data.
I'm pretty sure there is some saving in bandwidth but I don't think it is a huge amount.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Please read it correct. I said it works on client side. Again it depends on where you store the data if its in database it may be in server. However we may save data in-memory collections as well which will be reside in client side. It totally depends on requirement.
|
|
|
|
|
Mohit Dharmadhikari wrote: However we may save data in-memory collections
And where does the data come from so you can save it in a local collection.
As I ONLY do LOB projects I may be missing something as ALL my data is stored in a database and has to be dragged out of the server.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
I am looking at building a very simple schedule display layout something like the telerik TV schedule[^]. Basically a row header with multiple textblock fields and 1 month on a grid display that show a max of 1 event per day per row (no scheduling required).
Both the ScheduleView and PivotGrid are way over the top for what I want to achieve, but between the templated row header and the dynamic date columns I can't decide which control to use.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Why not just use that one? Easier then writing your own. If I was bored and wanted to write my own...
The left two columns would each be an ItemsControl styled with a vertical font and some borders.
The top row would be another ItemsControl styled with the time and tick marks, etc.
The grid would be 2 ItemsControls... one for the rows that contains another ItemsControl for the columns.
I'd package the control to hide all that though from the developer.
I wouldn't really reuse any control besides the ItemsControl. Doesn't seem like there is much functionality that can be reused from other controls.
|
|
|
|
|
SledgeHammer01 wrote: Why not just use that one Both the controls are monsters for something very simple. I don't need the row and column grouping, the vertical text is not required just the data laid out in a similar structure.
I was going to "I have decided to create a model of objects (RowHeader object and 31 DateEvent objects), I can then bind that to a templated gridview."
SledgeHammer01 wrote: The grid would be 2 ItemsControls... one for the rows that contains another ItemsControl for the columns. However this idea got me to thinking more sensibly - thank you.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
how to use validations with in a textbox it should not allow me to enter a 11 value my requirment is it only should accept 10 digit number if i tryed to press 11 value it has to be show an error message
|
|
|
|
|
|
I want to make an windows 8.1 store app(can be desktop but prefer store).
I know the following languages :
visual basic 2012(win rt)(preferable)
visual c++( not so good at it)
i have to make the beta fast
PROGRAM:-
->a interactive full screen homepage with 3 buttons and settings in the charm bar
HOME PAGE buttons:-
->1st button: record screen: records the desktop and other win 8 apps with webcam support and audio from mic
->2nd button: Edit video: more like mixing. you can drag-drop video to timeline(like windows movie maker) and 2 channel audio(one for voice and one for song)
->3rd button: upload video: push the video to the web as mp4 or avi at youtube or facebook or save them to disk
VOICE RECOGNITION:-
(optional) at the home screen when user say some command like 'program run record' or 'program edit video', the program does the same.
i want some leads...i have no experience in intensive, professional programming but i want to do so.
i would really appreciate if you tell me what i have to do,
specifically:
things that are easy,
things that need some stress
and work on!
Thanks in advance
Sal
|
|
|
|
|
Please do not post the same question in multiple forums.
Veni, vidi, abiit domum
|
|
|
|
|
Hi,
I'm creating a carousel using a PathListBox.
Everything's working fine..if I use buttons (and Interaction.Behaviors)
<Window
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:ec="http://schemas.microsoft.com/expression/2010/controls" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:Expression_Samples_PathListBoxUtils="clr-namespace:Expression.Samples.PathListBoxUtils;assembly=Expression.Samples.PathListBoxUtils" mc:Ignorable="d"
x:Class="MainWindow"
x:Name="Window"
Title="MainWindow"
Width="800" Height="480" Background="#DC212C43">
<Window.Resources>
<Style x:Key="PathListBoxItemStyle1" TargetType="{x:Type ec:PathListBoxItem}">
<Setter Property="HorizontalContentAlignment" Value="Left"/>
<Setter Property="VerticalContentAlignment" Value="Top"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderThickness" Value="1"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ec:PathListBoxItem}">
<Grid Height="150" Width="200">
<VisualStateManager.VisualStateGroups>
<VisualStateGroup x:Name="CommonStates">
<VisualState x:Name="Normal"/>
<VisualState x:Name="MouseOver">
<Storyboard>
<DoubleAnimation Duration="0" To="0.35" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="fillColor"/>
</Storyboard>
</VisualState>
<VisualState x:Name="Disabled">
<Storyboard>
<DoubleAnimation Duration="0" To="0.55" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="contentPresenter"/>
</Storyboard>
</VisualState>
</VisualStateGroup>
<VisualStateGroup x:Name="SelectionStates">
<VisualState x:Name="Unselected"/>
<VisualState x:Name="Selected">
<Storyboard>
<DoubleAnimation Duration="0" To="0.75" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="fillColor2"/>
</Storyboard>
</VisualState>
</VisualStateGroup>
<VisualStateGroup x:Name="FocusStates">
<VisualState x:Name="Focused">
<Storyboard>
<ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisualElement">
<DiscreteObjectKeyFrame KeyTime="0">
<DiscreteObjectKeyFrame.Value>
<Visibility>Visible</Visibility>
</DiscreteObjectKeyFrame.Value>
</DiscreteObjectKeyFrame>
</ObjectAnimationUsingKeyFrames>
</Storyboard>
</VisualState>
<VisualState x:Name="Unfocused"/>
</VisualStateGroup>
</VisualStateManager.VisualStateGroups>
<Expression_Samples_PathListBoxUtils:PathListBoxItemTransformer d:LayoutOverrides="Width" IsCentered="True" OpacityRange="0.4,1" ScaleRange="0.4,1">
<Grid Background="{TemplateBinding Background}" RenderTransformOrigin="0.5,0.5" d:LayoutOverrides="Width" Margin="0,0,-51.113,0">
<Grid.RenderTransform>
<TransformGroup>
<ScaleTransform>
<ScaleTransform.ScaleY>
<Binding Path="IsArranged" RelativeSource="{RelativeSource TemplatedParent}">
<Binding.Converter>
<ec:IsArrangedToScaleConverter/>
</Binding.Converter>
</Binding>
</ScaleTransform.ScaleY>
<ScaleTransform.ScaleX>
<Binding Path="IsArranged" RelativeSource="{RelativeSource TemplatedParent}">
<Binding.Converter>
<ec:IsArrangedToScaleConverter/>
</Binding.Converter>
</Binding>
</ScaleTransform.ScaleX>
</ScaleTransform>
<SkewTransform/>
<RotateTransform Angle="{Binding OrientationAngle, RelativeSource={RelativeSource TemplatedParent}}"/>
<TranslateTransform/>
</TransformGroup>
</Grid.RenderTransform>
<Rectangle x:Name="fillColor" Fill="#FFBADDE9" I****TestVisible="False" Opacity="0" RadiusY="1" RadiusX="1"/>
<Rectangle x:Name="fillColor2" Fill="#FFBADDE9" I****TestVisible="False" Opacity="0" RadiusY="1" RadiusX="1"/>
<ContentPresenter x:Name="contentPresenter" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}"/>
<Rectangle x:Name="FocusVisualElement" RadiusY="1" RadiusX="1" Stroke="#FF6DBDD1" StrokeThickness="1" Visibility="Collapsed"/>
</Grid>
</Expression_Samples_PathListBoxUtils:PathListBoxItemTransformer>
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Window.Resources>
<Grid x:Name="LayoutRoot">
<ec:PathListBox x:Name="pathListBox" Height="100" Width="100" ItemContainerStyle="{DynamicResource PathListBoxItemStyle1}" WrapItems="True">
<ec:PathListBox.LayoutPaths>
<ec:LayoutPath SourceElement="{Binding ElementName=path2}" Distribution="Even"/>
</ec:PathListBox.LayoutPaths>
<i:Interaction.Behaviors>
<Expression_Samples_PathListBoxUtils:PathListBoxScrollBehavior Duration="0:0:0.2">
<i:Interaction.Triggers>
<i:EventTrigger SourceName="pathListBox" SourceObject="{Binding ElementName=button}" EventName="Click">
<i:InvokeCommandAction CommandName="DecrementCommand"/>
</i:EventTrigger>
<i:EventTrigger SourceName="pathListBox" SourceObject="{Binding ElementName=button1}" EventName="Click">
<i:InvokeCommandAction CommandName="IncrementCommand"/>
</i:EventTrigger>
</i:Interaction.Triggers>
</Expression_Samples_PathListBoxUtils:PathListBoxScrollBehavior>
</i:Interaction.Behaviors>
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle1" Width="200" Fill="Red" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle2" Width="200" Fill="RosyBrown" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle3" Width="200" Fill="RoyalBlue" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle4" Width="200" Fill="SaddleBrown" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle5" Width="200" Fill="Salmon" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle6" Width="200" Fill="SandyBrown" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle7" Width="200" Fill="SeaGreen" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle8" Width="200" Fill="SeaShell" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle9" Width="200" Fill="Sienna" />
<Rectangle Height="150" HorizontalAlignment="Left" Name="Rectangle10" Width="200" Fill="Silver" />
</ec:PathListBox>
<Path x:Name="path" Data="M17,235 L769.5,235" Fill="#FFF4F4F5" Height="1" Margin="50,0,50,206" Stretch="Fill" Stroke="Black" VerticalAlignment="Bottom" Visibility="Hidden"/>
<Button x:Name="button" Content="Button" HorizontalAlignment="Left" VerticalAlignment="Bottom" Width="75" Margin="8,0,0,8"/>
<Button x:Name="button1" Content="Button" HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="75" Margin="0,0,8,8"/>
<Path x:Name="path2" Data="M377.5,203.50107 C171,203.50107 62.499854,216.50111 49.5,234.5 12.021974,286.39003 192.5,320.50145 380.5,320.50145 568.5,320.50145 776.43383,291.2388 730.5,234.5 713.5,213.5011 584,203.50107 377.5,203.50107 z" Margin="44.524,203.5,46.047,120.5" Stretch="Fill" Stroke="Black" Visibility="Hidden"/>
</Grid>
</Window>
But I have to scroll the carousel by code!
So, I'm asking your help on:
1) Either, how to invoke the "Interaction.Triggers" by code
2) Or, how to implement (by code) a Storyboard to browse from 1 "pathListBox.StartItemIndex" to another (and therefore deleting all the "<i:interaction.behaviors>" code"
Thanks very much for your help!!
PS: you can copy/paste the code to test, it should work out of the box!
|
|
|
|
|
Test is observablecollection, i am binding controls in Test. It has 20 controls, all 20 controls are displaying vertical, i want to display it in 2 columns(10 controls for each columns).
<ItemsControl x:Name="itemsControl" Canvas.Left="{Binding SetPosition}" ItemsSource="{Binding Test}">
</ItemsControl>
|
|
|
|
|
Where's your Canvas.Top property? You're only setting the Left here.
|
|
|
|
|
|
Explain the issue clealy. And no one is going to click the link(which you have mentioned in your question). Screenshot could be better instead of that link.
Check this to leasn how to ask good questions
Some guidelines for posting questions in the forums[^]
thatrajaCode converters | Education Needed
No thanks, I am all stocked up. - Luc Pattyn
When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is - Henry Minute
|
|
|
|
|
Hi All,
I am about to look in to a project which was done my ex developer. The project is using wpf and entity frame work as webservice to get the data.
1.the app is used by users where they can just drag and drop the entity on the grid and play with it instead of writing SQL which users dont know.
2. The entities to drag are stored in a xml file
for eg: Customers , orders, OrderDetails
3. When the user drags the customer it creates the query at runtime and display the data (provided by entity fremawork which works as web service).
The queries gets created a run time in blocks for each section
eg: Select, where , group by.
I was wondering if anyone can provide a link to a project which has similar functionality done using more object oreiented way of coding. (XMLDocument, dependencyobject, backgroundworker )
Thanks in advance
|
|
|
|
|
|
|
WPF using MVVM...
I have posted similar questions before and honest;y I haven't always uinderstood the responses. Now I have a new requirement from my client and I have to revisit this.
Please see this screen shot[^]. On the right is a section of the Job Screen called Job Personnel with 6 combo boxes. The XAML for the Superintendant is shown also. Up till now, the combo box was populated from a list of employees filtered to only those that is IsSupervisor = true.
The new requirement is that this drop down, and all others that show employees, will be loaded based on the employee's position. An Employee's position is set in the Employee screen.
So, the app will now query all employees for a position code. Positions are stored in a lookup table with a code relevant to each position:
LookupCode SystemCode Caption
------------ --------------- ---------------------
empposition accountant Accountant
empposition fldsuper Field Superintendent
empposition foreman Foreman
empposition projectmanager Project Manager
empposition safetyofficer Safety Officer
I now need to add the button next to any combo showing Employees so that the user can pick ANY employee and assign him to the drop down. It's a way to temporarily override the position.
Please see this[^]
So, on load the combo will be loaded from the lookup table using the code. Then when the user picks a new employee via the dialog, that employee is added to the combo and its Id is assigned to the Job.SuperintendantId.
So far I can handle all of this. Here's where I get hung up...
I think that this should be done via a control. The control would have the label, a combo, and button. Somewhere I would set the code, probably in the XAML. ALso in the XAML the selected EmployeeId from the control would be exposed and bound to the appropriate field on the job, or whatever entity is using employees. By making this a control I can use it all over the app.
What I don't understand is how to create this. I'm guessing the selected Id needs to be a DP so I can bind to it. Can I do in XAML? I'm using MVVM. Do I create a view and VM and work with that?
I could use some direction. An example would be great.
Many thanks
If it's not broken, fix it until it is
|
|
|
|
|
Ok, so I finally got my control to work, but I still have one final question.
The DP's and other code for the control are in the control's code behind. I still need to pop open a dialog to allow the user to pick an employee. There is no VM. What's the right way to do this? Is it ok to open it from the control's code behind?
Thanks
If it's not broken, fix it until it is
|
|
|
|
|
If you need info from the user that is required and is simple, then yes, I think it is OK to open it from the code behind. Remember, the separation of concerns in MVVM is to support testing of the VMs and the models independent of the view. So if you need to pop an input box or a file dialog or something from the control's code-behind, then go ahead if that is what makes the most sense.
That being said... although I think it is OK to do if that is what it takes to solve the problem, I think you are taking out some technical debt if you do it this way. You may want to reconsider your whole approach a bit. Normally, you would want the view model to react to a change in state in the view. With a control in the view you would normally want it to react to a change in the properties on the VM it is bound to. So generally, you would enter a state whereby a new employee needs picked, the VM might open a window to get the selection from the user. Then you would validate that result (in the VM) and set the property on the VM that your control is bound to so it can display the information. Generally we try to keep the brains out of the controls because that complicates things and makes it harder to maintain. The control should basically be able to take some information and display it. Any logic more than that should generally be in the VM.
And as one last thought... does your control need to know anything about the backend data other than being bound to a collection of the available options? Meaning, is there any logic in the control to manipulate the backing data such that there is a dependency on the backing data? Or, in other words, do you have strongly-typed references to data objects in your code behind? If so, that is definitely wrong. (References to members as part of the data template in code or in xaml don't count)
HTH.
|
|
|
|
|
I want to set a RadProgess Bar With Timer on Methodload Plaese Suggest me to get a right answer
With Regards
Ram
|
|
|
|
|
As a start I would investigate the Telerik examples[^], they tend to supply a comprehensive set. If you don't get and indication of how to do the work then search for WPF/Silverlight progress bar in Code Project or Google.
I would create a timer and an integer property with onpropertychange, each time the timer ticks I would update the int property.
I would then bind the progress bar's progress value to the int property. I would also bind the visibility value to a boolean property set when I begin and end the timer.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|