64,152 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for vileoxidation

Hello! I am taking a scientific computing class, where we are doing some programming in C, and right now our assignment is to add commentary to an existing program explaining what every line does (starting at the line that says Start here!). As you can see in the code below, …

Member Avatar for vileoxidation
0
123
Member Avatar for jonsca

I'm having a hard time geting access to properties in the var output of the query (I know I can use foreach on the result that I've got but I'm not sure which elements values I'm accessing). I think my query is just plain wrong, so I'd appreciate some help. …

Member Avatar for jonsca
0
219
Member Avatar for AutoPython

Okay, I am confused on the global statement. To my knowledge it lets you easily access variables from a function to be used in the session. Now someone said that it's useless and you shouldn't use it in your code. Is this true?

Member Avatar for AutoPython
0
331
Member Avatar for Gerald19

Hello, I am working on a website using a MySQL database, certain pages contain tables from the database. Also there is an admin where someone can edit (replace) values in the table. Everything is working, but I have one problem. A row in the table is named 'Best Moment' which …

Member Avatar for Gerald19
0
3K
Member Avatar for carlcarman

When I execute my functions the first one works fine and the second is called because I get my alert box but the second function does not execute. Any ideas why? Any input is appreciated. function changeFont() { <!--alert("changeFont function");--> document.getElementById("q4").style.fontStyle ="italic"; } function changeFontBack() { alert("changeFontBack function"); document.getElementById("q4").style.fontStyle="normal"; } …

Member Avatar for carlcarman
0
89
Member Avatar for Altairzq

Hello, I thought the programming gurus in this forum could lend me a hand understanding recursion in Javascript. I'm following an online Javascript tutorial ("Eloquent Javascript", I recommend it to anyone) and chapter 3 shows this function: [CODE]function power(base, exponent) { if (exponent == 0) return 1; else return base …

Member Avatar for ~s.o.s~
0
132
Member Avatar for xuexue

please could you give me a code the simplest code possible for a pagination, i have one however, it does not display the next item in the database....

Member Avatar for diafol
0
101
Member Avatar for JayGeePee

I was wondering if someone could tell me how I can set a default image to auto increment, when one of my members sign up. I cant figure out how to set this in phpmyadmin. I could do it manually, but I'd rather it be automatically.

Member Avatar for diafol
0
214
Member Avatar for leverin4

I'm running into an issue with a program. I need a method that takes a string and returns every possible combination of upper and lower case letters for that string. For instance, cat would return: cat caT cAt cAT Cat CaT CAt CAT The string entered could be any length …

Member Avatar for nomemory
0
795
Member Avatar for vlady

hello, pls can somebody show me a way how to solve the following exercise: A number, a, is a power of b if it is divisible by b and a/b is a power of b. Write a function called is_power that takes parameters a and b and returns True if …

Member Avatar for vlady
0
3K
Member Avatar for arcticM

