silverlight

Creating mp3 song previews in Silverlight /ASP.NET

Hi, what's the best way to create mp3 song preview from full mp3 song.Also I need to give the provisions for the user to choose the starting and ending point for the song. Is there any opensource API's for this? Or Is this be possible with silverlight,If so where should I start? Thank You. ...

Silverlight: Disable Button on validation error? (Trouble with validation)

I have a class in my SL4 app that represents a single entity the user is inputing data about. I am doing data validation as follows: private double cost; public string Cost { get { return String.Format("{0}{1}", DOLLAR_SYMBOL, cost); } set { string price = getPr...

Silverlight: Controls looking different in Visual Studio v. debugging

I have a text box that appears in a certain size and position in the Visual Studio Silverlight preview window. When I actually run the app, it appears to be much wider, and lower on the page. Why is this? (Sometimes I can fix the problem by deleting the control and making a new one like it, but it's frustrating.) This is the XAML: <Tex...

Silverlight: Validate as soon as user focuses on a text box?

I'm building a SL4 app. Currently, my validation works for the following scenario: User focuses on the text box User types invalid data User loses focus on the text box However, it does not work for this: User focuses on the text box, which already contains invalid data User loses focus on the text box How can I get validation to...

Does DataForm exist in Silverlight 4, or only in Silverlight 3?

Silverlight's DataForm seems great. I see a ton of documentation for it in SL3, but not so much in SL4. This tutorial is about SL4, but has way more XAML than I'd like to write, particularly given that DataForm is supposed to do all that for you. I've also been following along with this video, but he loses me when he references the Sys...

Layout in silverlight

I am running into a layout issue which I am not sure how to solve. Here is how my xaml looks like, <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="*" /> <ColumnDefinition Width="*" /> </Grid.ColumnDefinitions> <Grid x:Name="abc" Grid.Row="0" Grid.Column="0"> <Grid> <Grid.ColumnDe...

Silverlight: Debugging fails in three web browsers

I am working on a Silverlight 4 app that used to work fine. Now, when I press F5, the web browser fails to find it. In Chrome: This webpage is not available. The webpage at http://127.0.0.1:87/MySilverlightTestPage.aspx might be temporarily down or it may have moved permanently to a new web address. More information...

UploadStringAsync not working

Hello, I'm trying to send a POST request to a PHP script ("http://mywebsite/index/test/" in this case) once a button is clicked. I am using the WebClient's method UploadStringAsync for that but it doesn't seem to work: using System; using System.Collections.Generic; using System.Linq; using System.Net; using System.Windows; using System...

Is it reasonable to have both DomianService and Silverlight-enabled WCF Service

At the moment it seems that a RIA Domain Services class can not return a sinlge custom type. There are parts of my app that needs just that, so think the only way to get that is to call back to a simple silverlight-enabled WCF Service, which i beleive will not have a problem returning a custom type. I don't see where the Silverlight cl...

binding a textbox on gridfrom

I have a datagrid which is populated from a web service. I want to fill a form based on the selected item in the datagrid. This is what I use to set the DataContext (Which is a grid) private void PublisherSearchList_SelectionChanged(object sender, SelectionChangedEventArgs e) { this.PublisherItem.DataContext = (Publisher)Publis...

INotifyDataErrorInfo ArgumentOutOfRangeException when raising ErrorsChanged event

This is a wierd one and at this point I am thinking that it may have something to do with my machines configuration. Basically I have created a pretty standard implementation of INotifyDataErrorInfo and in certain circumstances, when raising the ErrorsChanged event I get an ArgumentOutOfRangeException. This exception doesn't contain muc...

async calls inside get accessor - is it good practice?

Hi! I have a window that shows customer infomation. when the window loads, I call LoadCustomer() method from the constructor which loads the customer information from the database asynchorously, which sets the CurrentCustomer property. and then the UI is updated because it is bound to the CurrentCustomer. private void LoadCustomer(...

Silverlight - How should I implement drag in canvas?

I am building a little app for the Windows Phone 7 (Silverlight 3) which allows the user to add objects to the screen and drag them around. My class is defined as the following: public class Frame { public double Height{ get; set; } public double Width { get; set; } public Uri Image { get; set; } pub...

Delay when calling wcf service from silverlight client

My silverlight client calls a web service that is hosted in IIS and using the basic http binding. Over the WAN there's an initial 60-200 ms delay before the response ( less than 20K) begins to come back. Why is that and what can be done to reduce the delay? The latency for ping between the client and the server is around 40 ms. ...

Selecting path to a folder in my computer (as in OpenFileDialog but without filename) in Silverlight 4

I have seen OpenFileDialog and SaveFileDialog in silverlight but, what if I required to select path of folder in my computer? Scenario: The user want to select path in the Computer which he can use for his files. For example there is a button (e.g. Select path to save your work button) which he will use to browse folder. When he is done...

Silverlight on ipad

Hi guys, What are the current possibilities to run silverlight on the iPad please ? Other than the video streaming MS demo of course. If there's no official packages or something, I'm interested in hacks too Thanks ...

Silverlight connectivity with database using ado.net

Hi All I want to connect my sql server 2005 database using ado.net in silverlight. I want to connect manually to my database. Please give me examples of populating gridview in silverlight manually. Thanks ...

Add deep zoom folder to VS2010 silverlight applciation

Hi, I have copied the deepzoom data created folder "Generated Images" into a folder named "temp" in my VS2010 web project, but I am unable to see the "Build" property of this ("temp") folder. While compilation, VS2010 shows an error "'Build Action' not set to 'Resource'" ...

Refresh the input text of an AutoCompleteBox

Hello, I have an AutoCompleteBox whose ValueMemberBinding uses a ValueConverter : ValueMemberBinding="{Binding Converter={StaticResource MyValueConverter}}" This ValueConverter uses a global property to convert the value. When I change this global property I'd like the AutoCompleteBox displayed strings to update accordingly. For ins...

binding two different transforms together in silverlight 4

Hi, I try to bind a translateTransform and a compositeTransform together in silverlight 4 in the code (c#). I can't do this in xaml because the UIelements are loaded dynamically. I just need the Xoffset. The compositeTransform is the source. I have the flowing code, but it doesn't work: TranslateTransform trans = new TranslateTransform...