199,113 Archived Topics
Remove Filter ![]() | |
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 … | |
for (int year = 1; year <= 10; year++){ amount = principal * Math.pow(1+rate, year); principal = amount; System.out.printf("%d%20.2f\n",year,amount); for (int year = 1; year <= 10; year++){ amount = principal * Math.pow(1+rate, year); System.out.printf("%d%20.2f\n",year,amount); // what is the difference between these two? | |
I am working on a project where i need to dynamically count how many buttons need to be added to a certain panel. Each button press has to change a variable in the parent class and then to excute generation of a child panel which also dynamically generates buttons. my … | |
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 | |
I'm working on a guessing game where the object is where the player is given a board of 25 symbols and asked to try and guess the location of 6 hidden symbols. However, I've encountered two bugs whose cause I cannot identify. 1. Regardless of whether the guess is a … | |
I borrowed this from C#, where you can easily send output, that normally goes to the ugly black console window, to a nice looking Windows MessageBox with an OK button to close after you read your results. You can accumulate your output in a string to send to one message … | |
I want to display an image from database so i am using this script: <?php header("Content-type: image/jpeg"); $username = "root"; $password = "root"; $host = "localhost"; $database = "binary"; mysql_connect($host, $username, $password) or die("Can not connect to database: ".mysql_error()); mysql_select_db($database) or die("Can not select the database: ".mysql_error()); $id = 3; … | |
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 … | |
Hello everyone, for example, I have name.txt file. It contains three lines of text (see below): *Roses are red% Sky is blue% JAVA is cool%* All lines ended with % symbol. I need to count how many every line have characters and which character is repeated max and min times. … | |
Hello , I'm trying to solve a "known problem" in XPath 1.0 . From [msdn](http://msdn.microsoft.com/en-us/library/bb341675.aspx) : "***Although the ordering of returned collections is not specified in the XML XPath Language 1.0 Recommendation, this extension method returns nodes in document order. Note that nodes are returned in document order even when … | |
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. | |
I have this jquery code below and I need it to attach events on controls as the controls are created dynamically. Right now they are set for a specific control. Thanks $(document).on("click", "#day1Header", function () { $("#day1Details").slideToggle("normal"); $(".expandDay1Details").html($(".expandDay1Details").html() == 'CLOSE' ? 'EDIT' : 'CLOSE'); }); $(document).on("click", "#day2Header", function () { … | |
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 … ![]() | |
Hi, I've been strugelling with this code for days now, I new at javascript and really need help. This code worked perfectly and then just stopped working. I want the divs to change on a mouseover event, so basically when you hover over a td it goes to a other … | |
#Administrator Console# I am Making a Noob-Proof GUI Administration Control Panel, and I Have, Log Off User Shutdown (With User Selected Amount Of Time) Quick Shutdown (Shell ("shutdown -s -t 00") ) Reboot Computer and I Need the following: Disable TaskManager Disable Command Prompt Disable internet Disable My Computer and … | |
**I have been automatically collecting machine breakdown info to a database for 12 months, so I have thousands of entries in a 'Machine Downtime' table. However, I have found that the time_down column is offset by one row. The 'time_down' in the top row needs to be moved to the … | |
Using Microsoft Visual Basic Express 2010 This is the code i used: Dim b As Integer = TextBox1.Text Dim c As Integer = TextBox2.Text Dim a As Integer = b * c MsgBox(a Why does this visual basic code not work and how do i fix it to make it … | |
so the code is pretty simple. it just loops and if statements. first i have a main. i took the headers and prototypes out to make it smaller. In main all iam doing is asking user to enter command and call one funtion. // main.c int main(int argc, char *argv[]) … | |
Hello, I'm working on an assignment that requires me to do the following: "A file contains 6 numbers per line and contains several records. Another file contains 3 numbers per line and several records. Write a program to input each of the numbers, find the highest number, the lowest number, … | |
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 … | |
One of the problems with datediff function is that even if the two dates are 31-12-2011 and 01-01-2012,it will show the difference as 1 year.How to overcome this problem???? | |
//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 … | |
hello there guys I have attached a picture of the error that I've been receiving in coding my tetris program, anyone here who knows how to fix this? please help me thanks in advance.  | |
hello! I have a function with the following definition: void functionName(void** a); When I want to call that function how am I supposed to send the arguments? | |
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 noticed the foolowing details regarding fstream. the following combination of openstate flags do not truncate the files. ios_base::out | ios_base::in | <any flag other than ios_base::trunc> ios_base::out | ios_base::app | <any flag other than ios_base::trunc> the following combinations are resulting in a failbit ios_base::app ios_base::ate ios_base::app | aos_base::ate … | |
I need to create a program that uses a structure that alocates memory with the new operator. The information must be saved in a file, then displayed. The problem I have is that the program saves only the first character of the words I enter. Could someone please help me … | |
Hi! I need to disable a key in vb.net, such as the e key. So i would open my application and tab off of it, and go to internet explorer and try to go to google and it would come out as goolg . How would i do this? | |
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 … | |
Hello, so none develper needing assistance... I am trying to change a class tag to a sub menus <ul> tag within Drupal 7. I have a main nav and sub nav each has the class - menu. I am trying to change the sub nav class attribute. So... <ul class="menu"> … ![]() | |
Hello. All i am having trouble with using public ref classes and gcnew. The following code will show you my situation. Vector2 class /// </summary> public ref class vector2{ public: vector2(void):x(""),y(""){}; System::String ^x; System::String ^y; void Position(System::String ^ X, System::String^ Y){ x=X; y=Y; }; }; Add picture class public ref … | |
Hi all, I am writing a service to get a count from a table on an SQL server. THe SQL box is in the same domain, and the service is runnign under the same account as the SQL box. The box service is running on is Win 2008 in the … | |
Trying to do Parameters for Report in Reporting Services from a database that's in mysql . My Where clause looks like this: Where HD_TICKET.HD_QUEUE_ID="6" WHERE HD_TICKET.CREATED BETWEEN [Start Date] AND [End Date] GROUP BY (HD_PRIORITY.NAME) I get this error: ERROR [42000] [MySQL][ODBC 5.1 Driver][mysqld-5.1.54-log]You have an error in your SQL … | |
This is a dumb question, but I have honestly spent a long time today trying to figure it out, and I'm sure I'm not the only one who has trouble with this. How do you import a CSV directly into a MYSQL DB? I've tried using [CODE]LOAD DATA LOCAL INFILE … | |
hi guys.... i make a program with Dev-C++ ..... let say my program is already running now .... if i try to open it ... it show me a MessageBox or an output to tell me i can't run it when is already running | |
[I]FYI - I'm coding in actionscript 3.0 but didn't see an area to post for that language.[/I] I made a simple character and a block. I'm trying to get it so that if the character will touch the box, it wont let him move to imply a wall/collision. I've got … | |
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 … | |
Hi, everyone. Hope you can help me to answer the question, i am not familiar with recursive function...and i hope someone could help me.. Shift elements means e.g. array[ ] = {1, 2, 3, 4, 5, 6}; if the user input a value, say 2, the array will become {5, … | |
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 … | |
Hi, I'm working on a website where i have the list of all products and its info: image, description, reference and a button to see more images of the product. I want to create a checkbox that when is checked all the info is hidden except the image. I'm using … ![]() | |
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 … | |
"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." … | |
Hi all, I actually need to use a sorted map.So i tried using Tree Map.But the problem is that This works well with sort key having values upto 9. With more than 10 items I see abrupt results with sort key arranged in the order = 1, 10, 11,12,--------17, 2, … | |
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 | |
I wonder if someone can point out where I'm going wrong with this code. My aim is to control the visibility of an UpdatePanel with a CheckBox. The CheckBox is located on the same form, but not adjacent to the UpdatePanel. ScriptManager is present, but when browsing, checking the CheckBox … | |
I recently been assigned a project to develop an internal web service that makes use of an outside service from Sprint. the only thing I have is a .wsdl file web reference from Sprint. When I add the web reference to the project and compile my code, I get a … |
The End.