43,549 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for drsmith

We have a script that creates a .csv file that in turn is fed into a python script. Our .csv file is being generated with a line feed at the bottom, and this is hammering the python script. Is there a way to get rid of that extra line that …

Software Development perl
Member Avatar for KevinADC
0
133
Member Avatar for LucyB

Do you do the flow chart first or go straight to the code? I find it easier to do the code first for some reason, maybe this is bad?

Software Development c++
Member Avatar for Rashakil Fol
0
104
Member Avatar for gabec94

Hi, I am trying to write a connect four program in python, which I am not very experienced at. This is what I have so far: [Code] row7 = [' ', ' ', ' ', ' ', ' ', ' ', ' '] row6 = [' ', ' ', ' …

Software Development python
Member Avatar for lllllIllIlllI
0
138
Member Avatar for cynical

Hi! I'm using VS 2003 and MS Access. I have this Form1 that displays Record details on textboxes (they are databinded).. The records are retrieved from MS Access using the code: [CODE] Public Sub loadFund() '[Load Items] Dim selectAllSQL as string = "SELECT * FROM Table1" Dim selectAllCMD As OleDbCommand …

Software Development dataset vb.net
Member Avatar for Jx_Man
0
162
Member Avatar for En-Motion

I'm trying to validate my textbox so that the user must enter a Table Number between 1 and 20. The click event of the exit button checks this and if invalid input, displays a message box. It works for all numbers except 3-9 where it displays the warning even though …

Software Development visual-basic
Member Avatar for En-Motion
0
73
Member Avatar for kadamora

i'm doing a game for my c++ course and there is something wrong with a class the error comes up in class hero...function jumpright [code=cplusplus] #include <iostream.h> #include <conio.h> #include <afx.h> #define rows 48 #define cols 80 class screen { private: char x[rows][cols]; public: screen() { int i,j; for(i=0;i<rows;i++) { …

Software Development c++
Member Avatar for Nick Evan
0
333
Member Avatar for nagatron

Please help me how to ignore case sensitivity in VB. My program is to store data in the database, though I use small letters or big letters, the database store the data starting with a capital letter followed by small letters. Ex. [B]Input[/B][B]:[/B] [COLOR="Red"]Neil, neil, NEIL[/COLOR] [B]In the database:[/B][COLOR="Red"] Neil[/COLOR] …

Software Development visual-basic
Member Avatar for nagatron
0
226
Member Avatar for cVz

:yawn: I am trying to import the address book from MS Office, can anyone tell me where to locate the MS Outlook addressbook ? Thank you in advance... [ICODE]cVz[/ICODE]

Software Development
Member Avatar for cVz
0
100
Member Avatar for lonely_girl

HI I need a little help with this program [code=c] #include<stdio.h> #include<conio.h> void main () { float num1,num2,result=0; char ch; clrscr(); printf("\nEnter 1st num:"); scanf("%f",&num1); printf("\nEnter 2nd num:"); scanf("%f",&num2); wrong: printf("\nEnter + for addition" "\nEnter - for subtraction" "\nEnter / for division" "\nEnter * for multiplication\n"); scanf(" %c",&ch); if (ch=='+') …

Software Development c
Member Avatar for lonely_girl
0
140
Member Avatar for 0av067

within a windows forms class (form1) I declared a cliext vector of vectors of strings with [CODE]cliext::vector<cliext::vector<String^>^> myvector;[/CODE]. Then, within a function in that same class I tried to push back a vector of strings in myvector but it resulted in an error. I attempted to push back the vector …

Software Development c++
Member Avatar for 0av067
0
537
Member Avatar for sonicstage

Hello all, I just started using c++ and I'm supposed to write a function that takes two positive integers, p and q, where p<q, and i have to return the sum of all the numbers >=p and <=q which are divisible by 7. here's what i have so far: # …

Software Development c++
Member Avatar for sonicstage
0
95
Member Avatar for ACParson2001

Having some troubles with a program I'm writing. I'm using SharpDevelop, and I'm writing a VB.net program, that I am doing for a friend. I have a combo box that has a list of races, that are already added (Human, Elf, Dark Elf, Draconian, Viera, Wingly). Upon selection, the appropriate …

Software Development vb.net
Member Avatar for ACParson2001
0
130
Member Avatar for crackerjacker

Hi- so i want to be able to type in a file name (not knowing the path) and have it search the c: drive. then, when it finds the file it will return the path (in a variable, label, etc.) thanks!

Software Development visual-basic
Member Avatar for crackerjacker
0
80
Member Avatar for serkan sendur

How it is useful to create a static variable in a non static member function? The compiler allows that, and i wonder in what situations it is useful to create static variables in the function bodies as they are going to be disposed at the end of the function call.

Software Development c++
Member Avatar for Rashakil Fol
0
165
Member Avatar for flipjoebanana

Hello, I am trying to figure out why pointer address is not preserved over a function call and how to fix it. For example: [code] void test_function(char **,char *); int main() { char **argv = calloc(64,sizeof(char *)); char *line = "MAMMAJAMMA!"; test_function(argv,line); printf("argv[0] == %s",argv[0]); return 0; } void test_function(char …

Software Development c++
Member Avatar for flipjoebanana
0
96
Member Avatar for serkan sendur

Wikipedia says something like this [I]Aggregate classes An aggregate class is a class with no user-declared constructors, no private or protected non-static data members, no base classes, and no virtual functions[1]. Such a class can be initialized with a brace-enclosed comma-separated list of initializer-clauses. The following code has the same …

Software Development c++
Member Avatar for Narue
0
163
Member Avatar for greenbluekidz

I am supposed to code a program that uses 3 parallel arrays. The program should prompt the user to enter in a Product ID. From there it is supposed to search the ids array and then display the corresponding price and quantity remaining. It does not do this. Instead I …

Software Development algorithm c++ visual-studio
Member Avatar for greenbluekidz
0
139
Member Avatar for scru

I noticed a weird thing happening when i use this function. If the page i open is in latin-1 encoding, the bytes returned by this function would have some weird junk characters inserted in various places. However, if i use urlretrieve to fetch the page to disk, there is no …

Software Development python
Member Avatar for scru
0
210
Member Avatar for Liszt

If I have this string: "Hello" How would I do to encrypt this string ?

Software Development c++
Member Avatar for Liszt
0
113
Member Avatar for anu123d

Project Name : " Employee Information System " I am trying to add a new department name in "dept.txt" file. using file Operations and funcctions defined in String Header file in C Problem is in fnAddDepartment() function. When i run program in VC++ compiler, it says : Debug Assertion Failed! …

Software Development c file-system operating-system
Member Avatar for Murtan
0
223
Member Avatar for Dendei

Hello i need some help to understand my work heres the code [CODE] #include <iostream> #include <string> #include <sstream> #include <vector> #include <fstream> using namespace std; struct cell1 { int value1; } cell1Data; struct cell2 { int value2; } cell2Data; int main(void) { ifstream myfile("example.txt"); if(!myfile.good()) return 0; vector<cell1> data1; …

Software Development c++
Member Avatar for Freaky_Chris
0
105
Member Avatar for murderotica

Hello there, I've been messing around with System.Web.Mail these days and I was able to create an application that could send a mail using smtp. My problem here is, Idk how to connect my application to an exchange server and I don't have any server yet. I'm kinda noob in …

Software Development web-server
Member Avatar for Hitandrun
0
176
Member Avatar for tillaart36

Hello, I'm writing my code into the 'vizard python editor' and sometimes it feels a bit bugged or something, now I get an error message that my class has no attribute. I feel it has to do something with editing in vizard because in other editors I don't think i …

Software Development python
Member Avatar for jlm699
0
36K
Member Avatar for denni11998833

Hey, I was wondering if someone could help me out here! I am trying to sort a list of files and remove the last x ones if it exceeds a constant variable (maxbuffersize). Below you can see what I did: I tried to sort the vector based on the predicate …

Software Development c++
Member Avatar for denni11998833
0
2K
Member Avatar for azwraith69

good day everyone.. thx for reading.. this is my problem: i want to use the write() function, in ofstream, to write strings into a file.. but write() requires parameters of const char pointer and streamsize... [icode]for(unsigned i=0; i != questions.size(); i++) { qptr = &questions[i]; //vector element(string) tempfile.write(qptr, stringsize); }[/icode] …

Software Development c++
Member Avatar for azwraith69
0
163
Member Avatar for number87

#5report function report { clear echo "Name, Position, Department, Salary" echo "========================================" awk 'BEGIN{FS=","; RS="\n"} {printf "%s, %s, %s, %s\n", $1, $2, $3, $4}' $dataFile awk '{total += $4}END{print total}' $dataFile } i am trying to print the total sum of the salary or $4 field. However i cant figure …

Software Development finance shell-scripting
Member Avatar for Salem
0
152
Member Avatar for rak4u

Hi till now i am used window application in which there is no problem in connection using following code [code] Dim cnn As SqlConnection cnn = New SqlConnection("data source=RAKESH-676DD0E1;initial catalog=rw;integrated security=SSPI") cnn.Open() Dim da As SqlDataAdapter Dim dt As New DataTable da = New SqlDataAdapter("select * from publicity", cnn) da.Fill(dt) …

Software Development dataset open-source vb.net web-server
Member Avatar for rak4u
0
126
Member Avatar for code46

Hello, I wrote a quicksort program that will give me the execution time of the algorithm. I was running it for 1,000, 10,000, 100,000, 1,000,000, and 10,000,000 numbers. Everything was going fine and then when I changed the amount of numbers it is sorting it gave me a segmentation fault …

Software Development algorithm c++
Member Avatar for code46
0
214
Member Avatar for serkan sendur

i keep some formatting data in an array of structs. it is a very long array. is it better to keep this information in another class and inherit from this class or is it better to not inherit from this class but create an instance of that class and use …

Software Development c++
Member Avatar for Narue
0
90
Member Avatar for OrderChaos

Hello I am working on a simple calculator program for school. I already have all the button clicks working, which is all that was required. I thought it would be cool if I could get it to where you could use the keyboard for entry and I've done similar things …

Software Development visual-basic
Member Avatar for Ramy Mahrous
0
1K
Member Avatar for aburich_44

This has only one function to solve projectile motion, but it doesnt seem like it works, why? [code] //Richard Chaaya //1-25-09 //kinimatics #include <iostream> #include <conio.h> #include <iomanip> #include <string> using namespace std; int main() { //declare variables double dblVix = 0.0; double dblViy = 0.0; double dblVfx= 0.0; double …

Software Development c c# c++
Member Avatar for StuXYZ
-1
122
Member Avatar for wheatontrue

Dear all, I am trying to create x attributes in a class, to the effect of: class classic: def __init__(self,text): r=range(text.count('TI -')) for l in r: self.l=None Unfortunately I can't iterate through for some reason. I only get self.l, not, for instance self.1 to self.107 How do I do this? …

Software Development python
Member Avatar for wheatontrue
0
84
Member Avatar for ddanbe

Start a new Forms application. Add a DataGridView control to the Form. Add a few Columns to the DataGridView. In the properties window select the ColumnHeadersDefaultCellStyle (ahh what's in a name...) property. A dialog opens. Change the appearance BackColor to whatever color you like. Run the application. On my system …

Software Development
Member Avatar for ddanbe
0
340
Member Avatar for bajanpoet

Hi guys! I have created two table valued multi-statement functions using SQL Server 2000 and am now trying to develop a VB.NET front end application where I run the functions and pass string parameters to them. When I run the function in SQL Server Query Analyzer, it works, but when …

Software Development vb.net
Member Avatar for bajanpoet
0
116
Member Avatar for mahdiahmadirad

Hi Dears! I Wrote A Bubble Sort for sorting 2D array of characters. and logically it seems correct, but unfortunately not works. please help me. this is my output: unsorted: mah ali sal Sorted: ali ali mah Here is my Code so far: [CODE] #include <iostream.h> #include <stdio.h> #include <string.h> …

Software Development c++
Member Avatar for mahdiahmadirad
0
188
Member Avatar for serkan sendur

hi guys i want to achieve something like this : in header file : [CODE]#pragma once class wef { private: int a[]; void setI(); };[/CODE] and the code file will be like this: [CODE]#include "wef.h" void wef::setI() { a = {1,2,3}; }[/CODE] could you please help me with that?

Software Development c++
Member Avatar for serkan sendur
0
13K
Member Avatar for serkan sendur

i have a struct and i need to use an array of that struct. The member of that array is definite at compile time, so i am going to hard code them. how do i declare it in my class header file and fill the items in the class file?

Software Development c++
Member Avatar for serkan sendur
0
298
Member Avatar for robertmacedonia

Hello, I would like to ask is there any class connected with the Tree data structure in the Java Api, since I couldn't find one. I'm just starting to study the Binary Search Trees, the Heap data structure etc. As far as I could see until now, I will have …

Software Development api data-structure java
Member Avatar for robertmacedonia
0
99
Member Avatar for Yaserk88

Hey. I am trying to output a file. I pretty much have down, but the only problem is I'm getting the last set of my numbers and missing the other 5000 or so sets. Here is what I have [[ICODE]for (int i=0; i < N_plates; i++) { cout << i …

Software Development c++
Member Avatar for Yaserk88
0
132
Member Avatar for urufukiba

im trying to make a program that reads a text file in the format: 2 polygon 3 90 90 90 90 90 90 polyline 2 12 80 30 15 (not the real numbers obviously) and have the program read how many things, what type, how many points for that type, …

Software Development c opengl
Member Avatar for urufukiba
0
94
Member Avatar for serkan sendur

i got compiler error stating that : Only static data members with const integral or const enumeration type can specify an initializer in the class definition what is the logic behind that? why is the compiler designed not to accept any non constant static initialization of types?

Software Development c++
Member Avatar for Narue
0
113
Member Avatar for mtramnes

I downloaded active perl and go to the perl package manager but I cant figure out how to get my applications to run. Any suggestions?

Software Development perl
Member Avatar for KevinADC
0
132
Member Avatar for mtramnes

Im taking a perl class not exactly sure if what Im doing is right. I was to take a written program that allowed the user to enter a number guessing what the target was. The original used elseif statements to let the user know if the guess was to high, …

Software Development perl
Member Avatar for KevinADC
0
125
Member Avatar for serkan sendur

i have a problem instantiating an object, to demostrate that problem i created three files named body.cpp, head.h, head2.h the content of the files are as follows: body.cpp: [CODE]#include "head.h" class2::class2() { myClass(5); } int main() { class2 myFinalClass(); return 0; }[/CODE] head.h: [CODE]#include "head2.h" class class2 { public: class1 …

Software Development c++
Member Avatar for Narue
1
117
Member Avatar for scru

Is there a gui library that has already been ported to python 3? I'm interested in using some of the new python 3 features in the back end for my project.

Software Development gui python
Member Avatar for Ene Uran
-1
270
Member Avatar for jake88

I've parsed an XML and now I'm trying to write into some elements that are text nodes. What is the best way to go about writing into these text nodes? Ex. <tag>insert texty text here </tag>

Software Development c++ xml
0
63
Member Avatar for yuanza

I have this program that will ask user to put in the day, it compiles but every time i set the day to Saturday this program won't display Saturday, instead it shows Sunday. It also won't correctly generate the output for yesterday if the current day is Sunday and tomorrow …

Software Development c++
Member Avatar for yuanza
0
127
Member Avatar for nikola.rosic

I have a panel on form and i'm drawing a graph on it with a pen.When i open something on top of that form or i minimize the form and maximize it, the panel goes white until i draw something on it again.So i think i could call an event …

Software Development
Member Avatar for nelis
0
222
Member Avatar for Stefano Mtangoo

Hello all, I'm starting C++ and wan't to learn for loop. I want the Loop to count down the rotate and print its value until when it equals to value where it terminates. Here is code [CODE=C++] int value; int rotate = 4; for (value = 0; rotate>value; rotate--; ){ …

Software Development c++
Member Avatar for Stefano Mtangoo
0
92
Member Avatar for Stefano Mtangoo

I know of ww.portablepython.com/ Can anyone know how to do a combination of IDE and this python in stick. Also if anyone have ever tried to add other python modules to it like Vpython, wxpython, etc Thanks alot

Software Development ide python
Member Avatar for Stefano Mtangoo
0
393

The End.