[Solved] How to fetch data from a website in android app after entering his personal details during registration?

You can write a RESTful web service on your server which takes the arguments like (age,income,etc) and store these arguments to a new variable then use those variable when connecting the government’s website. After that you can use your government’s APIs if there are any, if not: you can write a web scraper for that … Read more

[Solved] Print index number of dictionary?

I think you have mixed up index numbers with keys. Dictionaries are formed like such: {key: value} data.keys() will return a list of keys. In your case: data.keys() [0,1,2] From there, you can call the first item, which is 0 (First item in a list is 0, and then progresses by one). data.keys()[0] 0 If … Read more

[Solved] which one is better? a javascript stored on the root file or the link directly to the js?

js/example.js is 14 bytes. http://example.com/example.js is 30 bytes. The difference will be smaller once gzip compression is applied in transport. The first one will be infinitesimally faster. Loading time should not be a factor in your decision to use an absolute or relative URI. 0 solved which one is better? a javascript stored on the … Read more

[Solved] How to delete dynamically created textbox in asp.net

You can remove textbox from your placeholder like below: protected void Remove(object sender, EventArgs e) { foreach (Control control in PlaceHolder1.Controls) { //Here you need to take ID from ViewState[“controlIdList”] if (control.ID == “TakeIDFromControlListsID”) { Controls.Remove(control); } } } 0 solved How to delete dynamically created textbox in asp.net

[Solved] SQL distinct query with whole record [closed]

I’m sure there are lots of ways of doing what you want. Try this: SELECT a.* FROM FGEHF_DB.dbo.Tbl_Alotee a JOIN ( SELECT MAX(ID) AS ID FROM FGEHF_DB.dbo.Tbl_Alotee WHERE Plot_Id = ‘4117’ — or other value GROUP BY alotee_name, alotee_fname, alotee_cnic ) b ON a.ID = b.ID I think we are getting closer now. 8 solved … Read more

[Solved] Recommendations for processing incoming data on a web server [closed]

As @cybermonkey said, you should communicate via HTTP POST. Http Post lets you send data (large bits of data), you can use the headers actively to determine response status etc. When using POST, I would recommend transporting the strings in JSON-format. JSON Allows you to serialize and deserialize objects, arrays and strings. Can be serialized … Read more

[Solved] Calculate the difference between two dates in hours:minutes:seconds?

Try this function:- //1 minute = 60 seconds //1 hour = 60 x 60 = 3600 //1 day = 3600 x 24 = 86400 public void printDifference(Date startDate, Date endDate){ //milliseconds long different = endDate.getTime() – startDate.getTime(); System.out.println(“startDate : ” + startDate); System.out.println(“endDate : “+ endDate); System.out.println(“different : ” + different); long secondsInMilli = 1000; … Read more

[Solved] printing data of specific element from array in java [duplicate]

Your implementation of Clip class is wrong. It should be something like this: public class Clip { private String title; private String author; public Clip(String title, String author) { this.title = title; this.author = author; } public String getTitle() { return title; } public void setTitle(String title) { this.title = title; } public String getAuthor() … Read more

[Solved] string return a substring possibly with .find() [closed]

Not sure what it is that is not compiling for you, but this is what you want: string over = yay.substr(yay.find(“over”),4); To break it down: yay.find(“over”) returns index of the first letter of “over” in ‘yay’, which is 16. yay.substr(16,4) extracts 4 characters from ‘yay’ starting at index 16. string over = yay.find(“over”); Does not … Read more

[Solved] perl + numeration word or parameter in file

It can be condensed to a one line perl script pretty easily, though I don’t particularly recommend it if you want readability: #!/usr/bin/perl s/(.*)=/$k{$1}++;”$1$k{$1}=”/e and print while <>; This version reads from a specified file, rather than using the command line: #!/usr/bin/perl open IN, “/tmp/file”; s/(.*)=/$k{$1}++;”$1$k{$1}=”/e and print while <IN>; 6 solved perl + numeration … Read more

[Solved] Javascript / Html Check box error [closed]

On line 68 of your code, you set y to be the number of questions the user asked for. y=document.getElementById(“myForm”).elements[0].value; This loop (starting on line 102) is where the error is coming from: for(var i=0; i<y; i++){ if(choices[i].checked){ choice = choices[i].value; } } Here’s what happens: If you ask for 4 questions, this loop will … Read more