132,726 Archived Topics

Remove Filter
Member Avatar for
Member Avatar for rockerjhr

could someone explain to me why the compiler(gcc) outputs a warning that the control reaches the end of a non void function? [CODE] #include <stdio.h> #include "stack.h" #include "globals.h" #include "stack_interface.h" #define ERR_PUSH "Error in pushing symbol (character #%d).\n" #define ERR_POP "Error in popping symbol tp match character #%d.\n" #define …

Software Development c
Member Avatar for nezachem
0
220
Member Avatar for Jsplinter

Below is a simplified version of the function. [code]int x; void myAdd(const double& p) { if (x > 100) { x = 1; myAdd(p); } ++x; ... }[/code] The advantage of this recursion is that I don't have to write a second function ie myAdd2. Are there any pitfalls of …

Software Development c++
Member Avatar for mike_2000_17
0
130
Member Avatar for ajayb

public static boolean compare(int[] a,int n) { for(int i=0;i<n;i++) { for(int j=i+1;j<n;j++) { if((a[i]*a[j])%2==0) return false; else return true; } } } there's an error coming when I try to include this function in my prog. I think the place of return true is causing problem.When I write the return …

Software Development java
Member Avatar for ajayb
0
126
Member Avatar for alex55

I have a function that should read in data from a file and add them to and array then i pass that array to another that totals the data then i want to find the average of that array and pass the max value to a variable 'max' with the …

Software Development c++
Member Avatar for alex55
0
123
Member Avatar for Kate Teoh

Hi, I have a problem about update table in a database. The situation is I have a table named member which store thousand rows of data records about thousand of member for a system. This member table has a field named MemberExpiryDate which used to store each member expired date. …

Software Development java
Member Avatar for Kate Teoh
0
126
Member Avatar for curbster

Hi I'm in my first Java class, towards the end and am struggling with some code dealing with arrays. I'm not looking for the answers but am spinning my wheels (as usual) and am stuck on a particular problem. I'll list the problem here and then explain where I am …

Software Development display java java-swing
Member Avatar for Akill10
0
12K
Member Avatar for anandguptastar

I have created a function which add a row in tablelayoutpanel and textbox in column of the row. After adding few rows, i want to read the value of particular textbox in particular row. How can it be done. Remember one thing that name of all textbox is same in …

Software Development
Member Avatar for anandguptastar
0
5K
Member Avatar for MarkHolm

This seems to work well until I try to create the 11th button. Any suggestions? [CODE] procedure TForm1.FormClick(Sender: TObject); var nb: TButton; begin Inc(n); nb := TButton.Create(Self); nb.OnClick := ButtonClick; SetLength(ca, n); ca[n] := nb; ca[n].Left := 8; ca[n].Top := (((n - 1) * nb.Height) + 8); ca[n].ParentWindow := Form1.Handle; …

Software Development delphi pascal
Member Avatar for Wolfgan
0
409
Member Avatar for realoneomer

hi Perl Gurus, I have two text files namely test_old and test_new and i am using below perl script which compares both files (old & new) and display only those records which only have changed values but i am getting an error like Can't use an undefined value as an …

Software Development perl
Member Avatar for realoneomer
0
221
Member Avatar for niths

hi all, i had a folderbrowserdialogue. and wen i click on a folder it should get me that folder name, files names in that folder and subfolders and files names in that subfolder to be displayed in listview. i had tried this and it is displaying files in selected folder.Now …

Software Development display listview
Member Avatar for Mitja Bonca
0
520
Member Avatar for tim8w

I need a RegularExpression that can convert a string from a fraction or decimal like "1/2" or "0.5" to a decimal "0.5". It needs to handle both cases. Input can be either fractional or decimal, output must be decimal...

Software Development vb.net
Member Avatar for tim8w
0
242
Member Avatar for mahdi68

in my application i show database table in a datagridview , now i want to modify and change some records and save this changes on database , how can i do this ? thanks

