199,112 Archived Topics
Remove Filter ![]() | |
Can anyone tell me if there is any function for replacing multiples substrings within a string. For instance we have this function call to replace multiple appearances of the same substring: [CODE=python] newLine = line.replace(';', '_') [/CODE] Here I replace all appearances of ';' with '_' But what I need … | |
I am drawing on a bit my, then re-loading the bitmap(to erase it) then drawing on it again at 100Hz. I am getting flicker. Is there a way to reduce this flicker? Or a better way to do this than to reload the bitmap everytime? Thanks. | |
Hey, ive written a piece of code which reads from a file called test.txt. all it does is use strtok to seperate the data from the spaces because there are alot of them, and then print them out, this worked fine when i did a test for just 1 line, … | |
Hello, I have a datagrid with 2 columns.Both the columns have textboxes where user will enter data.And at the end of the grid there will be button in insert all the data into the table. I have user xml variable in my stored procedure. In the gridview I have kept … | |
Logic circuit builder is a software that simulates AND,OR,XOR gates.I want to give it an attractive GUI wherein gates can be dragged/dropped.How do i accomplish drag and drop in Java?For instance if there is a buuton with an AND gate.if the user clicks on it and drags the mouse pointer … | |
I am having difficulty with nested loops. I am attempting to create a program that has the user enter monthly data during the course of a three year period. here is what I have so far. [code=C++] #include <iostream> const int Months = 12; const int Years = 3; int … | |
Hello, I don't know any Perl but I do know Java. I am studying about Push down automatas at the moment and wanted to make a simulator for myself. I have found some code in Perl that does it but I do not know how I can go about using … | |
I.ve problem with java image processing.I've to convert 2d array into image.I'm using the loadPixels function, but it doesen't work.The Image is never shown on the label. Please help, here is the code of the loadPixels function: [CODE] public static void loadPixels(JLabel label, int[][] pixels) { // 1. convert to … | |
Hi Guys, Im currently doing a website now that has a lot of png images in it. And because of that, I had to use pngfix for IE6. i have recoded the main page so that the png images are all in the css file. in the menu for the … | |
i'm trying to control four separate lighting arrays using a timer overflow interrupt to control four pulse width modulations. at the same time i want to be able to control the pwm frequencies using serial communication. i'm using a version of pic lite for my compiling and can compile my … | |
Hello, I have a file with the data as shown below: ATOM 2 CA ARG A 1 6.324 32.707 50.379 ATOM 13 CA THR A 2 5.197 32.618 46.826 ATOM 20 CA ASP A 3 4.020 36.132 46.259 ATOM 28 CA CYS A 4 7.131 38.210 45.919 I am a … | |
i need help removing spaces from a string..how do i go about this?? i have to report back the number of spaces too but ive been able to do that thnx (i dont want to use any of the string functions in the string library) [code] #include <iostream> int stripspaces(char … | |
Ive been given a task where i read in a line of text from a file, and then need to seperate that line into seperate strings, ive done this however I also need to keep some attatched... the file contains "abc def ghi jkl mno", this is read in using … | |
I have been working on this assignment for a while and cant get the end result to work. Can anyone help? Assignment [QUOTE]Write a function called sumTo that takes as arguments two integers. Your function should use a loop to sum all of the numbers between the two (This includes … | |
Hey guys hopefully this is just a quick question. I've a form that is sending data to a PHP script. The form has the following textbox: [CODE] <input id="quantity1" name="quantity1" type="text" value="" /> [/CODE] Whenever it is posted I do the following: [CODE] function isInteger($val) { if (is_int($val)) { return … | |
Sorry for asking the topic that asked before... but im still dont know how to use that.. Below is an example create by me.. I hope that someone can tell me which part have to fix ... This is the header file: [CODE] int check_SkipCard (string input) { int SkipCard=0; … | |
As a beginner VB 6.0 user, i have tried to make a simple database-link VB project. There were problems when i used a Microsoft Access Database which have some combo-boxes field (made by look-up wizard options). Is there any way for me to make the combo-box field in the database … | |
I have a problem with bulding a program to store a family record (genogram), this record consits of : name, birthday, married? and number of child. What is the best way to store this record??? Could you give me some example about some task on this structure : Input name … | |
Hello! This is my first post here. :) I'm trying to use this regexp pattern to filter form input (the message body) that will be emailed to me from a "contact us" form. The pattern is (i removed the punctuation and other special chars for the sake of ease): [CODE]$clean['match'] … | |
I am using a List where I wonder how it is possible to find the MaxValue searching trough Value1[0] until Value1[3]. In this case it should return: 12 I have found a ::Max function but this will only consider the 2 values inside the paranthes wich then will return: 100. … | |
I am pulling dates from my database using this code: [code] <% Set rs = Server.CreateObject("adodb.recordset") cmdTemp.CommandText = "SELECT First, Last, Anniversary, Ext FROM Directory " _ & " WHERE Month(Anniversary) = " & showMonth _ & " ORDER BY Anniversary" rs.Open cmdTemp, , AdOpenStatic Do Until RS.EOF AnnName = … | |
I am using this in the std:: to check for the first occurance of " " backwards (rfind). If I go managed .NET, I wonder if there is any simular method for this using str-> [code] std::string::size_type index2 = str.rfind(" ", index - 1); [/code] | |
I am coding a unit in Delphi 2007 and everything has been working fine. Suddenly, pressing the "return" key merely moves the cursor to the next line instead of throwing a new line I switch to another program (word processor) and that program works fine. I have rebooted, but that … | |
OK this is driving me mad and it needs to be done for a deadline. It is just a simple query to update a few database fields. Here's the PHP for it. [code=php] $sql5 = "UPDATE videos SET title='$new_video_title' WHERE artist_id='$i' "; $query5 = mysql_query($sql5) or die( mysql_error() ); $sql6 … | |
How would I reuse functions in C? I've tried simply sticking them in a [icode]#include <myfunctions.h>[/icode], but that didn't work... Any (complete) suggestions/links on how to do this? I googled some and found this: [code]The way to write a header file is: functions.h: int sum( int a, int b) ; … | |
Hey all, i'm a freshmen in college who is taking Intro to Computer Science with C++ and i'm just a beginner when it comes to programming so i have a problem. This is our assignment: [B]You are to write a program which inputs a Celsius temperature from the user, converts … | |
how can i get a name from database according to the letters entering on the textbox using onkeyup() | |
Hey I am trying to created a dice game that roll the dice twice and then ask the user if he/she thinks the next two rolls will be more than or less than the first two. After the third roll the program is then suppose to ask the user if … | |
hi all, I have been trying to convert my phpnuke setup over to mysqli.I am running it as mysql at the moment on apache 2.2.9, php 5.2.6 and mysql 5.0.51b.I have attached the unmodified file as i have been playing for a week and have got no closer. is it … | |
Hello, I'm a beginner VB 6.0 user, and I would like to know something about it. Is there any difference in coding (for the same purpose) between a database oriented VB projects using the Data Control and ADO? How much are the differences, if you plz could explain it briefly. … | |
Hey all! i need to write a tuple into a file.. it was to work something like this: ---- [ICODE]c.execute('select * from valores') for row in c: file1.write(row)[/ICODE] ----- i already tried to do str(row) and everything, but nothing seems to work... | |
Hello, How can I find out the day of week, using given date using php or mysql, I have searched for it on google and find out a mysql function DAYNAME but when I used this function the output is "Resource id#3" please help me in solving this. Thanks | |
Hey everyone, I have a project in which I need to program a Khepera robot too navigate through a maze and find a beacon on the first run. *On the second run it must go to the bacon via the shortest path. *The grid is a 4*3 (so i have … | |
I am having a lot of trouble with a Divide and Conquer algorithm to count the number of white cells and white cell blocks in a grid of black and white cells. Here is my grid file "cells.txt": w = white cell b = black cell [CODE] bbbbbbbbbb bwwwwwbwwb bbbbbwbwwb … | |
Hi I am trying get user info from the database into the textbox when i select Usename Which is stored in the drop down. so could any help how to get all usernames into dropdown and when i select any usenames i should get all details into the text box.........please … | |
Hi, Badly need help again. I have completed one project and have tried making a setup file using Microsoft Visual Studio Package and Deployment Wizard. It showed no error. I ran the setup file but could not as I saw a message(Error?) and after completing the setup I tried running … | |
Dear friends, thanks in advance for reading this: I wanted to set up membership roles for my application. I am using Visual Studio 2005 Web Development. However, I could not enter into the security tab under ASP.NET Web Site Administration Tool(In a web interface look)... they threw me this: There … | |
you mean newsletters... that can be achieved by any server side scriptings...just browse google for free scripts... all the best. | |
Hi All, I want to know that, if i have developed a project using asp.net c# and i also in asp.net and code in vb.net, can i use any form of vb.net code in c#.net without any change? :) Please increase my knowledge. | |
HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly. Plz tell me how to solve this.. Am a new to this.. | |
every time i make my own rounding routine with precision, i see my compiler suggesting a function long double round(long double x, int precision); so i was wondering if someone knows what library it comes from, i surely wasn't able to find it... thanks | |
![]() | I am trying to write this program that requires the following for C++: Write a c++ program to simulate the roll of a die. In principle, each of six possible outcomes is equally likely. -The program will prompt the usesr to enter the # of times the die is to … ![]() |
pl.help me out on this : i need to calculate balance amount....however...i am not able to calculate it. C i have coursefees then when i click on installment 1 and enter the amount my balance amount textbox should reflect the coursefees- installment1 total similarly when i click on installment 2 … | |
Hello Friends... I am completely newbie to XML..And I am a php developer... I heard that XML can be used in the replacement of our databases...Is it right??? What is the purpose of XML to be used in our project....What are the advantages and disadavantages of XML...And How to use … | |
Hello, I am developing a website for which I am designing a signup form, the problem is a user fills the form and miss a field when they go back to enter that field it cleans up all the remainig field and they have to fill the whole form again. … | |
here is my calculator. it works fine, but for the love of god i cant figure out how to get the screen at the top, centered while the rest of the buttons follow the gridlayout pattern. any way? [ICODE] package Calculator1; import javax.swing.*; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.*; public … | |
Looking to rewrite the pages of a company I work for, [url]www.whatsshopping.com[/url]. The product pages produce URL's as such: [url]http://www.whatsshopping.com/productsincategories.php?ban=352&cat=LG483BLK[/url] Looking to if possible, rewrite the pages to reflect the product name or category name in the url. | |
Hello, Here's the details: User inputs sentence Program checks sentence for 3 magic words ("chicken", "egg", "rooster") Program keeps count of every magic word found and displays results Here's my code: [code=c++]#include<iostream> #include<string> using namespace std; const string chicken( "chicken" ); const string egg( "egg" ); const string rooster( "rooster" … | |
I am trying to dynamically create some shell script and run it (but don't know how!). I want to read in a string from a file (e.g. '[icode]echo $myvar[/icode]') then run that string (and, yes, myvar IS an existing variable). Can it be done? I have thought about writing it … | |
I am working with fifo module...I actually found the basic code on DaniWeb, just made a few changes to it... There are 2 main sources...first one is called fifoqueue which consists of basic fifo functions i.e. qu, dequ, isEmpty and a couple more...the second one is called packetstructure which is … |
The End.