64,152 Solved Topics
Remove Filter ![]() | |
Hi mates.. I'm trying to find a way in how to inputing or outputting from a file in Java. For my bad luck when I finished my Java course, our professor didn't talked about this thing. I searched in the internet, and found a way in inputing from a file … | |
Hi, I am working on creating a jradiobutton group using JTable. Here is a brief definition of the problem. My program gives an output like this:- [CODE] Questions Answers 1 radiobtn1 radiobtn2 radiobtn3 2 radiobtn1 radiobtn2 radiobtn3 3 radiobtn1 radiobtn2 radiobtn3 [/CODE] I am able to set horizontal control that … | |
hello all i am new to this forum and need some help whit php. I am trying to create a script that shows the number of users online. [CODE]<?php $host = "xx.xxx.xxx.xx"; $user = "xxxx"; $pass = "xxxx"; $db = "users" $conn = mysql_connect("$host", "$user", "$pass") or die ("Unable to … ![]() | |
ok so im a new programmer and im making a tic tac toe program and i got this error `"operator && cannot be applied to boolean,java.lang.String"` in the crazy long line in the winner method and am not sure how to fix it import java.util.Scanner; import java.util.Random; public class tictactoe … | |
Hello every one ... I need help to make connection between two PC through socket programming ... in which scenario i want connection is as below ... there are two networks on different places.One network having internet connection of COM1company and through that one connection only other PCs are getting … | |
Hi.. This is my program for my assignment.. So far,I've succeeded in coding the program but not for the last part.. I still need to find the total sale for this program... and the result at the end suppose to be more or less like this : Total sale : … | |
Hello, I am beginner with c++ programming and I need help with this source. I tried to find a way for getPrintDetails to not print a infomation. //Course: 4002-208 //Author: Joseph Dalpra //Topic: Functions //Name: project4.cpp //Purpose: Using functions to shorten repeated code // Play the game of craps for … | |
I need to have a function like this: if (x == 1){ ... } do some amazing things. I need it to check to see if x == 1 through 380 or more. But I really don't want to waste 4 hours doing this: if (x == 1 || x … | |
Sorry if this is a really easy question, but I've been going through control flows in the python documentation and something confuses me that it doesn't address. [CODE] a = ['Mary', 'had', 'a', 'little', 'lamb'] for i in range(len(a)): print i, a[i] [/CODE] When I type that in, it prints … | |
So I need to find the highest and lowest for some numbers I am storing into struct [code=c] #include <iostream> #include <string> using namespace std; struct WeatherStation { string StationDesignation; double Temperature; } CA, FL, NY; // EXAMPLE, I WILL ADD A LOOP FOR FL AND NY int main() { … | |
Hello guys, can someone tell me how can I get the values from the columns ? My sql table is: Table name: settbl Table columns: id, first (int), second (int) ...and now, I want to get the values from "first" and "second", but I got the error message "Object reference … | |
From what I've googled, it seems like symbol reference errors are linking errors.. If I am wrong, please let me know. I'm trying to make a very simple program(DataReader.cpp) that takes inputs from a text file and saves them in a form specified in Data.cpp/Data.h. But I keep getting symbol … | |
Hello everyone, I'm new to the forum and new to C++, or any programming for that matter. I've been trying to create suite of 4 functions one of which takes a string and converts it into an integer. I'm aware of the atoi function but we are not supposed to … | |
Having worked with txt files, I'm learning about binary now. My code below works for a while then bombs out, can you point me towards a method or module to read binary data line by line? The crypto module requires a buffer (don't know how to create one of those) … | |
Hello Daniweb, This is my first official "help" thread. I'm currently attempting to read a file that has the following code: [CODE]8 split 1 9 1 spare 7 2 10 strike 8 2 spare 6 split 2 7 3 spare 10 strike 10 strike 10 turkey 8 1[/CODE] and have … | |
Hi, Any advice please. I have various forms (e.g. frmCustomers, frmProducts), each having bindingSources and tableAdapters. The forms have the required Fill methods triggered from their constructors. It appears that the DataTable filled only exists in the App for as long as the form does. What I want is a … | |
[CODE] def doKey(e): print(e.widget.get("1.0","end")) root= Tk() root.title('yada') txta = Text(root, width=40, height=10) txta.bind("<Key>", doKey) txta.pack(side=LEFT) root.mainloop() [/CODE] Pressing a key in this text area will always output the string prior to your pressing the key. Am I missing something? | |
I am a complete newbie to python but know some c++ Was wondering where i can get my hands on a 3D script for schooling(like fish) BattlingMaxo | |
Hi guys. I am trying to write a program that asks the user how many test scores they have, then reads the test scores, averages them, then displays the average and a pass/fail grade (50+ is a pass), using a seperate function to average the input values. I have been … | |
![]() | hi all, I am designing a text editor program in Python using Tkinter and I was wondering if there's any way to get the current line number when the mouse is clicked somewhere on the text field, i.e the mouse position should determine the current line, like in the python … ![]() |
simple little program from a book. One of the exercises is to modify it to use displayMessage to output the "Welcome" message and the name of the Professor. Problem is everytime I do it the name of the Course and the professor are the same. What am I doing wrong? … | |
I'm too new in java and I always appreciated when you share with me your knowledge. Here I'm trying following self-test exercise; Give two declaration for two variables called feet and inches.Both variables are of type int and both are to be initialised to zero in declaration. I try this … | |
Hi, In my app I have a group of checkboxes which represent different settings. I want to be able to load and save these settings into the program, and that works just fine. However I'm having trouble updating the checkboxes to show the settings. If I load the settings, only … | |
i have created a database for subscriptions in MS Access 2007. I want to link it with my forms using the code below but its saying unrecognised database format. [B]Dim conn As Connection Set conn = New Connection conn.Open "PROVIDER=Microsoft.Jet.OLEDB.3.51;Data Source=C:\subscriptions2.mdb".......[/B] Now i have converted it to Access 2000 format … | |
![]() | Hi, I would like to know if it's possible to specify the "target='FrameName'" in response.sendRedirect("Home.jsp") by any chance? I tried this: [CODE] <!-- Security Check --> <form action="Login" target="_top"> <% if ((String) request.getSession(false).getAttribute("sessionStatus") == null) { response.sendRedirect("Login?pageTimeout=yes"); } %> </form> <!-- Security Check --> [/CODE] But it doesn't work... The … ![]() |
wats roang in here .. [LIST=1] [*]<?php [*]ini_set('display_errors', 1); [*]//connecting to database [*]$error = "nu am putut sa ma conectez :("; [*]mysql_connect('localhost','root','')or die ($error); [*]mysql_select_db('dan') or die ($error); [*]//max display pet page [*]$per_page = 2; [*]//get start variabel [*]$start = $_GET['start'] ; [*]//cont record [*]$record_count = mysql_num_rows( mysql_query("SELECT *FROM news")); … | |
Hello all. I've got this upload script, working just fine. [CODE] <?php error_reporting(0); $change=""; $abc=""; define ("MAX_SIZE","400"); function getExtension($str) { $i = strrpos($str,"."); if (!$i) { return ""; } $l = strlen($str) - $i; $ext = substr($str,$i+1,$l); return $ext; } $errors=0; if($_SERVER["REQUEST_METHOD"] == "POST") { $image =$_FILES["file"]["name"]; $uploadedfile = $_FILES['file']['tmp_name']; … | |
Hello. I've been trying to solve this problem but I can't and my head hurts already. Please help me. [code=c] #include<stdio.h> #include<conio.h> #include<stdlib.h> #include<string.h> #define max 12 #define num 30 #define nam 24 typedef struct { char name[nam]; int score; int rank; }CONTESTANT; typedef struct { CONTESTANT CA; int next; … | |
This is what I have of my code so far but I cant get it to work right, Can someone help me fix this I need to make a float function that converts celsius to fahrenheit but im not totally sure how to do it I also need to make … | |
I an trying to write a few java classes, which I wrote successfully, but when I am tryin to test it I get some weird errors and I cant figure out why, so i'd be very grateful for your expertise. The code for the GCD class is: [code] public class … | |
Hey, I am just learning functions. I was wondering if you could tell me why this piece of code is not implementing the 'values' function. [code] #include <iostream> #include <windows.h> #include <string> #include <iomanip> void values(float value1[11]); using namespace std; float value1[11], value2[11]; int main() { cout << setiosflags(ios::fixed) << … | |
I have be struggling to turn the below while loop into a foreach loop with no result, so I am asking for help here on how to do this. [code] $query = "Select * from TIME_TABLE Where Extract(month from DATE_FIELD ) = DATE_FORMAT(NOW(), '%c') and Extract(day from DATE_FIELD ) = … | |
Hey DW. Working on a nice poker application and need some help. Right now I'm trying to go through two arraylists, one of chars and one of sorted ints (representing the suites, and numbers of the cards) and delete duplicating numbs (and the char/suite counterpart in the other array). In … | |
Write a function called NumDistinctDict that takes a single parameter alist that determines the number of distinct values in alist. For example, the list [1,2,4,2,7] contains 3 unique values (namely 1,2,4 and 7). | |
So I want to make a class based RPG, as a project to help me understand how classes work. Unfortunately, I didn't get far. The below code is intended to make an instance of a character and have info in it like name, health, gold, exp, and the like. I … | |
How do you know when to use a function by wraping the content between parentheses "function(x) or through dot notation x.function() ? thanks. ![]() | |
Afternoon: I am trying to create a loop to give me a series of random numbers. I need the random numbers to be between 100 and 999, this is necessary so I can divide the numbers by 1000 and then use this numbers for another program. My problem is that … | |
hello every one i m trying to minimize the form size but less than what it allows for me if i do like this .. it is okey this.Size = new Size(124, 36); but less than these values for the width and length it won't work.. i need to make … | |
Does anyone know of a php based forum that is easily customizable to work with an existing user base so that members don't have to register or sign in a second time when they access the forum? I heard that this is possible with phpbb3 but I haven't seen anything … | |
the program draws lines, but every time I draw a new line, the previous one disappears. How can I let it show all the lines drawn? I know my problem is in the array, but how to fix it? thanks for help [code] import javax.swing.JPanel; import java.awt.*; import java.awt.event.*; import … | |
Hi guys, Can I enable/disable an #ifdef based on a specific condition? Let's say that I've a loop [CODE]#define MYCONDITION 1 // code here for (int i=0; i<5; ++i) { printf("Hello #%d", i); #if MYCONDITION printf("I wanna be reached only if i == 3, is that possible?"); #endif }[/CODE] Is … | |
Hi all, this is a bit of a follow on from a previous post, but slightly different so thought a new post would be best. i want to pass my scanner variables into an object. the following is the last scanner (Added as example), followed by the creation of a … | |
I'd like to turn PHP off within a folder, with the exception of certain files (e.g. disabling PHP for all files but test1.php and test2.php, or test*.php). I believe PHP can be turned off for a folder by placing "php_flag engine off" within that folder's .htaccess, but how can I … | |
I can't find a compiler to compile version 3 Python scripts to .exe. All the compilers I see are all for Python 2. | |
Hi all, I have a constructor with 2 numbers both set as longs however in my driver class, it is showing as an error, even after casting the already longs to a long again. This is constructor [code]public Personal(String forename, String surname, long dob, String add1, String add2, String county, … | |
could someone point out the error in the followin php/mysql code [code=php]$strSearchVal = $_GET['q']; //database connection.. //... $strSQL = "SELECT DISTINCT area FROM hospital where area like '%'+ $strSearchVal; "; $result = mysql_query($strSQL); while ($arrThisRow = mysql_fetch_array($result )) { echo '<li>' . $arrThisRow['area'] . '</li>';[/code] | |
Don't know why my coding appear this error: "Notice : Undefined index: PK in c:\easyphp1-8\www\associationdeleteprocess.php on line 24" But I still can delete my database. Who can help me to solve this problem? This is my "AssociationDeleteProcess.php" coding: [CODE]<html> <head> <title>Index</title> </head> <body background="E-Filing%20Management%20System%20Picture/Snow.gif"> <p align="center"> <img border="0" src="E-Filing%20Management%20System%20Picture/logo-RR-gif.gif" width="957" … | |
hi i keep getting this error on my php page Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/internal/public_html/includes/xpage_admin.php on line 871 Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/internal/public_html/includes/xpage_admin.php on line 877 the code below works perfectly on my test … | |
Hello, I am having trouble figuring out the correct syntax for a small portion of my code. I am trying to have my code search through a column and for each entry in that column copy and paste only the rows that have the following characteristics: the first character = … | |
Hi, I'm new to c# although have written in a few other langues in the past. I'm trying to get a list of services and their status and create an xml file from this info. I use the ServiceController. [CODE]ServiceController[] services = ServiceController.GetServices();[/CODE] If I send the info to the … |
The End.