Software Development sql vb.net
Member Avatar for Mitja Bonca
0
110
Member Avatar for Dexxta27

[CODE]typedef struct electro { char name[20]; int access_number; char address[50]; float balance_due; }; electro account[10]; electro account[0].balance_due=$ 120.52; electro account[0].address[50]={Cane Gardens};[/CODE] Can someone tell em how to correct this piece of code. I'm using Codeblocks and it says it " expected an initializer before '.' " in the two last …

Software Development c
Member Avatar for Dexxta27
0
214
Member Avatar for ticktock

Hey all I am a month or two in coding in java and currently I am doing a java calculator gui project, my professor requires us to code the gui by hand, and I did so with a panel and gridbaglayout layout manager, anyways since this is a calculator I …

Software Development gui java
Member Avatar for ticktock
0
671
Member Avatar for Jollyyy100

I have a form on my vb 6.0, i need to change the appearance. In the sense that, i can change its transparency or opacity of the way how the form looks. Is there any way possible i can do that ?

Software Development vb.net visual-basic
Member Avatar for Jollyyy100
0
359
Member Avatar for QuesoTaco

Nevermind, I wanted to delete this post, but did not want to bother emailing the moderator. Sorry.

Software Development c++
Member Avatar for QuesoTaco
0
340
Member Avatar for dennis.d.elston

Please help! I don't understand why I am getting this error: function does not take 0 arguments. The program is suppose to calculate how much fuel is left in the tank after you drive a certain amount of miles. Can someone please help explain why I am getting this error? …

Software Development c++
Member Avatar for dennis.d.elston
0
1K
Member Avatar for biancaW

I have this question. could anyone help me how to write C++ code for it: A bank account starts out with $10,000. Interest is compounded monthly at 6% per year (0.5% per month). Every month, $500 is withdrawn to meet college expenses. After how many years is the account depleted? …

Software Development algorithm c c# c++ file-stream
Member Avatar for jonsca
0
2K
Member Avatar for unclepauly

hello, im writing an HTTP proxy in C#. the proxy should capture both HTTP and HTTPS traffic from the web browser. so far i have implemented the GET and POST requests no problem, but the CONNECT request i am having a little trouble with. there does not appear to be …

Member Avatar for unclepauly
0
2K
Member Avatar for novice20

I want 1.py to call 2.py. 1.py takes an Ip address as a command line argument. I am trying a '[B]subprocess.call()[/B]' in 1.py to call 2.py. I have defined addr= sys.argv[1] before the [B]main()[/B] of 1.py. I want the same address to be accessed in 2.py. In short, 1.py should …

Software Development python
Member Avatar for slate
0
180
Member Avatar for jsefraijeen

good day sir's/ma'am , please help on how to search an inputted elements to an array... for example... i added a name "JOSEPH" and Address "ILOCOS" and i got an option search in my code and i don't know how i will gonna it... please help me.. [CODE]import java.util.Scanner; import …

Software Development java
Member Avatar for jsefraijeen
0
133
Member Avatar for prahesh

Hi I am creating a Setup and Deployment project using Visual Studio 2008, professional edition. And I was able to build successfully the desired .msi and setup.exe files. Requirement: But I want to create a Setup project which searches registry entries for the pre-installed software (VISA) and install our setup …

Software Development c++ visual-studio
Member Avatar for Ancient Dragon
0
192
Member Avatar for jackmaverick1

When I declare a class or an instance of the class, I get the error, error: redefinition of 'class player' then after, I get, error: previous definition of 'class player' by the way, I am using gc++. If you want to see the source, just ask. thanx, JT

Software Development c++ java
Member Avatar for Fbody
0
8K
Member Avatar for abelingaw

I want to load values from a lstview column to a combobox in another form. The problem is that, my combobox style is 2 - Dropdown List and the values in it are from my database field. That's where the error occurs. Saying [ICODE]Text property is read only.[/ICODE] I could …

Software Development listview visual-basic
Member Avatar for AndreRet
0
807
Member Avatar for Shodow

