64,152 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for Mike_11

Hi. I'm trying to make a simple question program, my first question doesn't work (if you enter the wrong answer/an answer that isn't an integer, you get stuck in an infinite loop). However, my second question works fine even though the code is quite similar. Sorry if I'm being a …

Member Avatar for AKMafia001
0
407
Member Avatar for tunlinaung

It is OK, if you write like this below : [CODE] delegate void mydelegate(); public class testing { mydelegate d1; string str ; public void btnStart_Click(object sender, EventArgs e) // Click Event { ThreadStart ts = new ThreadStart(StartServer); Thread t = new Thread(ts); t.Start(); } public void StartServer() { str …

Member Avatar for tunlinaung
0
293
Member Avatar for stevanity

I have just started out with Java. I have been programing with C and C++ for some years now. I have this problem. Im not able to call a non static method belonging to the main class from the static main method. This is the code: [CODE]public class Helloworld { …

Member Avatar for masijade
0
28K
Member Avatar for goldenpete

Hi, I am having an issue with OpenCV version 2.1, 2.0 on windows VS2008. I am attempting to open an uncompressed .avi video to grab frames from it. The VideoCapture class works to capture from an attached camera, and it compiles, making me think it is not a location/missing file …

Member Avatar for beano69
0
542
Member Avatar for masterofpuppets

Hey guys, Here's the problem I have: I am writing a server application in Java using the ServerSocket and Socket classes. I have an instance of ServerSocket which listens for connection and accepts them. The server runs a website that requires users to log in using an e-mail and a …

Member Avatar for masterofpuppets
0
1K
Member Avatar for Macko888

HI Everyone, Having a bit of trouble with some array`s... here is the situation: I need to get the contents of 1 array and compare them to another array and if numbers from the 2nd array are in the first array, i want to unset it from the 2nd array. …

Member Avatar for Macko888
0
116
Member Avatar for Sorcher

Hello guys, i got a small problem here. I can write and press "send" to submit a private message to a memeber, right... but if i refresh the page, the message gets sent again.. Anyone know a small php script i could put on top of the page to avoid …

Member Avatar for vibhaJ
0
107
Member Avatar for nocloud

I have a custom date class that is constructed in the following way: [CODE] date date_file("dates.txt"); [/CODE] I want to put this object into a new class as a private member, e.g [CODE] //the mem_data class======================================// class mem_data { public: mem_data(int,int,std::string); ~mem_data(); private: std::vector<reader> mem_store; int complete; date date_file; }; …

Member Avatar for mike_2000_17
0
278
Member Avatar for Besherek

Hey guys, I'm trying to update an existing site and I'm having a few issues with an array in terms of sorting the results of an array into a simple div layout. It currently works and the output is working fine. However I want to define a category as a …

Member Avatar for Besherek
0
178
Member Avatar for drax12

Hey guys, I'm want to retrieve results from the database, where datetime picker given value, is equal to database value. var _check = (from day in Check.tbl_employees where day.d_from== _frm && day.d_to == _to select new { day.desg_id, }).FirstOrDefault(); datetime picker gives a value with its time,but i'm only interested …

Member Avatar for drax12
0
714
Member Avatar for Zaffron

Obviously, it doesn't work. So what I'm trying to do (this is all very rough at the moment, merely an experiment/test to see if I can get it to work) is have a method under the player class that, when called, takes the value of the requested item, sees if …

Member Avatar for Zaffron
0
113
Member Avatar for MasterBerd

Hey Guys! Below is my code of Battleship game. I keep getting "Process terminated due to StackOverflowException." error. It keeps pointing to [CODE] char[,] Grid = new char[10, 10]; [/CODE] and i have no idea what it's asking to fix. Please help me. Thanks! [CODE] using System; using System.Collections.Generic; using …

Member Avatar for MasterBerd
0
1K
Member Avatar for maikens

Hi, I am having a problem with an assignment for a C++ course. I have to make a Game of Life simulator (predator and prey). There are two organisms, lion and ant, and the lions eat the ants. My problem is that for some reason I can't fathom, the lions …

Member Avatar for daianahoney
0
319
Member Avatar for WolfShield

So, I am working with some code I don't understand. Here is the file: [CODE=Python] import sys import os def change_ext(directory, old_ext, new_ext): for f in os.listdir(sys.argv[1]): base, ext = os.path.splitext(f) if ext[1:] == sys.argv[2]: os.rename(f, "%s.%s" % (base, sys.argv[3])) if __name__ == '__main__': if len(sys.argv) < 4: print "usage: …

Member Avatar for WolfShield
0
430
Member Avatar for didi00

Hi guys, I'm trying to modify the plaincart for my needs but I have problem with the cyrillic characters. When I call the data from the database, all I get is ???????. My database is ok, the collation is utf8_unicode_ci and I can see my characters correctly in phpMyAdmin. for …

Member Avatar for didi00
0
608
Member Avatar for annetria

I'm receiving the following errors when trying to read from a file: java.io.FileNotFoundException: rates.txt (The system cannot find the file specified) at java.io.FileInputStream.open(Native Method) at java.io.FileInputStream.<init>(FileInputStream.java:120) at java.util.Scanner.<init>(Scanner.java:636) at MortgageCalculator4.submitButtonActionPerformed(MortgageCalculator4.java:187) at MortgageCalculator4.access$000(MortgageCalculator4.java:20) at MortgageCalculator4$1.actionPerformed(MortgageCalculator4.java:70) at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995) at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318) at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387) at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242) at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236) at java.awt.Component.processMouseEvent(Component.java:6288) at javax.swing.JComponent.processMouseEvent(JComponent.java:3267) at java.awt.Component.processEvent(Component.java:6053) …

Member Avatar for annetria
0
136
Member Avatar for bibiki

hey there again, I am trying to build a small mechanism that lets me store product names and prices on a produktet.txt file. the file should hold lines as follows: product1 price1 product2 price2 . . productN priceN So, I built a small panel with three rows and one column. …

Member Avatar for bibiki
0
146
Member Avatar for Warl30ck

OK so I'm trying to parse simple URL's from a whole char chunk using strtok but always keeps giving me an unhandled exception error . SO here is all the code in C++ : [CODE] char* str = "(%/\%)google.com(%/\%)hotmail.com(%/\%)nananna.org(%/\%)" char *url[]; while(str != NULL){ url[0] = strtok(str, "(%/\%)"); if (DownloadFile_1(url[0],szPath) …

Member Avatar for Narue
0
317
Member Avatar for WildBamaBoy

Right now I only need to be able to send a 100kb JPEG photo. I tried Google and found a couple of things but their code only threw exceptions so maybe what they've done is not appropriate in my situation. This is an attempt at a remote screen viewer. If …

Member Avatar for oredigger
0
186
Member Avatar for dyingatmidnight

hey there, what I want to do is transform search results into hyperlinks. This part isn't really the hard part I don't think. But what I would like it have a generic details.php page which would bring up everything associated with the url you clicked. For example, my database is …

Member Avatar for pbcomput
0
161
Member Avatar for reza.adinata

Hi, I am new in C, trying to create a simple C file, that assign a value for a struct member with the type of string. I can't figure out why it said error : string.c:20: error: expected expression before ‘{’ token, but I don't find any syntax error.. [CODE] …

Member Avatar for reza.adinata
0
220
Member Avatar for Fresco Vivir

Greetings everyone i'm new to php and this is what i want to do if you can help me , i have a DB on my web server and there are two column one for the name of the product and the other for the id of the product , …

Member Avatar for Jiaxin
0
104
Member Avatar for ayagi

hi, i have a problem. As i need to export my report to PDF. In Crystal Report Viewer the Alignment are perfect.. But when i export into PDF the Alignment changed entirely.. In the Report im using all the Controls ( Text,Line,Box). Thanks in Advance.. thanks in advance

Member Avatar for mnjogin
-1
109
Member Avatar for vedro-compota

hi programmers!) Please help me understand this - as I understand from practice - the getting SIGALRM by process is ends the process - but I can't find the explanation of this guess. for exp. - I have code - [CODE]int main(void) { /* Установить будильник */ sleep(1); if((alarm(5)) > …

Member Avatar for vedro-compota
0
114
Member Avatar for Sadun89

Dear Friend..... I want to make web site that it want to plugging with facebook..... In other words, If i type & submit something,I want to publish in Facebook wall (if i can publish in selected person's walls its very worth) it like what the youtube done after some video …

Member Avatar for Sadun89
0
282
Member Avatar for suley04

Hi Everyone, I have a BIG problem right now. I am currently learning ASP.NET to fulfil my job role, as an IT Manager. Although I have programming experience in other languages, I have never done ASP.NET before. I am currently working on a website called [url]www.packagepets.com[/url] . I recently uploaded …

Member Avatar for jfarrugia
0
314
Member Avatar for matthewkeating

Hello all, I have just converted from Windows to Mac and have been a longtime user and fan of NotePad++. I had heard of a way to run it on a Mac but am having the hardest time finding it. Is this possible? And if not, what are some FREE …

Member Avatar for dekarvn
0
219
Member Avatar for danielgr

Hi, When I view images on my development PC they look fine, but when I view them on other PC's, the images are sized differently and often get cut off. I've tested this on multiple PC's and the images always get cut off. I've attached the images from my PC …

Member Avatar for danielgr
0
209
Member Avatar for ayagi

i need to update my data using stored procedure here is my code : [CODE] Try con = getconnect() con.Open() sqlcmd = con.CreateCommand sqlcmd.CommandText = "Select * from EmployeeProfile where EmployeeID = '" & txtEmpID.Text & "'" daemployee.SelectCommand = cmdemployee1 daemployee.Fill(dsemployee, "EmployeeProfile") If dsemployee.Tables(0).Rows.Count <> 0 Then txtEmpID.Text = dsemployee.Tables(0).Rows(0).Item("EmployeeID") …

Member Avatar for ayagi
0
316
Member Avatar for DaMoose75

I have a problem with this simple Win32 application I am trying to make. As you can tell by the title, the function CreateWindow() always returns 0, which indicates failure. Here is my code. [CODE] int MessageLoop() { MSG msg; ZeroMemory(&msg, sizeof(MSG)); while (GetMessage(&msg, 0, 0, 0)) { TranslateMessage(&msg); DispatchMessage(&msg); …

Member Avatar for DaMoose75
0
3K
Member Avatar for epicbeast9022

Hello, I cannot read a file, config.cfg, in the current directory on MacOS X 10.6. I'm running a console app. Can anybody tell me what I'm doing wrong? (By the way the getline() function returns no string.) [CODE] #include <iostream> #include <fstream> #include <string> using namespace std; int main(int argc, …

Member Avatar for epicbeast9022
0
382
Member Avatar for LogicallyInsane

So after pretty much giving up on programming (I think I should say that I kinda forgot about it actually) and not checking Daniweb, I decided after a few months of doing other things I'd come back to Daniweb and start trying to program once again. After skimming through "Learn …

Member Avatar for LogicallyInsane
0
86
Member Avatar for b0tz

[CODE] String ip = "www.google.ro"; String pingResult = ""; String pingCmd = "ping " + ip + " -c 4"; String s; try { Process p = Runtime.getRuntime().exec(pingCmd); BufferedReader stdInput = new BufferedReader(new InputStreamReader(p.getInputStream())); BufferedReader stdError = new BufferedReader(new InputStreamReader(p.getErrorStream())); // read the output from the command System.out.println("Rezultat ping:\n"); for …

Member Avatar for b0tz
0
224
Member Avatar for warlord902

I am developing a project which is going to use this database table, but I am not getting the complete normalized form of this table. I am not practically strong with normalization so every time I try to make it I end up in no where. The table is attached …

Member Avatar for smantscheff
0
179
Member Avatar for Spyzker

Parse error: syntax error, unexpected T_CASE in /home/redlimbc/public_html/M2H/article.php on line 757 [CODE]<?php break; case "yorumonay": $id = $_GET['id']; $yorum_adsoyad = str_replace("'", "'", $_POST['yazan']); $yorum_email = str_replace("'", "'", $_POST['mail']); $yorum_yorum = str_replace("'", "'", $_POST['yorum']); $tarih = date("d.m.Y"); if(($yorum_adsoyad == "") or ($yorum_email == "") or ($yorum_yorum == "")){ echo '<script type="text/javascript">alert("Bo? …

Member Avatar for diafol
0
124
Member Avatar for Jollyyy100

Hi, im currently designing a form on dreamweaver and it allows a client to enter their Name, Email and Comments. At the same time i want this data to store in my mysql database which i created. The php code that i used is shown below, but the problem is …

Member Avatar for diafol
0
155
Member Avatar for anilopo

is there a way to do a backwards loop in matlab? i tried: [CODE]for j = end; -1; 1[/CODE] - but it's not going, it stays in "end"...

Member Avatar for anilopo
0
60
Member Avatar for element432

Im trying to do a exercise in one of my books and it wants me to use a function to get the factorial of a number entered by the user. Ive tried several different ways and they either get me numbers that make no sense or say if I entered …

Member Avatar for element432
0
128
Member Avatar for wazakiller

there is an error somewhere in my code, but i cant work it out. could one of you give it a quiq look? <html> <head> <script language="JavaScript"> function bereken() { j = parseInt(fx.s.value) p = parseInt(fx.j.value) s = parseInt(fx.p.value) while (j > 0 ) { j = j-1 r = …

Member Avatar for wazakiller
0
101
Member Avatar for autorunman22

im a newbie and im learning java just week ago. I wonder how i cant make the ball bounce in one axis only (the X axis) im not good in logic:( and i want that logic to be in one event. [code]if(x<0){ ++x;//go right }else if(x>500) {--x;//go left } [/code] …

Member Avatar for autorunman22
0
164
Member Avatar for Naveed_786

I am using oracle 9i database with VB.NET when i am trying to insert record in my PR_REC table it gives me error "ORA-01722 Invalid number" here is my insert statement and the structure of the table [CODE]com = New OleDbCommand("INSERT INTO PR_REC(pr_no,item1,price1,qty1,item2,price2,qty2,item3,price3,qty3,item4,price4,qty4,item5,price5,qty5,item6,price6,qty6,item7,price7,qty7,item8,price8,qty8,item9,price9,qty9,item10,price10,qty10,Pur_reason,pr_date,Status) VALUES ('" & Me.txtprno.Text.Trim & "','" & …

Member Avatar for Naveed_786
0
415
Member Avatar for niranga

Hi All, Is it possible to bind an array or a Vector with a event listener? For an example if we add an element to the Vector or remove from the Vector, can I use an event listener to track the changes? Thanks a lot in advance. Cheers..!!

Member Avatar for niranga
0
998
Member Avatar for xxgrplayer

Hello guys, i am a very beginner php developer (i know only the basics) and i am trying to create a website about betting which will retrieve info from mySql databases. the problem is that i have stored some variables (which are written in greek) in databases and then when …

Member Avatar for xxgrplayer
0
2K
Member Avatar for galhajaj

Hello, i have a little dificulties in the area of object-oriented programming i guess... i am making a chess-like game i created the classes "board" and "square" (the square inherit from picturebox) now - in the constructor of the board i create 8X8 squares inside it all the program is …

Member Avatar for galhajaj
0
217
Member Avatar for pseudorandom21

Sooo... Every DLL injection result I've read so far only uses a pre-made DLL, loads it into another process and says "darn I'm good." They do absolutely NOTHING useful and a couple of them are rip-offs of one another only using a different programming language. Google has failed me! Once …

Member Avatar for pseudorandom21
0
188
Member Avatar for belper

Hello, Could anyone help me with next problem: Visitors come to a website through a Clickbank affiliatelink http: //nick.vendor.hop.clickbank.net But they will land on different websites based on an URL parameter, for example http: //nick.vendor.hop.clickbank.net?x=prod1 they’ll go to www.websiteA.com http: //nick.vendor.hop.clickbank.net?x=prod2 they’ll go to www.websiteB.com http: //nick.vendor.hop.clickbank.net?x=prod3 they’ll go to …

Member Avatar for belper
0
867
Member Avatar for pecet

I've been trying to solve SQL exercises from [url]http://www.sql-ex.ru/[/url] for some time. You can find database description below: Short database description "Computer firm": The database scheme consists of four tables: Product(maker, model, type) PC(code, model, speed, ram, hd, cd, price) Laptop(code, model, speed, ram, hd, screen, price) Printer(code, model, color, …

Member Avatar for pecet
0
389
Member Avatar for didi00

Hi guys! I'm trying to make a PHP mailer and I have a little problem with the eregi() function. This is the code: [code] if (!eregi("^[A-Z0-9._%-]+@[A-Z0-9._%-]+\.[A-Z]{2,6}$", $senders_email)) { $error = "1"; $info_error .= $lang_invalidemail . "<br>"; } [/code] and it gives me this error: Deprecated: Function eregi() is deprecated in …

Member Avatar for didi00
0
168
Member Avatar for ifiok.idiang
Member Avatar for skald89

What I thought this code would do is, if i typed non-numbers it would continue prompting me until I finally input a number which it then will output the word "one" on the page. What it does is if I type a number first it outputs the word "one" on …

Member Avatar for skald89
0
106

The End.