realy desperate here.. :'( my prog is getting data about problems (computer/electricity..ect (not real C problems)) from txt file..and every line in file has a different problem..so I made one PROBLEM problem; (object) and in my getProbDetails() function I'm getting the first line..reallocing to add one more object (creating array …

Member Avatar for arcticM
0
171
Member Avatar for sfuo

Hey I was wondering how the string class is able to output its self the way it does. For example: [CODE]#include <iostream> #include <string> using namespace std; int main() { string testString; testString = "Hello"; cout << testString << endl; system("PAUSE"); return 0; }[/CODE] If I were to try to …

Member Avatar for mrnutty
0
253
Member Avatar for sid78669

Hey Guys, So I'm working on an ASP page and I am making use some select statement. Now, I need to specify a where clause and make the only condition in there optional, i.e.: [CODE=SQL] SELECT * from table where Upper(name) LIKE "SID" [/CODE] I want to make [CODE=SQL] where …

Member Avatar for sid78669
0
139
Member Avatar for TryingToDo

1. I have a simple application, which uses a html table to represent the data retrieved from the database. How can I add to each row from the Html Table, a submit button. The button can be something like delete or modify the dates from that specific row, so I …

Member Avatar for TryingToDo
0
127
Member Avatar for Sobakaa

Hi, guys, i need some help, as i can't find a mistake in my code for some hours. I'm expiriencing a problem in function makeCodes, which should make huffman codes for my symbols. In my head this works just fine, recursively making codes, but my Visual Studio crashes on the …

Member Avatar for Sobakaa
0
88
Member Avatar for chico2009

Hi All Could you please help me with the following, #Convert C to F def Tc_to_Tf (): Tc = input ("What is the Celsius Temperature ? " ) Tf = 9.0/5.0 * Tc + 32 print 'The temperature is ', Tf, ' Degrees Fahrenheit' I get NameError: name 'Tf' is …

Member Avatar for chico2009
0
195
Member Avatar for sonygamer

Hi everyone, I have to write a code that finds and prints all prime numbers from 2 to whatever number the user inputs, be it 10 or 10,000. So far what i have is this: [code=cplusplus] #include <iostream> using namespace std; int main(){ int n,p,t,limit; cout<<"input the limit:"; cin>>limit; //outer …

Member Avatar for ashen77
0
151
Member Avatar for ktkevin1222

I'm fairly new to coding VB 2008 I need help converting a text document with a type of code in it. One line looks like this: 52.000000, 400.000000, 1.3107711, 0 I need to convert that to an xml file that looks like this: - <CuePoint> <Time>11619</Time> <Type>event</Type> <Name>Marker 01</Name> - …

Member Avatar for ktkevin1222
0
226
Member Avatar for sonia sardana

I want to convert VB.Net to C# code VB.NET- [code] Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Try Dim lCount As Integer For lCount = 1 To 5 ListView1.Items.Add(lCount.ToString) Next Catch ex As Exception MsgBox(ex.Message) End Try End Sub Private Sub Button1_Click(ByVal …

Member Avatar for DdoubleD
0
234
Member Avatar for jingo1126

ok i can inverse the code like 1234 to 4321..but when i applied jmp and cmp i dont know what goes wrong with my data.. code without loop [code] .model small .stack .data .code start: mov ah,1 int 21h push ax mov ah,1 int 21h push ax mov ah,1 int …

Member Avatar for mathematician
0
105
Member Avatar for TechSupportGeek

Hello again guys, this time I need help with the [B]FormClosing()[/B] Event in the Picture Viewing application I made. I wanted it to prompt the user before closing the form (if he had any unsaved changes) and I did it without help. But, the bad thing is, when someone saves …

Member Avatar for sknake
0
246
Member Avatar for jefanot

Hello, I really need help. If anyone could, please tell me what I'm doing wrong. Well, I'm making this program that asks if you're happy. Then if you don't answer yes, it will ask the question again until you do. I thought that it would be fun to have a …

Member Avatar for William Hemsworth
0
119
Member Avatar for TenaciousC22

I am pretty new to C#, but I do have some experience with programming ("some" being the operative word here). I am wondering what is the best way to completely exit out of code at a certain time. For example, I am writing an application to read in a Photoshop …

Member Avatar for sknake
0
102
Member Avatar for Stefano Mtangoo

Don't get me wrong, I don't ignore the power behind CMSes. I want to make a Database driven contents. Here is the approach I want to take, correct me/Add opinion as you it! 1. Integrate TinyMCE editor for wariting contents (WYSIWYG) 2. Have database with table contents and three columns …

Member Avatar for Stefano Mtangoo
0
86
Member Avatar for MrNoob

hello i was reading today some stuff abt bitfield but here in this program I understand most of it but there unnamed fields inside the structure book says its stuff for allgiment or something like that i dont rlly get what does it do [code] /* fields.c -- define and …

Member Avatar for codeguru_2009
0
145
Member Avatar for brando|away

I'm trying to crop an image: [code] Bitmap bmp = (Bitmap)pictureBox1.Image; Bitmap cBmp = bmp.Clone(croppedAreaRectangle, bmp.PixelFormat); pictureBox1.Image = cBmp; bmp.Dispose(); [/code] It's partly working, but the image result is smaller, and from a different area out side the selected cropped area. So what's wrong?

Member Avatar for Diamonddrake
0
93
Member Avatar for justted

Hello everyone, I paid for this script which is a community that offers its members the chance to get a club and joijn other members clubs! However, when people try to join a club they getb this error: Parse error: syntax error, unexpected T_PRIVATE, expecting ']' in /home/cyberpet/public_html/club_join.pro.php on line …

Member Avatar for nasado
0
942
Member Avatar for KonkaNok

Hi, I noticed a few snippets recently where a size_t variable was used for array indices, and after searching around I'm still not sure what the obvious advantage of using a size_t variable over a typical int would be.. To clarify, what would be the difference between this: [code=cplusplus] for(size_t …

Member Avatar for KonkaNok
0
148
Member Avatar for timon_zed

Hi there, I have a servlet which is meant to retrieve data from the database by compairing the number entered via a web form. The trouble is that, it only gives me the last record in the database and not any other record. I have 5 records in the database …

Member Avatar for timon_zed
0
143
Member Avatar for Tommy_101

Hi, I've been trying to create a program that gets wikipedia pages, and lists all the links found in the page source. I've used the urllib.urlopen() method to do this, and unfortunately I've run into a little problem. Instead of getting the actual page like say the main page, or …

Member Avatar for Tommy_101
0
208
Member Avatar for kyumi419

hello~ Write a program that will display a pattern depending on n. Assume n as a one digit odd number. Example: if n=9, display *000*000* 0*00*00*0 00*0*0*00 000***000 how will i start doing this type of problem? ^^

Member Avatar for kyumi419
0
205
Member Avatar for crash override

I've been trying to get started with sockets programming. However, when I try to use the getaddrinfo and freeaddrinfo functions, my linker complains that they are "not declared in this scope" and that they are "unused variables". I have checked the header (ws2tcpip.h) and the headers appear to be declared …

Member Avatar for ndarkduck
0
4K
Member Avatar for papanyquiL

Hi everyone. Basically what I want to do is search for a specific *.exe file upon initialization of my application. The *.exe file that I want to search for happens to be a .NET debugging tool. When / if my application finds this file, I want it to automatically close …

Member Avatar for papanyquiL
0
206
Member Avatar for MattyRobot
Member Avatar for ddanbe

Talking about a shoebox type of database here. Would like to make a nice interface in C# for it. Typically something around 50 records or so. (e.g. my wine cellar;) ) To use a genuine SQL DB seems to me like a bit of an overkill. Could use a flat …

Member Avatar for ddanbe
1
1K
Member Avatar for sftwr21

I'm a noob when it comes to C programming. I wrote a simple program that runs an infinite for loop. But inside that loop I wanted to create another loop to stop the user three times after entering incorrect passwords. I tested from different angles it seems like the infinite …

Member Avatar for sftwr21
0
214
Member Avatar for kained

Right i'm in the process of designing a web page for a property company and the owner has requested a random property be displayed each day. I have modified a quote of the day script to work with a filemtime method but its not working and im stumped, fairly sure …

Member Avatar for kained
0
187
Member Avatar for Graphix

Hi, I am currently writing a chatprogram, and it works fine in FF but it doesnt refresh as it should every 1500ms (set with setInterval("retrieve_messages()",1500) in body tag) in IE. The object ajax is made in previous code. I wrote the following code: [code] function retrieve_messages() { // Checks wether …

Member Avatar for Graphix
0
187
Member Avatar for empoor

Hi. I tried looking for this problem on Google, and found a lot, but nothing that actually seems to work. I basically have a search script that works fine when using one keyword, but when one uses more than that, it returns every single row per keyword. So a search …

Member Avatar for dasatti
0
218
Member Avatar for iwaqasi

Hi, I am working on a Project that has to search some specific folders and inside those folders I want to check if any file resides. I used the following techniques but they are not working if I need to connect to the machine as USER: [CODE] If Directory.Exists("\\" & …

Member Avatar for samir_ibrahim
0
132
Member Avatar for Stefano Mtangoo

Hi All, I need to make a PHP word editor for writting notes that will have buttons like one for wordpress. How do I start it? Is there readymade class that I can employ? Or any tutorial? I have never done such project before but I need such editor to …

Member Avatar for Stefano Mtangoo
0
244
Member Avatar for veledrom

Hi, I am trying to backup one of my Mysql database with a PHP script. [code] <?php $host="localhost"; $database="toy"; $username="root"; $password=""; $connection=mysql_connect($host, $username, $password); if(!$connection) { die("ERROR: Couldn't connect to the server."); } else { $dbSelect=mysql_select_db($database); if(!$dbSelect) { die("ERROR: Couldn't select the database."); } else { $mysqldumpPath="/usr/bin/mysqldump"; $backupFileName = "Desktop/toy-`date …

Member Avatar for digital-ether
0
196
Member Avatar for yonghc

I am inclined to suspect that Borland C++ compiler 5.02 is seemingly full of bugs. Even though my C++ codes could be bug free, it reported External errors on compiling and failed to create an EXE file to run. Thanks to Mr. Salem, I have successfully compiled the above codes …

Member Avatar for yonghc
0
414
Member Avatar for Tekkno

I am not really sure where to go with this, but any help I can get would be appreciated. What I am trying to do is put together an array to use with a foreach loop by getting columns from multiple tables. Here is my query: [code=php] $results = mysql_query("SELECT …

Member Avatar for Tekkno
0
86
Member Avatar for javanub123
Member Avatar for AirGear

i usually use Visual Studio 6 or sometimes Dev Cpp.. but, they can't show me the runtime and the memory spent.. i need that information, to make sure that my program is qualified.. can someone help me about cpp compiler that can do that? thx.

Member Avatar for AirGear
0
134
Member Avatar for MrNoob

I m trying to find idea to change like from 1 to one and 2 to two and 3 three from 1 to 999 i m had an idea to do like a string with information etc ? but i want better idea so i dunno how to do it …

Member Avatar for Anjoe18_Edica
0
225
Member Avatar for =OTS=G-Man

Hello, I am having the hardest time getting my strings to format right I want it to only show the first 14 chars of the string. sounds simple, but I think ive been looking at the code to long to see where im messing up :). here's the code I …

Member Avatar for sknake
1
191
Member Avatar for gsc1ugs

I'm trying to bind to querys and would like to know most efficient way to do it I have these that both need binding as one SELECT * FROM categories ORDER BY categoryDesc and select count(*) as amount from products where idCategory = "&idCat&" and listhidden = 0" idCat is …

Member Avatar for gsc1ugs
0
129
Member Avatar for phoobah

I have somewhat a simple scenario, and having been out of PHP for some time, I'm a bit of a brainfart the past two days as I'm researching and re-educating myself with PHP. To put in lamen terms, I have a CSV file on the host server. I have a …

Member Avatar for phoobah
0
2K

The End.