can u help me about this . . . when i click the column header of datagrid it will sort automatically

Software Development vb.net visual-basic
Member Avatar for AndreRet
0
1K
Member Avatar for rosstafarian

Hey Guys, I am trying to create a little project for my college course. I have been trying in vain over the past few days to sort out some errors i have and alot of google pages have brought me here where i have gained alot of knowledge so i …

Software Development open-source vb.net
Member Avatar for rosstafarian
0
95
Member Avatar for pseudorandom21

C++/CLI @ runtime add a PictureBox to a tab control, I need to do this at run-time because they're to represent some data the user must be able to manipulate. I actually need them to be in some kind of scrollable panel on the tabcontrol. Any ideas?

Software Development c c# c++
Member Avatar for jonsca
0
149
Member Avatar for fragan01

Hello! When I build a solution for my program, it does not have any errors. [B][/B]However, in this particular screen (my menu screen), I cannot choose #1 (Cashier Module).[/B] What I mean is, when I enter 1, nothing appears. The choice 2, 3 and 4 do work, however. Can anyone …

Software Development c++
Member Avatar for fragan01
0
3K
Member Avatar for CodeAerial

HMm... already frustrated at it... But is there something wrong in my malloc? Everytime I try to display the record, it gives me random things as answer(see code below)? Was it that I didn't free it or was I wrong in declaring malloc itself? Thanks in advance. [CODE] #include <stdio.h> …

Software Development c
Member Avatar for CodeAerial
0
283
Member Avatar for jordan0420

Im working on my first big project, a GUI library for movie files (much like in itunes). so far i have the ability to list the movies title director and year in a list box as well as add movies to the database, however it is only text no actual …

Software Development gui python tkinter
Member Avatar for jordan0420
0
914
Member Avatar for gregarion

Hey guys , i am facing a problem using fprintf. Basically what happens is that , i will use it to read from an array and store the information in a txt file. The problem i face is that , for some reason , numbers such as "02 , 05" …

Software Development c++
Member Avatar for gregarion
0
101
Member Avatar for stephy1

[CODE] File file = new File(args[0]);[/CODE] what this line of code actually mean?

Software Development file-system java
Member Avatar for stephy1
0
375
Member Avatar for stephy1

I have 3 threads. 3 are going to do a different tasks , so different run() methods. How to overload run() method?

Software Development java
Member Avatar for stephy1
0
90
Member Avatar for scru

Sometimes IDLE crashes when trying to run GUI code. I already know the standard responses to this issue (use another editor, run from command line etc.). What I'm interested in is why does it do this? Does anybody have any information (or a link to info) on why this issue …

Software Development gui python
Member Avatar for richieking
0
235
Member Avatar for stephy1

