Hello,
I am a computer science Student Second year ,and i know good deal about c++,Data Structure, File Structure,OOP etc.
I decided to learn java i have read couple of books but i know u need practice to master any Programming language so i wonder if anyone could give me the assignments"only the questions not the solution" so that i could solve them as i am getting bored of "hello world"s and "3+2=5"s kinda stuff
thanks,
~HW
Hai,
After inclunde the library in php.ini .I try to create a project in dos window by typing like C:\wamp\www\Zend\binzf.bat create project quickstart i got a error message:"
'"php.exe"' is not recognized as an internal or external command,
operable program or batch file."
this is the error message please help me??how it was occured and a solution
For the example below:
if a == 100:
# Five lines of code
elif a == 200:
# Five lines of code
Five lines of code is common and repeating how can I avoid it?
I know about putting it a function
or
if a == 100 or a == 200:
# Five lines of code
if a == 100:
# Do something
elif a == 200:
# Do something
Any other cleaner solution?
I am working with USB device on Windows that is seen as a virtual serial port. I can communicate with the device using CreateFile and ReadFile functions, but in some cases my application does not call CloseHandle (when my application in development crashes). After that all calls to CreateFile fail (ERROR_ACCESS_DENIED), and the only solution is to log in to my computer again. Is there any way to force closing the open handle (or reopening) programmatically?
I'm developing a ASP.NET MVC app and I'm wondering which is the best way to handle an expired .NET Forms authentication cookie detected during an ajax call.
Do you think that packing the ajax response into a JsonResult containing info about the cookie validity is the best solution?
How can I replace a string with another string, within a given text file. Do I just loop through readline() and run the replacement while saving out to a new file? Or is there a better way?
I'm thinking that I could read the whole thing into memory, but I'm looking for a more elegant solution...
Thanks in advance
When use entity framework for DAL tier, VS 2010 can create edmx for each database.
Question:
If I have a database with many tables, should I create only one edmx for all tables or mutiple edmx files? for example, maybe all security tables for one edmx file, other tables for another edmx file. If there is more than one, then in other tiers, there will have more then on ObjectContext in code for business logic.
Which one it the best solutionfor this case?
Ugh, I can't believe I have to ask this, but where can I find previous versions of the ant manual (http://ant.apache.org/manual/index.html)? That page says, "Please use the documentation appropriate to your current version" but I can't find anything other than the current version (1.8.0) on the Web site - I had to resort to using archive.org to find the old version (which I would consider a hack, not a clean solution)...
I have stored a bulk of objects in an ArrayList and I have set that in the request. Now I want to retrive the values in the Arraylist from my java script. Please help me with the solution
on my asp.net page i am linking 2 css files which are used by 2 different controls but the main problem is that one class name is same in both so they are conflicting with each other, please tell me how can i distinguish between them.
Both are of jquery, 1 is slider control and another one is time picker control. and they are conflicting on their background image as i want to change background image of slider control's scroller. Please give me solution..
I am programming a process monitoring tool which is written in C++, windows application. Is there anyway to send out alert email when the tool find the process go down? Any library support this? or any solution is fine. Thanks.
I am trying to read dataSource ad Catalog from connectionString in web.config in Silverlight business project. Unfortunately when I used "SqlConnectionStringBuilder", I could not read connectionstring the has "connectionString="metadata=res:///MainDatabase.Main.csdl|res:///MainDatabase.Main.ssdl|......."" where as it work for
"connectionString="Data Source=My-PC\SQL_2008;Initial Catalog =...."".
I could get them using "Split" however, I don't like that solution. Is there any way to get my requirements?
Thanks
Good day chaps.
I'm interested in learning how to invert (make a negative of) an image using the python image libary module.
I cannot however, use the ImageOps function 'invert.' I need another solution, using the RGB values. I've searched and tried to no avail. Thanks for any help :)
I'm looking for a way to host a web UI in a windows service so that I can configure and control it within a browser. I'd like a simple and lightweight solution, and I don't want to use IIS.
I could probably hand-roll most of it but I was wondering if there was something already made to ease the process.
Hey everybody,
Im trying to write a quick console app that outputs data to an HTML file, however im having trouble accessing the System.Web.UI namespace.
Adding System.Web to my references places a warning icon on top of the reference name in the solution explorer and System.Web is not available in the .NET reference list (in order for me to actually add it to the project I have to go to the object browser and add it from there).
Anybody have any ideas about what I could be missing?
Thanks alot people!
I am looking for a method of reading emails using Pop3 in C# 2.0. Currently, I am using code found in CodeProject. However, this solution is less than ideal. The biggest problem is that it doesn't support emails written in unicode.
I'm doing some experiments with jquery n widths for a liquid column and I'm not sure why it isn't working on firefox.
It works fine on IE6,7,8 Chrome, Opera(sluggish).
I found some articles about firefox not recognizing the .resize attribute but no explanation/solution =\
$(document).ready(function(){
$(midCol).width((window,$(window).width()) - 470)
$(window).resize(function(){$(midCol).width((window,$(window).width()) - 470)
})
});
These questions are a kind of game, and I did not find the solutionfor them.
It is possible to write ::: in Cpp without using "" or anything like this and the compiler will accept it. (macro-s are prohibited too)
And the same is true for C# too, but in C#, you have to write ???.
I think Cpp will use the :: scope operator and C# will use '? :' , but I do not know the answers to them.
Any idea?
I have a very simple application. There is a refresh button, everytime it is being clicked, the adapter will call notifyDataSetChanged() to update a ListView. However, I got IllegalStateException all the time. Any quick solution? Thanks.
I have an Excel worksheet where the user enters certain data, which I want to store in a text file and upload to a server using FTP. One site suggested adding a reference to "Microsoft Internet Transfer Control" and then define an "Inet" object to do the FTP. However, I am unable to find a reference with this name in "Tools - References" in the VB Editor. Does anyone know of a solutionfor this problem? Thanks in advance.
I was using the Fiddler core .Net library as a local proxy to record the user activity in web. However I ended up with a problem which seems dirty to solve. I have a web browser say Google Chrome, and the user opened like 10 different tabs each with different web URLs. The problem is that the proxy records all the HTTP session initiated by each pages separately, causing me to figure out using my intelligence the tab which the corresponding HTTP session belonged to. I understand that this is because of the stateless nature of HTTP protocol. However I am just wondering is there an easy way to do this? I ended up with below c# code for that in Fiddler. Still its not a reliable solution due to the heuristics.
This is a modification of the sample project bundled with Fiddler core for .NET 4. Basically what it does is filtering HTTP sessions initiated in last few seconds to find the first request or switching to another page made by the same tab in browser. It almost works, but not seems to be a universal solution.
Fiddler.FiddlerApplication.AfterSessionComplete += delegate(Fiddler.Session oS)
{
//exclude other HTTP methods
if (oS.oRequest.headers.HTTPMethod == "GET" || oS.oRequest.headers.HTTPMethod == "POST")
//exclude other HTTP Status codes
if (oS.oResponse.headers.HTTPResponseStatus == "200 OK" || oS.oResponse.headers.HTTPResponseStatus == "304 Not Modified")
{
//exclude other MIME responses (allow only text/html)
var accept = oS.oRequest.headers.FindAll("Accept");
if (accept != null)
{
if(accept.Count>0)
if (accept[0].Value.Contains("text/html"))
{
//exclude AJAX
if (!oS.oRequest.headers.Exists("X-Requested-With"))
{
//find the referer for this request
var referer = oS.oRequest.headers.FindAll("Referer");
//if no referer then assume this as a new request and display the same
if(referer!=null)
{
//if no referer then assume this as a new request and display the same
if (referer.Count > 0)
{
//lock the sessions
Monitor.Enter(oAllSessions);
//filter further using the response
if (oS.oResponse.MIMEType == string.Empty || oS.oResponse.MIMEType == "text/html")
//get all previous sessions with the same process ID this session request
if(oAllSessions.FindAll(a=>a.LocalProcessID == oS.LocalProcessID)
//get all previous sessions within last second (assuming the new tab opened initiated multiple sessions other than parent)
.FindAll(z => (z.Timers.ClientBeginRequest > oS.Timers.ClientBeginRequest.AddSeconds(-1)))
//get all previous sessions that belongs to the same port of the current session
.FindAll(b=>b.port == oS.port ).FindAll(c=>c.clientIP ==oS.clientIP)
//get all previus sessions with the same referrer URL of the current session
.FindAll(y => referer[0].Value.Equals(y.fullUrl))
//get all previous sessions with the same host name of the current session
.FindAll(m=>m.hostname==oS.hostname).Count==0 ) //if count ==0 that means this is the parent request
Console.WriteLine(oS.fullUrl);
//unlock sessions
Monitor.Exit(oAllSessions);
}
else
Console.WriteLine(oS.fullUrl);
}
else
Console.WriteLine(oS.fullUrl);
Console.WriteLine();
}
}
}
}
};
Is anyone out there working with SOAP on Ruby 1.9? Rackspace has email addresses for $2/month and an api to programmatically create/destroy accounts which looks like the best I've found.
Fusemail has $2 addresses too but you need a minimum of 80 to get access to the api.
So, I either need to find a solution to working with Rackspace or a different email host.
Using .Net (C#), how can you work with USB devices?
How can you detect USB events (connections/disconnections) and how do you communicate with devices (read/write).
Is there a native .Net solution to do this?