I am looking for a free service that has a music streaming API. EchoNest is perfect and gives a simple XML result of URL's to audio files for a specific search. Except that lots of the links are dead. I think something like PlayMe.com is the answer but I am in South Africa and they limit IP's. I have also looked at 7Digital but it seems that you need to pay to stream. So is there a free service that will return me URL's for songs? There is no money involved in the application I am making and is non-commercial. Thanks.
Matt Cavanagh
Posts
-
Music Streaming API -
View download count on article filesThanks for the info! So there will be historical information, not just download counts from when this gets implemented?
-
View download count on article filesHey, is it possible to view the number of downloads that an attached file(like the source code) on an article has? It seems strange that you can view page view count but not that.
Strive to be humble enough to take advice, and confident enough to do something about it.
-
NHibernate CreateSqlQuery and addEntityThis seems like a stupidly simple request to me, but for some reason I cannot get it to work: The hibernate manual says this:
String sql = "SELECT ID as {c.id}, NAME as {c.name}, " + "BIRTHDATE as {c.birthDate}, MOTHER_ID as {c.mother}, {mother.*} " + "FROM CAT_LOG c, CAT_LOG m WHERE {c.mother} = c.ID"; List loggedCats = sess.createSQLQuery(sql) .addEntity("cat", Cat.class) .addEntity("mother", Cat.class).list()
Now, what I have is basically the same. I am return two of the same type per row. I am doing a select something like this:SELECT {ctrl1.*}, {ctrl2.*} FROM tableA AS A LEFT JOIN tableB AS ctrl1 ON (A.controlID = ctrl1.controlID AND ctrl1.controlOptionType = ? AND ctrl1.controlOptionValue = ?) LEFT JOIN tableB AS ctrl2 ON (A.controlID = ctrl2.controlID AND ctrl2.controlOptionType = ? AND ctrl2.controlOptionValue = ?)
And then IaddEntity("ctrl1", typeof(mycontrolclass)
andaddEntity("ctrl1", typeof(mycontrolclass)
Which seems exactly the same to me as their example. But I get this exception: "Could not execute query" and the inner exception is "Could not find specified column in results". If I copy the sql in the exception(to which it has added "AS ctrl1_1_3_3_" etc) it works fine. Thanks.Strive to be humble enough to take advice, and confident enough to do something about it.
-
Getting sessions to ASMX webserviceI have looked through that article, and have done everything up to the point about cookie containers. My webservice proxy has no such object, what am I missing? EDIT: Ok so I found that theres and attribute in the config file to enable the cookie container. But now my silverlight(which is what I am using to connect to the webservice) now gives this error: "CookieContainer is not supported when using a browser-based HTTP stack. Cookies will be automatically managed by the browser. To gain manual control over cookies, switch to a different HTTP stack, for example by using WebRequest.RegisterPrefix with WebRequestCreator.ClientHttp." But I don't think this has to do with Silverlight at all, or the cookiecontainer, because even that auto generated test page for the ASMX doesn't work.
Strive to be humble enough to take advice, and confident enough to do something about it.
modified on Wednesday, July 21, 2010 4:45 PM
-
Getting sessions to ASMX webserviceI have an ASMX webservice hosted alongside my ASP.NET web app. It is in the same project, hosted as the same IIS web application, and compiles to the same DLL. Now, I need to get the users session into the Webservice. To test this I made this simple method:
[WebMethod(EnableSession = true)]
public string checkSession()
{
return HttpContext.Current.Session["userid"].ToString();
}So, first I login to my web app, then in the browser goto my webservice and click "checkSession" on that auto generated test page. I have tested this on 3 computers. All 3 of those work fine with the webapp(so the sessions are being created etc), and 2 of those return the value of Session["userid"] on invoking the webmethod, however the last computer returns "Object reference not set to an instance of an object" because Session is null. So, whats the difference between these computers and why can my ASP.NET app get the sessions on all computers but the webservice cant? I have also tested with my cellphone and it works there too. Thanks:)
Strive to be humble enough to take advice, and confident enough to do something about it.
-
Uploading with WebClientHi. I have the code below which I am using to upload files to my ashx page. It works great, although I cant seem to find a proper way of getting how much it has transferred.
the calling code:
WebClient wc = new WebClient();
wc.OpenWriteCompleted += (s2, e2) =>
{
PushData(e2.Result, offset);
e2.Result.Close();
};
wc.OpenWriteAsync(ub.Uri);the push data code
private void PushData(Stream output, long offset)
{
byte[] buffer = new byte[4096];
int bytesRead;
bytesRead = theFileStream.Read(buffer, 0, buffer.Length);
if (bytesRead != 0)
{
output.Write(buffer, 0, bytesRead);totalBytesDone += bytesRead; FireUpdateEvent(bytesRead); } }
The above code is slightly different to my actual code, for brevity sake. Now, I had presumed that when it gets to output.Write(buffer,0,bytesRead); that that was the point where it sent the actual data and it would lock up and only goto the next line once its finished writing that section. But it goes on to totalBytesDone += bytesRead; before its written anything to the server. I presume the reason is that its doing the writing in a seperate thread in the background(or im actually looking at the wrong section of code and it writes somewhere else) - but for my totalBytesDone code to work i WANT it to lock up until its finished sending(i can put this all in a seperate thread later). Ive downloaded tons of examples for doing this and they either dont work properly with my ashx file handler(i cant change it) or they use a WebClient method that just reports on 50% progress. Please help, this is urgent. Thanks :)
Strive to be humble enough to take advice, and confident enough to do something about it.
-
Page Methods and ASCXThanks! Seems perfect.
Strive to be humble enough to take advice, and confident enough to do something about it.
-
Page Methods and ASCXHi. I have a situation where I need to use Page Methods instead of posts backs on an ASCX control. But I cant find a way that doesnt involve putting code in the main aspx page(which I cannot do due to specifics of the project). I also cannot create a web service. Basically each ascx control needs to be self containing and not call anything else. P.S. Update panels work for what I need, but are SLOW SLOW SLOW. Thanks
Strive to be humble enough to take advice, and confident enough to do something about it.
-
Fastest drawing with WinMo 6Hi, i want to develop a small game for windows mobile with C#. What is the fastest 2D drawing API? Im very used to XNA, so is there anything that I can use that's similar? I heard GDI is pretty slow. Thanks
Strive to be humble enough to take advice, and confident enough to do something about it.
-
How to download executable fileWell, you can set the URI straight to the exe to popup the download window. Therefore skipping the extra HTML page.
Strive to be humble enough to take advice, and confident enough to do something about it.
-
How to download executable fileMaybe im being silly but the simplest solution I can think of is to embed the silverlight in a HTML page which this javascript function: function redirect(url){ window.location=url; } and then call that JS from silverlight with "http://domain.com/file.exe".
Strive to be humble enough to take advice, and confident enough to do something about it.
-
Silverlight covering absolute DIVsHi. Any silverlight I put in my page cover's every other element on the page(even if that element is z-indexed to be in front). This only happens in IE. I remember having a similar problem with Flash but cant find a SL equivalent solution. Someone suggested setting Windowless to true. But that disabled the silverlight so you couldnt click in it. Thanks
Strive to be humble enough to take advice, and confident enough to do something about it.
-
Silverlight breaks when hiding it container with CSSI have this
But when I set display to block to show the div the silverlight box is just white, with no content loaded. Even if I set the div to block to start with(in which case the SL box works) then hide it and display it again, the SL still doesnt work. I need to be able to hide and show silverlight clientside. Thanks
Strive to be humble enough to take advice, and confident enough to do something about it.
-
ASP PageMethod not working :-/Thanks :D
Strive to be humble enough to take advice, and confident enough to do something about it.
-
website templateYou may want to check out Photoshops save for web feature in addition to "Slices". File -> Save for web. It will generate the HTML too if you want it to, and then you can modify it to suit your back end.
Strive to be humble enough to take advice, and confident enough to do something about it.
-
Is it free to use Google API for purposes like it's used in codeproject web site - Job BoardYes it is free for their map API. I think you are allowed a certain amount of views, after that you may have to pay for it.
Strive to be humble enough to take advice, and confident enough to do something about it.
-
ASP PageMethod not working :-/No, as I said, all the other ones on the page work. I set a onfail method and it results in "object [object]" ?
Strive to be humble enough to take advice, and confident enough to do something about it.
-
ASP PageMethod not working :-/All my AJAX using Page Methods is working except one which just never gets back to client side(but executes and returns fine on server). The only difference between this method and the previous ones is that this one returns a bit more data(all are strings btw). Ive tried making it return an array of sections of the string but it also never comes back. Please help, this is pretty urgent and its making me crazy :-/ Thank you
Strive to be humble enough to take advice, and confident enough to do something about it.
-
App too slow :-/Ive created a pretty big ASP.NET app which does financial calculations and the like. It worked fine all the way through development. What I failed to try during dev though was what would happen with more than one set of values. It breaks down to a treacle like speed. Now up till now, the dedicated server that I tested it on, ran it MUCH faster than running it in VS2008. But then it all changed, and now its slow as hell. Its a set of 5 AJAX update panels which each run according to what you press. Now as far as I can tell, the code is executing pretty speedily, but what slows it all down is the transfer of that to the client browser(maybe why it runs faster locally?). So, is it possible that every time one of my updatepanels(all set to conditional with children as triggers) is updating, that it is also resending all the data in the others? Thanks. P.S. I know this is very vague, but theres far too many factors to be able to post one block of code :-/
Strive to be humble enough to take advice, and confident enough to do something about it.