I got error :At the constructor MyStackThreads "class , interface or enum expected" [code]import java.util.*; import java.io.*; class MyStackThreads extends Thread { Stack thestack= new Stack(); String expression; String splitexpr[]; MyStackThreads[j] { public void run() { try { DataInputStream dis=new DataInputStream(System.in); expression=dis.readLine(); for(int i=0;i<expression.length();i++) { splitexpr=expression.split(expression); thestack.push(splitexpr[i]); } } catch(IOException …

Software Development java user-interface
Member Avatar for stephy1
0
385
Member Avatar for Valaraukar

So for some reason I my brain seems be failing me :( Anyway....I have a cylinder object in 3D space and inside of the cylinder I have line objects originating at the origin (0,0,0) (which is also the centre point of the cylinder). I would like to find the exact …

Software Development c++
Member Avatar for Valaraukar
0
201
Member Avatar for boshu

Hi all, I am using a script which takes various command line options, does some zipping activities and publish a log file of what is has zipped. arguments: [CODE]zip_contents.pl -u content_name -s c:\contetn_path -u content_flag -m content.sender@mail[/CODE] When the log file is created I want that the given command line …

Software Development perl
Member Avatar for boshu
0
346
Member Avatar for srisrisri

Hello Can anyone tell me the way to reverse a string in C and only in """"C"""? How to get a string through one by one characters of the same? And if I use the following I get errors String name="hai"; len=strlen(name); for(i=0;i<len;i++) { scanf("%c",name[i]); } how to get name …

Software Development c
Member Avatar for minhajakhter
0
316
Member Avatar for chamnab

do anyone know how to write code to display time like in the window

Software Development c++
Member Avatar for jonsca
0
73
Member Avatar for chamnab

i want to write some code that can input only number or only character ? plz help me ???

Software Development c++
Member Avatar for jonsca
0
145
Member Avatar for Zvjezdan23

[CODE]// This program is supposed to figure out how much does a custom banner cost by figuring out the price for each letter and outputting it's total to the screen. #include <iostream> #include <string> using namespace std; int main() { double cost = 3.45, total; string banner; cout << "Enter …

Software Development c++
Member Avatar for Nick Evan
0
352
Member Avatar for jecris

A common problem when processing incoming text is to isolate the words in the text. This is made more difficult by the punctuation; words have commas, "quote marks", (even brackets) next to them, or hyphens in the middle of the word. This punctuation doesn't count as letters when the words …

Software Development java
Member Avatar for masijade
0
143
Member Avatar for jecris

Anyone have code with this?... Write a program to find the chain associated with any given number. Start with the given positive integer. This is the first number in the chain. Sort the digits (of the base 10 number) into ascending order, and also in descending order. Subtract the ascending …

Software Development java
Member Avatar for masijade
0
473
Member Avatar for mangopearapples

Hi, I was wondering how I can use this type of list: [url]http://palib-dev.com/manual[/url] On the left, there are expandable lists. How can I use them? Thanks.

Software Development java
Member Avatar for mangopearapples
0
144
Member Avatar for rookanga

Im trying to get a sales percentage program to work and im having trouble on the last part. My homework is to get the original price from the customer and then take the sales percentage off and show how much it is. Then after the first percentage is off take …

Software Development vb.net
Member Avatar for AndreRet
0
118
Member Avatar for roseworld

[B][COLOR="Red"][U]Face recognition using Two Webcam with OpenCV[/U][/COLOR][/B][CODE][/CODE] I am very new in OpenCv, and I am trying to use 2 USB webcams with OpenCV, so can anybody help me how I can start this and understand it in short time. best regards,

Software Development c++ webcam
Member Avatar for roseworld
0
187
Member Avatar for xXEJEarlXx

please help me. i need codes. How to Convert Dotted Decimal to Binary and Vice Versa in VB6. and a short explanation for the code.. please...

Software Development visual-basic
Member Avatar for AndreRet
0
375
Member Avatar for Insomaniacal

Hi everyone. I'm having a little bit of trouble getting a piece of code to work correctly here. Here is the code. [CODE]] filename = "./" + `random.randrange(0,9999999999999999999999999999999999)` + ".txt" f = open(filename, 'w') f.write(`data`) f.close f = open(filename,'rb') ftp = FTP('ftphost.com') time.sleep(5) ftp.login('user,pass') time.sleep(5) ftp.storbinary('STOR `filename`', f ) [/CODE] …

Software Development python
Member Avatar for jintujacob
0
241
Member Avatar for Allen 0108

I am working thru the Wrox book: [U]Beginning Programming[/U], and need some advice on getting a simple program to compile. I have Vista and use the free Borland C++ compiler. After entering in a simple C++ code, I was not able to get it to compile. When I attempted to …

Software Development c++ file-system windows-vista
Member Avatar for smTaqi
0
3K
Member Avatar for yassop

Hi all. I have a problem with my calculator. #include <stdio.h> int a, b; /* value entered by user */ char c, choice; int main() { printf("\nThis program is a calculator.\n"); printf("Enter your calculation: "); scanf("%d%c%d", &a,&c,&b); if (c=='+') printf("The answer is %d", a+b); if (c=='-') printf("The answer is %d", …

Software Development c
Member Avatar for yassop
0
241

The End.