199,114 Archived Topics
Remove Filter ![]() | |
class Mixer { Mixer() {} Mixer(Mixer m) { m1 = m; } Mixer m1; public static void main(String args[]) { Mixer m2 = new Mixer(); Mixer m3 = new Mixer(m2); m3.go(); Mixer m4 = m3.m1; m4.go(); Mixer m5 = m2.m1; m5.go(); } void go() { System.out.println("hi"); } } The answer … | |
Hello, Can someone please help me with a little problem that I am having splitting strings? I am trying to remove everything more than 2 - digits to the right of a decimal point in a string. For some reason I am not realizing my desired results. If you could … | |
Private Sub PrintDocument3_PrintPage(sender As Object, e As System.Drawing.Printing.PrintPageEventArgs) Handles PrintDocument3.PrintPage Dim PrintFont As New Font("Arial", 18) Dim LineHeight As Single = PrintFont.GetHeight + 2 Dim Horizontal As Single = 100 Dim Vertical As Single = e.MarginBounds.Top Dim PrintLine As String = "This is a Chapter 4 Testing" Static pageCount As … | |
I have a Winforms application that I want the end-user to be able to select a radio button to determine the browser they will use(ie, firefox, chrome, opera, etc...) to perform a set of predefined queries. The problem is I want to scale the web-browser to be 800x600 no matter … | |
Hi guys, Just looking for some advice on database design. I'm relatively competent in MySQL (competent at a push, haha) and I'm in a bit of a pickle right now when I'm trying to generate products for a Magento store. Well, Magento is where it ends up, I currently use … | |
I want to fetch names and address of all my friends from facebook and store it in my system, Can AnyOne tell me how this can be done with html, php or anything...I don't have any idea for this.. | |
![]() | Hi, everyone. I am making a tic - tac - toe game and I am having some trouble. As you can see I have made good progress: from os import system a = "1"; b = "2"; c = "3"; d = "4"; e = "5"; f = "6"; g … |
In my script, I have a table displaying the results of a SQL query. However, I am using the results as a sumamary, but the SQL is making the page display the table as many times as there are results (rows) in the returning SQL that are allowed because of … | |
some people say that multiple inheritance in java is not needed because we have interfaces or that using singular inheritance can bring the same results as using a multiple inheritance. But that is not the case. Lets take a look at the example I call “The Workbench Example” say we … | |
Hi I would like to make cgi-bin program which will make dynamic pictures. I know how to make cgi program which would output simple html file #include <iostream> using namespace std; int main(int argc, char* argv[]) { cout <<"Content-type: text/html\r\n\r\n" << endl; try { cout<<"<html><body><h1>Test</h1></body></html>"<<endl; } catch (exception e) { … | |
| |
Hello All, I'm currently working on developing a game app for Android. The game app is based off of 'Mr.Nom' from Beginning Android 4 Games Development. I've kept the code the same for this first version, but did make some original graphical and audio attributes. I worked through the last … | |
I want to modify the sky to be grey but i want to be time gap between the two...but i dont know how to do it # Import a library functions called 'pygame' import pygame # Initialize the game engine pygame.init() # Define some colors black = (0, 0, 0) … | |
//Check radiobutton list based on the data retrieve from the database //This is also not working.. This does not select any item of the RadioButtonList1.. and also not giving any error... //Here is my code protected void DropDownList2_SelectedIndexChanged(object sender, EventArgs e) { string selectSQL; selectSQL = "SELECT * FROM Books_Magazines … | |
Hello, I am such a rookie when it comes to C#. I have created a class with a list. I am needing to read an xml file into this from inside the class. Then I am needing to manipulate this list from inside the class as well. I have everything … | |
Hi, i need an help for an error. When I run this code it crush, with this error: Unhandled exception at 0x77da331f in ES_7.exe: 0xC0000005: Access violation reading location 0x00000004. Process returned -1073741819 (0xC0000005) I translated some parts of the code to better understanding NB: When I run this code … | |
ok so I was doing a a function that would find the square root of a number to a certain precision using newtons method and this is what I came up with /* * File: main.cpp * * * Created on July 6, 2012, 6:58 PM */ #include <iostream> #include … | |
Please anybody help me out in installing gearman php extension on windows xp. I have xampp 1.7.7 installed on my system and i have installed Cygwin, libevent-1.4.14b-stable and gearmand on my system. Please let me know what more is needed to install gearman-1.0.2 php extension. As when i run the … | |
# Heading Here # Please assist me on this one. I have two DB's, one keeps track of user and system activities and the other keeps track of only user activities. The purpose of the codes below is to first of all retreive all tables from the second DB. These … | |
I am learning to using STL, and I'm currently on vectors. I have seen a lot of examples and practiced a lot on my own using built in types, but I'm finding very difficult storing objects that I create my self in a vector. Everything works fine when I add … | |
Hi. I am having a problem with PHP. I got these lines of code: <?php include('Include Stuff') ?> <html> <center> <h1>Admin Login.</h1> <form action="(Action Script)" method="POST"> Admin Name: <input type="text" name="name" /><br /> Password: <input type="password" name="code" /><br /> <input type="submit" value="Login" /> </form> </html> And this: (the action script … | |
![]() | Hi guys, I was making a text based game in javascript.. Here it is: <!doctype html> <script type="text/javascript"> //Experimental Code - Text Based RPG function error() { alert(+choice+ "is not a recognised command") maingame() } function maingame() { choice = prompt('You find yourself in a dark room...do you\n[1]Eat cheese\n[2]Do stuff') … |
Sir Please suggest a way to compare values in a column of excel sheet so that if same values are appeared i can update using php I have a column named Name which stores Names of students,if same student entry is appeared i need to update Thanks | |
# This program runs a test of knowledge #First get the questions #Later this will be modified to use file io def get_questions(): #Notice how the data is stored in a list of lists return [["What color is the daytime sky on a clear day? ", "blue"], ["What i the … | |
Hi, i'm programing in CodeBlocks (http://www.codeblocks.org/). I would like to add Dlib (http://dlib.net/) library to my project. How can I do this? I went to my project "Build options..."->"Search directories"->Compiler and added path to "dlib" folder. I did the same for "Linker" and "Resource compiler" (more info abaut adding libaries … | |
I have created a JFrame with two JPanes (mainPanel and secondPanel)in it. I am trying to update the first JPane (mainPanel) with a JPane that is returned by another class of the project. How can I do that? Thank you. | |
i just finish working on my website which uses php, sql database, html and css. I am trying to put it online and i am using 000wehost.com to do so. but the problem is that when i sign up for host it says that "Account verification in progress, check again … | |
I'm building an image processing appilcation..the problem is I'm not able to import separate scripts in my main script..I want to use them for various functions..but it shows an error.. can anyone tell me the correct procedure to import script defined for various functions.. ` from Tkinter import * from … | |
We all know how to open a mailbox using `imap_open`. Here the problem is i'm creating a maill system here. I'm not able to find to create a mail account with `imap/pop3` in `php`. Is it is possible ? Assume suppose my domain is www.studentmug.com. I want to create a … | |
Hi, I am trying to check if a certain username is in a session. This is what I have so far... <?php if ($_SESSION=='Djmann1013') { // Do the work here. } else { // Don't do anything :P } ?> But, when I test this, it does nothing. But when … | |
Hi Everyone, I have a foreach array that prints out images one per line. How can I print images out so I have 3 per line ? here is the code I am working with. if (count($friendDataRawArray) > 0) { foreach ( $friendDataRawArray as $id => $friend) { //$name = … | |
# problem with code for converting decimal to other bases # when i give any input, a window appears saying "**a problem has occured, windows needs to close**"  i cant understand what im doing wrong here. any help will highly appreciated :) this is my code: #include<stdio.h> #include<conio.h> … | |
I have a question about a better way to do this as what I've written seems clunky. I'm trying to generate 2 variables here that will be used as the date in a BETWEEN clause in MySQL. In order to get the proper construction (YYYYMMDD) I am converting to a … | |
i did a program in xp and when i m trying to open this program in win7 it gives an error i think i should convert this program to win7 but i dont know how to do is there any way to do it? thx for answers | |
hi, i'm trying to do some appointment book so i decided to use MonthCalendar control and date changed event for choose the date i tried dataset.table.rows.find() function on other tables which have int primary key and it works its finds my row/s i need but when i tried this func. … | |
been trying to google it for a while now but didnt help using the " "... anyway i need to do a recursive search inside a sub tree of the file system. given a folder A , I need to go through all of its sub folders. so far the … | |
Hi there, I want to create like a online interaction system on my site. you know like a "Chat to us now" kinda thing. Where when a user is on your site you can chat with them directly from the home page or any other page using a 3rd party … | |
![]() | Hi, I'm new to JS: <!doctype html> <script type="text/javascript"> //JS start function give_me_an_alertbox(): alert("This is an alert box."); //JS end </script> <a href="javascript: give_me_an_alertbox()">ALERT BOX!</a> How come this code does not work!? How do I refer to Javascript using `href` ? |
I have made 2 classes; Customer and Repair. I have a map<String, Customer>(customerDetails). Customer objects hold a map<String, Repair>(repairs). My GUI has 2 JTextAreas, notes and results. In notes ou type some notes and when you choose save the notes appear in results and a new Repair is created with … | |
I have a form that consists of only a TableLayoutPanel (which fills the entire form) containing a vertical stack of buttons. The resulting app is used in conjunction with another app. What I would like is to have the vb app do something when the mouse enters the form. Unfortunately, … | |
Hi, I want to change this code as given 1 result. I don't need 10 line results. I just need 1 line result. When I tried to change 10 with 1 it doesn't work. Please help me about that. while( $row = mysql_fetch_array($query) ) { $id[] = $row['id']; } $id … | |
hi guys, i've been trying to get a work around for this: in a file structure like this: root: -----index.php (file inside root) -----template (folder inside root) -----user (folder inside root) -----products (folder inside root) -----config (folder inside root) i've been tryoing to use dirname(dirname(__FILE__)) inside a file in the … ![]() | |
I have created a JMenuItem and a JButton. How can I have the same result when I use either the JMenuItem or the JButton? Basically I want them to trigger the same method. Thank you. | |
Good day to everyone I am having some trouble with an assignment for my work at College in UK (im 17) We have been given the task of, and the criteria of The program should allow the user to input 4 numbers as follows: '0' - Exit the program '1' … | |
This is a program which I made back in the beginnings when I was trying to figure out how to work with strings, and how to work with files. This is suppose to format a C++ code, for example if the syntax of an if statement is if (condition) { … | |
I have created a JToolBar and I added 3 JButtons inside it. Is there any way I can increase the horizontal space between the buttons?(Now they seem like they're stacked together) Thank you. | |
I have created a form and I added a JFileChooser on it. When I start the form , the JFileChooser appears when the form loads. I gave used netbeans fileChooser tutorial.(http://netbeans.org/kb/docs/java/gui-filechooser.html) Any ideas? Thank you. | |
Dear All, I want to create a dynamic website with a database. Visual studio 2010, dreamweaver CS5, sql server management studio and all other requirements are installed (like IIS 7). I set the IIS server configuration in dreamweaver cs5. I check simple ASP codes like <%Response.Write ("The time on the … | |
Hi, I'm creating a website/database that my dad and his partner will use to help manage there business. update new appointments / manage customers ect. My dad wanted to host it on our server, however I'm not confident about setting up security so I was just going to use a … | |
public class Thread8 implements Runnable { Demo d; public static void main(String r[]) { new Thread8().disp(); } void disp() { d = new Demo(); new Thread(new Thread8()).start(); new Thread(new Thread8()).start(); } public void run() { d.fun(Thread.currentThread().getId()); } } class Demo { static long f=0; synchronized void fun(long id) { for(int … |
The End.