64,152 Solved Topics
Remove Filter ![]() | |
One question: How do i differentiate when a page is refreshed event from a page/browser closed event? Because it seems that the onbeforeunload event is triggered when a page is refreshed and when it's closed, and i didnt want that to happen ? ![]() | |
Hi, On google Chrome there is an event when someone closes the window that merely asks if you really want to leave ONLY. What i wanted was to know if there is a way in jquery or javascript that enables the logout code to be run on chrome,(or any other … ![]() | |
I used to use a tutorial for windows console API, but the website was taken down :(. So now I need to ask how to do these things (which ALL were included on the website) in the console with windows API: * Mouse events (clicks and unclicks) * Cursor seeking … | |
hi, i am a complete newbie on software development onlt a couple of weeks, currently working through a manual and one of the chapter challenges is to create a number guess game in a GUI enviroment. been trying to look for tips on the web to no avail. i am … | |
I just downloaded netbeans and when I went to start a C++ project I was told that Netbeans couldn't find a C++ compiler. When I use to play around witt MS Visual C++ I never ran into a problem like this, Can anyone tell me what's up and what I … | |
please am new into programming and i was given a project to create a premier league table using C can any 1 help me thanks a lot | |
I'm developing wp7 app . i have a problem with this cod i want to get values of table from a webservice and show it in msg box the problem is i have two tables in a web service but in foreach only the first value can shown in two … | |
I'm getting a null pointer exception pointing to the line containing [COLOR="Green"]dispatcher.forward(request,response); [/COLOR] Any suggestions as to where i have gone wrong. it wud be of gr8 help... thanks in advance:)[CODE] ArrayList empList =EmployeeDao.getEmpDetail();//this is defined already request.setAttribute("empList",empList); RequestDispatcher disp = request.getRequestDispatcher("/myPage.jsp") disp.forward(request,response);[/CODE] [CODE] ArrayList employeeList=null; ArrayList employeeList=(ArrayList)request.getAttribute("empList"); if(!employeeList.isEmpty()) { … | |
public static void main(String[] args) { Set<Point> points = new HashSet<Point>(); points.add(); --- how to add point of "Point" type cureAlgor(0.01, 3,points); } Point is a pre-defined class. I want to know what to wrtie in points.add(). Please help! | |
Hi my codes works fine.When i key in ,for example, asdf 546,(f and 5 is separated by space), the programe rightly take it as invalid input ,however it takes asdf and 546 as separate type and return two "Invalid input".See below. I hav no clue why it does that oher … | |
Hi ive made a code does the following: 1. user makes a list of items 2. user adds more items to the list 3. list is displayed it uses Linked-Lists. here is the code #include <iostream> using namespace std; struct vote { char product[10]; vote *votePtr; }; void addNodes(vote *&startPtr,vote … | |
I have a C++ console project in Code::Blocks and I have set breakpoints to test an error. I have set the build for the project to produce debugging symbols for the debug build. I built it, then when I hit debug it just ignored my breakpoints and skipped to the … | |
Hi i came up with the following code for my Assignment.It works.What i dont understand was the following code, the rest of the code i did myself. if ( value == 1 ) smallest = randomNum; Why do i need to assign value to 1? Rest of my codes System.out.println("How … | |
Hi I have a single search field ' agent_name' in a form which is a dropdown field of data based on the concatonation of 2 fields: reg_fname and reg_lname When I do the SELECT Query though I'm getting a bit mixed up..... The data from reg_fname & reg_lname does not … | |
//PROGRAM TO FIND DERIVATIVE(FIRST AND SECOND)OF POLYNOMIAL FUNCTIONS #include<iostream.h> #include<conio.h> void main() { int i,d,coeff[100],degree[100]; clrscr(); cout<<"\nEnter the degree of the polynomial : "; cin>>d; for(i=d;i>=0;i--) { if(i>1) { degree[i]=i; cout<<"\nEnter the coefficient of x^"<<degree[i]<<" (with sign) : "; cin>>coeff[i]; } else if(i==1) { degree[i]=i; cout<<"\nEnter the coefficient of x … | |
Hi. Sorry for this kind of post in this forum.. But i am in serious trouble and need help. My 6th semester of B.E (computer science) will end on 28th-may-2012 (final exams going on now ) And after that i need to do a major training of 45 days . … | |
I hav this code here that prompt me for only 1 randomNum.I know i need a second loop.how can i go about doing it public static void main(String[] args) { int ii=0; int value; int randomNum; System.out.println("How many integers shall we compare? (Enter a positive integer):"); ii = input.nextInt(); randomNum … | |
Hi, I would like to know how to set a character set once and permanently, since when i alter the character_set% variables that are shown on 'show varables like 'character_set%', when i alter them the next day they are back with the old values? Thank you very much | |
matrix operation please help me coding this in c++: - Inverse matrices. - Calculate matrix determinant. - Set a row or a column of the matrix to a certain value. - Calculate performance (time and memory taken by each algorithm). | |
hi im currently learning about linked list. Ive created a code which is supposed to let you type some numbers, then display them. i did this mostly by using information on the internet(code examples) and such. Hence there are obvious mistakes a bits i do not understand. Here is my … | |
Greetings guys i just want to ask on how to update the gridview at runtime. I set the AutoGenerateColumn to true but nothing happens. I appriciate every idea. Thanks in advance. | |
Hi, I make two tables, one of them named operator, used to enter the mobile line operator name and the other one name directory, used to enter name, surname, mobile number and the id of the operator. I make a page to display all data from directory table and call … ![]() | |
I need a timer that shows the total elapsed time it took for the user to complete the game. I'm running Python 3.2, pyscripter 2.5.3. I'm using "timer.timer" but I'm having trouble. I want the timer to reset when the user inputs "reset", but still keep a running total in … | |
Hi, how can i return arguments in my custom native dll like ReadProcessMemory api? For example for readprocessmemory, byte arguments return readed value. Its mixed c# and c++ so if its wrong place to ask, sorry about that. public byte[] ByteOku(uint BellekAdresi, int PID) { IntPtr readHandle = NativeMethods.OpenProcess(0x10, false, … | |
#include <string> #include <cstdlib> typedef enum {Dominion, Sobeys, Shoppers, Walmart} Store; using namespace std; class Item { private: // name of the item (non-empty string) string name; // number of dollars in price of item int dollars; // number of cents in price of item int cents; // store where … | |
//TO FIND INVERSE OF A MATRIX #include<iostream.h> #include<conio.h> #include<math.h> #include<graphics.h> #include<iomanip.h> float A[3][3],B[3][3]; int i,j,k,l,m,n,e,f,g,h; float det=0; void main() { clrscr(); cout<<"Enter the 3x3 matrix :\n";//Enters the matrix for(i=0;i<3;i++) for(j=0;j<3;j++) cin>>A[i][j]; //To find cofactor and determinant for(i=0,k=1,m=2,e=-1,g=2;i<3;i++,e++,g--,k-=g,m-=e) { for(j=0,l=1,n=2,f=-1,h=2;j<3;j++,f++,h--,l-=h,n-=f) { B[i][j]=pow(-1,(i+j))*((A[k][l]*A[m][n])-(A[m][l]*A[k][n])); if(i==0) { det+=A[i][j]*B[i][j]; } } } cout<<"The determinant of … | |
HI I am developing a web service client using netbeans ide . I have used the code completion feature to implement the submit message method : import javax.xml.bind.JAXBElement; import uk.co.csoft.www2.dtd.sendsms5.Message; import uk.co.csoft.www2.dtd.sendsms5.ObjectFactory; import uk.co.csoft.www2.dtd.sendsms5.Recipient; public class Main { public static void main(String args[]) { //Recipient r = new Recipient(); //Message … | |
I have a half built invoice, but I'm needing to add items in a list to get a subtotal and total. How should I go about doing that? `using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace FinalProject { [Serializable] public class Invoice { List<int> price = new List<int>(); public … | |
Hi, I am hoping you guys could help me with this. I am trying to loop number into something like this. 0 12 345 6789 here is my code: Dim i As Integer Dim j As Integer j = CInt(TextBox1.Text) For i = 0 To j label1.text = i Next … | |
I'm trying to upgrade my class library to my current mathematical skill set and am having trouble with multi-term polynomials, especially those I where I don't know how many terms the user will be putting in. I know that the formula for the first derivative of a polynomial is ax^n … | |
I'm trying to upgrade my class library to my current mathematical skill set and am having trouble with multi-term polynomials, especially those I where I don't know how many terms the user will be putting in. I know that the formula for the first derivative of a polynomial is ax^n … | |
#include<dos.h> #include<iostream.h> #include<stdlib.h> #include<conio.h> #include<stdio.h> #include<string.h> #include<graphics.h> int y; int i; struct element{ char name[20]; int at_no; double at_wt,at_r,en,ion,density,mp,bp; char ato_wt[20],ato_r[20],eno[20]; char iono[20],densityo[20],mpo[20],bpo[20]; char crs[20]; char sym[4]; char earr[100]; }E[118]; void numberfind(int); void numrfind(int,int); void massfind(double); void namfind(char*); void namlfind(char); void massrfind(double,double); void ionifind(double); void ionirfind(double,double); void enegfind(double); void enegrfind(double,double); … | |
[Moderator edit: 3500 lines of code removed as it was totally irrelevant to the question and severely affecting load time of the page] | |
"Add a function to the sets module called issubset with a function signature issubset(set1, set2). Your function should return True if every element in set1 appears in set2. Make sure you document your function fully and remember to include preconditions and postconditions. Also, include some testing for your new function." … | |
I need Help Here /* Name: Ashley Powell File Name: Employee */ public class Employee extends Person { private double annualSalary; private int hiredYear; private String ID; public Employee(String initialName, double initialSalary, int joinedYear, String id) { super(initialName); annualSalary = initialSalary; hiredYear = joinedYear; ID = id; } public void … | |
Greetings, guys can you help me with this error? Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\xampp\htdocs\email_verify\register.php on line 63 | |
Hi All, I am quite stuck in an operation where I have to calculate a sum using circular reference. Though in Excel , it's quite easy (or already managed by excel itself) to use circular reference but I am not sure how to implement this thing in C#. The problem … | |
Hello I have some PHP code that will extract data from multiple tables and present it with mpdf as a PDF. Everything is working well except i only get the last row instead of all rows with one of the while statements. I realize that it's not optimal to run … | |
Hello, Please advise how to remove white spaces before and after a sentence only. Example: " This is a sentence. " should be "This is a sentence." Thanks. | |
Hi, I am facing some problem dealing with the qsort funtion. Basically, the below program takes in a bunch of strings from the text file "word.txt" and then implements the qsort function for sorting the list alphabatically and then displaying the sorted list. However, after the sorting is done, all … | |
How I can write the below query in PHP ? In my query I have sepcial characters like single quote (') ampersand (&) `update onlinepg (short_description, long_description) values ('PG for Girls/Ladies/Women in Kasmiri Rd, heart of the Agra city with fully furnished, 2/3 times homely food and all basic amenities.', … | |
I have added three images to ImageList..I want to show tooltip....On listview item... [code] Public Class Form2 Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load ListView1.View = View.LargeIcon ListView1.LargeImageList = ImageList1 For lcount As Integer = 1 To 3 ListView1.Items.Add(lcount.ToString, lcount - 1) Next End Sub … | |
Hi, I don't have any idea about regular expression. Can some on please suggest a good website for regular expression Tutorial. Also 1.Can some one please help me to generate a regular expression meeting all these requirements * A strings minmum length must be 3 charcters, and maximum length must … | |
hi. I am working on a project that requires a search button. it goes like this. the I will enter data on a text box. then the record that goes with it will display on the 3 textboxes. My problem is I don't know how to code a search buttons. … | |
Hi evreybody,sry before i posted wrong title name,very sory for my bad english I have a users table which I want to display 5 records then take a new row, display 5 records, take a new row... plz anybody help me. this is the mysql query $planbook_obj= Doctrine_Query::create()->select('p.personal_id,p.photo,p.title_name,p.zone_id,p.place,p.occasion,p.itinerary,p.description,p.date')->from('planbook p'); $result … | |
Hi, been working on this project and just confusing the heck out of myself. My project is Operation • This project simulates a simple robot that can move a given direction and distance. • To determine the direction the robot will move, the user clicks the N (North), S (South), … | |
I had decided to use JcomboBox but it doesn't seems to work. It doesn't seem to be able to take the string in the JComboBox as a condition to log in. Previously with correct username and password, it will be able to log in but now with correct user and … | |
Hello all, been a while since I've asked a question. I'm working on a project just to practice and for fun and I've run into a snag. I'm working on a painting type program and I'm trying to get a generic Buffer class for the images so I can use … | |
How do I move my first thumbnail left an and have no space at end on right side? http://www.rendemolition.com/patio1.html | |
The code is really long so I don't want to post all of it, but I'm posting the part I'm having an issue with. This is part of a fraction class I'm writing. Most of it is working but for there is something wrong with the istream because when I … |
The End.