43,549 Solved Topics
Remove Filter ![]() | |
The next code from the book "Pro-linq language itegrated query in C# 2008" gives a casting exception error on line 29. I know ToArray returns an array of objects, which are in fact of type Employee so why it generates an error? [CODE=C#]public class Employee { public int id; public … Software Development | |
Hi, I was just wondering what might be the path to load jar file from c sharp project folder. Currently the path I'm using is String strJarFilePath1 = "C:\\Users\\xxxx\\Downloads\\ss\\ss.jar"; which works perfectly If I place this ss.jar in project folder by the name WindowsFormsApplication1 what might be the path? I … Software Development | |
Write a program for the following problem. An instructor needs a program that accepts a student identification number and three test scores, test1, test2, and final_test as input, and determines and outputs for each student the semester average and the final letter grade according to the following scheme: SEMESTER AVERAGE … Software Development c | |
Hello Guyz Need some more help now. This is my GUI [img]http://screensnapr.com/e/AuJ8Ka.png[/img] Suppose i have this written in textbox1 [CODE] vb.net gettext leaning daniweb.com 2 learn vb2learn[/CODE] [img]http://screensnapr.com/e/sC969O.png[/img] It should show "leaning daniweb.com 2 learn" in the other textbox Like [img]http://screensnapr.com/e/3MW0jl.png[/img] So the line which should contain daniweb.com, it should … | |
Hey All, am looking for a way to break an xml Tag line into tag and attributes. Say I have This line [code=xml] <event time="12:30" value="This is a Sample Value" type="event"> </event> [/code] I have this so far [code=python] # Open file to read f=open("myTest2.xml") #start reading File for line … | |
Hi, I need help with Resource files.... That i need to do is running file that i have put in the resource files (exe file) So the idea of this when i click the button the file that i have put run so it cant be happen with shell. is … Software Development file-system vb.net | |
i know that i should use this to compile all the java classes . i used these and its working great. but i dont understand all of this . i did some readings and i understand now that when i use "set" , it sets the varibale name to the … Software Development java | |
Hi,everyone Im new to JAVA and not sure how does recursion work in JAVA I have to use JAVA Turtle to draw snowflake here is the pseudocode. procedure snowflakePart( S, N ) : if N is greater than 0: move turtle forward S units if N is greater than 1: … Software Development java | |
I have a data base using access which has one column as jobno and which is empty. I want that when my form load (vb.net 2005) it generate a number which then appears in a textbox. Below are my codes please i cant complete it help me. Private Sub Form1_Load(ByVal … Software Development microsoft-access open-source vb.net | |
How can i continue a very long sentence on the second line in a JLabel? /n does not work /t does not work as well I dont want the html thing cause i have a simple application. Thank you Software Development java | |
Hi, please help me with error. I want to run simple project below. I have a lot of errors below and don't know how to fix it. I use GCC port (Mingw) [CODE=C++]#include "mysql/my_global.h" #include "mysql/mysql.h" #include <stdio.h> int main(int argc, char **argv) { printf("MySQL client version: %s\n", mysql_get_client_info()); } … Software Development c | |
I am using python in win32 enviornment.i wanna add extra library for using serial port.So i have downloaded the lib for windows env. The package is installing fine.But when ever i import serial following error i get.Can anyone please help me out... [CODE]>>> import serial Traceback (most recent call last): … Software Development python | |
Hi guys..I try to automate outlook..it works great ..the problem is that I use office14 at home, and my company (where I need my program to work) uses office12... I was told that to make it possible to run on office12 and later, I need to get msoutl.olb from office12. … Software Development c# microsoft-office | |
Im trying to make a fast food program on which the user will input the amount that he has, then he will click on what he wants, by using check boxes. There are 7 different check boxes with 7 different amounts of money. I got an idea on what to … | |
Hi all! I'm a beginner to C++ and wanted to try my skill at creating a decimal to binary converter in the console. I tried two different methods, but I failed at both. My first program was an attempt at being organized and using multiple functions and snaking the output … Software Development c++ | |
Im planing to have several Methods that will display the question and the answer choices to their coresponding labels and cmdButtons. But somehow i get the error message "void is an invalid type for the variable" when i want to create my method below of my code (i commented the … Software Development java java-swing | |
Hello every one i have a text file containing following data(it is a config file for another program): [pos] 100 [lastsave] 10 How do i replace the value of [pos] i.e 100 with 200?? Thanks BattleX Software Development vb.net | |
hi all, I am trying to make a prog. which will download image from a web site.But the problem is the dynamic nature of the web site. The url is like [url]http://www.site.com/image.aspx?id=445[/url] If i wanna access image 1,2 or anything i can change the id and i can view the … Software Development image python web-browser | |
I am having problems accessing a variable from one class to another. [CODE] class Player(pygame.sprite.Sprite): def rotateShip(self, rotAmt): radians = self.rotation * math.pi / 180 [/CODE] I am trying to use the variable radians from class Player to another class. radians only exists in 'rotateShip'. Thanks for your help in … | |
here is my code: [CODE]//if any of errprLists is not equal to 0, then initialWieght equals newWeight if(errorList[0]!=0 || errorList[1]!=0 || errorList[2]!=0 || errorList[3]!=0) { for(int i=0; i<row; i++) { initialWeight[i] = newWeight[i]; } } //break the loop if all errors equal 0 //--------------------------------------------------------------------------- else if(errorList[0]==0 && errorList[1]==0 && errorList[2]==0 … Software Development java | |
I'm having some difficulty figuring out how to delete the objects I new'ed during run-time. I'm using a heterogeneous collection. Simplified Example: [CODE] const int SIZE = 4; myBase* objs[SIZE]; objs[0] = new myChild1(); objs[1] = new myChild2(); objs[2] = new myChild3(); objs[3] = new myBase(); //I tried: for(int i … Software Development c++ | |
[code] std::string headerInfo = " "; //Verify stream is still in good condition if(streamReader->good()) { streamReader->ignore(fileSize, ':'); //work arounds =) v------------v streamReader->getline(&headerInfo[0], sizeof(headerInfo), '\n'); } else { //Error } return headerInfo; [/code] The first parameter of getline wants a char* to store the data, so instead of creating an array … Software Development c++ | |
Hi this is an assignment for my computer science lab. It is weird because if I compile and run with my c compiler from ubuntu gcc4.4, it works perfectly. But if I compile with the university's server (I connect with SSH) it messes up The main purpose of the program … Software Development c open-source ubuntu | |
any time a number is present in a word inflate its value by 1........ for eg, input anyone up four tennis output anytwo up five elevennis Software Development java | |
Hello I have created a Regex to remove invalid characters in a string: Here it is: [CODE] Regex replace_invalid_caracters = new Regex(@"[\\|/|*|+|-|%|=|^|@|#|$|!|~|`|?|<|>|:|(|)|{|}|;|,|_|]"); [/CODE] The thing is that then I use it in a method to remove this invalid characters. It manages to remove all invalid characters except for "-". I … Software Development regex | |
i really need help with this program i am finding a saddle number of a 2-d array which is the min value in a particular column and maximum value in its row.......and my error with the code is arrayindexoutofboundexception eg input num=4 7 6 9 10 5 3 4 6 … Software Development java | |
i get this error when add database source...anyone help me...[ATTACH]19437[/ATTACH] Software Development vb.net | |
I've this very stupid litle problem. I want to populate a combobox with numbers ranging from 00 to 99. But when I ad them with a loop as an integer the first ten numbers apear only with one digit. I wonder, how can I ad a second digit to them … Software Development vb.net | |
I have created to GUI interfaces using netbeans drag n drop. The first interface has a button upon clicking which opens the second interface. I want to close the 1st interface as soon as I click the button in it so that only the second interface is displayed. How can … | |
what is wrong with my code? in inputs like "radar" or "tttt" should say its palindrome. [CODE]#include <iostream> using namespace std; bool testpalindrome(string,int,int); int main() { string wordX; bool result; cout<<"Enter string: "; getline(cin,wordX); result=testpalindrome(wordX,wordX.length()-1,0); result==true ? cout<<"\nthe string is palindrome!" : cout<<"\nthe string is NOT palindrome!\n"; } bool testpalindrome(string … Software Development c++ | |
I am using MsAccess DB and Vb.NET 2008. This is a code to check the Database for duplicate entries but m geting an Error. [B]" Fill: SelectCommand.Connection property has not been initialized."[/B] And this points to [B]LINE NO 14[/B]. What could be the cause..? thanks in adv [CODE] Dim con … Software Development dataset open-source vb.net | |
Hi, I'm trying to trim certain caracters from a string but it is not working. Here is my code: [CODE] string sMystring = "what you waiting for? "; char[] cInvalid = { '\', '-', '/', '*', '?', '<', '>', '|'}; sMystring = sMystring.Trim(cInvalid); [/CODE] I realized that if I remove … Software Development | |
Newbie to C++ but i am a Java programmer. Trying to learn C++ now. Reading the C++ Primer by Stanley Lipmann. I don't understand this sentence in Chapter 3 about library types. He's talking about library type string and vector. "These library types are abstractions of more primitive types - … Software Development c++ | |
Hello Guyz This is my first post here. I am having problem in vb.net I am trying to get a webpage source using this code. [CODE] Dim request As System.Net.HttpWebRequest = System.Net.HttpWebRequest.Create(Textbox1.Text) Dim response As System.Net.HttpWebResponse = request.GetResponse() Dim sr As System.IO.StreamReader = New System.IO.StreamReader(response.GetResponseStream()) Dim sourcecode As String = … Software Development http-protocol perl vb.net | |
hello all, i'm new to python programming and i'm facing a problem and need ur help i finished my script and i'm trying to execute it on windows cmd the script takes a file as an argument , when i run the script with the argument it works very well … Software Development python | |
[CODE] <html> <td id="item_menu" class="line" valign="top" width="100%"> <a class="nopd" target="mainly" href="http://myfruits/aboutfruits.html">About fruits</a> </td> <td class="line" id="item_menu" valign="top" width="100%"> <b>Common Fruits</b> <div class="tree tree-top" style="-moz-user-select: none;"><div class=" tree-item tree-lines-t" style="-moz-user-select: none;"><table class="tree-table" style="-moz-user-select: none;" cellpadding="0" cellspacing="0"><tbody style="-moz-user-select: none;"><tr style="-moz-user-select: none;"><td class="tgb icon customIcon" style="-moz-user-select: none;"></td><td class="label" style="-moz-user-select: none;"><a href="http://myfruits/apple.html" target="cmain" title="CONTENT: … Software Development html-css vb.net web-browser | |
[code]#include <iostream> #include <WinSock2.h> #include <mysql.h> #include <string> #include <vector> #include "action.h" using namespace std; MYSQL *con; st_mysql_res* res = NULL; MYSQL_FIELD * field[200]; MYSQL_ROW myRow; CAction * m_pActionList[1000]; int LoadActions(); int main() { con = mysql_init(con); if(!mysql_real_connect(con,"127.0.0.1","test","test","account_zf",NULL,NULL,NULL)) { cout<<"Error connected"<<endl; system("pause"); exit(-1); return false; } LoadActions(); system("pause"); return 0; … Software Development c++ | |
Greetings to all Forum users, Yesterday i tried to install a Haskell-module via cabal, in order to get aquainted with the installation of modules in Haskell. I had to install cabal first. My System: Windows 7 Haskell-Compiler Version: GHC 7.0.2 (Link [url]http://www.haskell.org/ghc/download[/url]) Cabal: [url]http://haskell.org/cabal/download.html[/url] I will describe the process step … Software Development file-stream user-interface | |
I have a vb 6.0 project which uses access as a database. but i need only oracle as database. Will anybody pls tell me how to change it to oracle database. Does it requires the Complete change in the code of the project or only a little changes. i am … Software Development oracle visual-basic | |
![]() | I have a little problem with strcmp here,the following code basically opens a file and writes to it until I enter "\esc",at which point the program should stop....but the problem is,it does not,and I can't figure out what might be the prob.Thanks for your time(I am using turbo c++ 3.0 … ![]() |
I'm trying something like this [CODE]void receiver (char* x) { cout<<x<<endl; //prints "a" cout<<*x<<endl; //prints "a" cout<<&x<<endl; //prints address of x } int main() { char p = 'a'; cout<<p<<endl; //prints "a" cout<<&p<<endl; //prints "a" receiver(&p); } [/CODE] In the main function for both p and &p, it is printing … Software Development c++ | |
Hi All I have just started using a subprocess.call()to call external commands. I want to call R from command line and that I can do it easily by subprocess.call('Rscript script.R') and it works fine. I want to pass the several arguments instead of using default arguments. I tried using Rscript … Software Development python | |
I have an assignment in which I have to read in a series of words using the nextLine method from the Scanner class and then count the number of words using the StringTokenizer class. I know you all like for people to show some initiative by starting the program but … Software Development java | |
Hello, I'm trying to write a simple Clicker program to automate room-joining on GArena: 2 clicks to attempt to join, 1 attempt per 5 seconds. That means I have to simulate 2 x mouseButton1 clicks every 5 seconds - easy. The problem with my clicker, as well as with other … Software Development java | |
[CODE] ListView listView1 = new ListView(); DataTable dataTable = new DataTable(); MoneyReceiptGateway moneyReceiptGateway = new MoneyReceiptGateway(); dataTable = moneyReceiptGateway.SelectDataForListView(narrationTextBox.Text); string[] str = new string[dataTable.Columns.Count]; foreach (DataRow rr in dataTable.Rows) { for (int coll = 0; coll <= dataTable.Columns.Count; coll++) { str[coll] = rr[coll].ToString(); } ListViewDataItem li; li = new ListViewDataItem(str); … | |
Hi guys, I'm supposed to make a program that calculates how many months it would take to pay off your credit card balance with a 14% yearly interest rate. I've written out what I believe to be it but I end up getting this. [url]http://omg.wthax.org/error_2.png[/url] The program doesn't seem to … Software Development c++ | |
I'm posting here because I'm not too sure Google will take the entire search criteria of what I'm trying to explain. I have a Main form, called Main.vb, that is a Parent Form. I have another form called Notes.vb. Inside Main.vb I have a toolstrip with a button on it … Software Development vb.net | |
Hello... Like the title already says, i have a Panel with a TextField and when a text is entered, i want it to appear on a JLabel that is located on another Panel. Can someone give me the Syntax? Or is it more complicated to do? I do not use … Software Development display java java-swing | |
I'm really lost on this topic. I'm trying to study for an exam. 1)When the symbol '&' is in front of a variable, it is referring to the address right? How is it different from a reference parameter? I keep getting them mixed up. 2)By dereferencing it, it means that … Software Development c++ |
The End.