5,346 Posted Topics
Re: [QUOTE=evant8950;862753]Hello everyone I am working on a ftp uploader and I have the class and the form. I have a progress bar on the form, but I need the class to tell the form to update the progress bar with the proper percent complete. I can't seem to figure out … | |
Re: [QUOTE=MJV;863537]I have searched everywhere but im not able to determine if you can show two or more data fields in a combo box. If so can anyone help me with the code to do so as I am stumped. Thanks in advance.[/QUOTE] You may do so by creating a user … | |
Re: Statement is written incorrectly, pop = 4 * double pow(e, t); pow is a static method of java.lang.Math class and you have to write the statement as follows: pop = 4 * Math.pow(e,t); | |
Re: [QUOTE=Tank50;862950]HI Iam reading from excel file and I store values into data tables. Thanks Tank50[/QUOTE] You say that you want to store data from Excel file and store into two DataTable instances - You are going to split your data. If you want to add relationship between two tables - … | |
Re: [QUOTE=AntonioMG;861461]Hello, Im having this problem with public interface, i want to use this method (is on a .dll) [code]namespace DS.GS.Admin { public interface BrokerAdmin { int GetCount(); } [/code] But i dont know how to call it, I try: DS.GS.Admin.BrokerAdmin ba; int a = ba.GetCount(); -> Error And: DS.GS.Admin.BrokerAdmin ba … | |
Re: > I am trying to copy large files over a network using sockets and channels. Here is a code snippet //sender side FileInputStream in = new FileInputStream(inputFileName); FileChannel fromFile = in.getChannel(); SocketChannel toSocket = sendSocket.getChannel(); fromFile.transferTo(0, 999999, toSocket ); > However, in the line where I call transferTo I get … | |
Re: [QUOTE=Egypt Pharaoh;861796]How can I change the view of the form[/QUOTE] We didnot get you. I think you want the different shaped forms. Isn't it? | |
Re: Dear, Check the type of authentication : SQL or Windows under which your database is created. | |
Re: Dear, An indexer is a member of class that enables an object to be indexed in the same way as an array. Consider the following code: using System; public class Date { int d, m, y; // Constructors public Date() { d = DateTime.Now.Day; m = DateTime.Now.Month; y = DateTime.Now.Year; … | |
Re: Dear, Ms-Access database - You may preserve binary data (picture file or any other file) using [B]OLE Object [/B] field type. Following code might help you to understand how to store binary data into a database. [QUOTE] .. string file=@"x:\aa\image.png"; byte []content=System.IO.File.ReadAllBytes(file); OledbConnection cn=new OledbConnection("...connection string .."); // Emp (eno … | |
Re: Dear, If you are loading DropDownList in Page_Load event then the code of databinding must be execute once. [B]IsPostBack[/B] property of Page class is used to determine whether a page is loaded first time or not. You may add your databind code like this: [CODE] if(IsPostBack==false) { .. .. Place … | |
Re: [QUOTE=Jarredpsmith;861030]Hi All I have come to the end of my first large project and would really appreciate some guidance on how to go about getting it into a finished state. There are a few issues im worried about and having come this far and with a deadline looming im so … | |
Re: [QUOTE=Mitja Bonca;860720]How to do comparions (or equalizations) in a Query builder (for a dataGridView)? I mean, I would like to select Grade and a Teacher who gave this grade, but I need to do a comparison to two listBox. In 1st I select a Student and in 2nd I select … | |
Re: Dear, Please honour to our community. Post your code problems not your problems. | |
Re: [QUOTE=Ancient Dragon;860427]The standard way to do it is to use the time functions in time.h [code] #include <ctime> int main() { time_t now = time(0); char* stime = asctime( localtime(&now) ); cout << stime << "\n"; } [/code][/QUOTE] [B]return[/B] statement is missing in your code snippet. Poster had used DateTime … | |
Re: [QUOTE=sivak;857644]i know what is the maening for method overloading ....can any one explain me method overloading with real time .NET example plz[/QUOTE] [QUOTE] In real world, we have a common verb serves different meaning. For example, to print [LIST] [*]Print on printer [*]Print on screen [*]Print on disk/file [/LIST] [/QUOTE] … | |
Re: Please be careful to use words - abstraction and abstract. [B]Abstraction[/B] is an integrated element of Object-Oriented Program Design. [QUOTE]All programming languages provide abstractions. It can be argued that the complexity of the problems you're able to solve is directly related to the [B]kind and quality [/B]of abstraction.[/QUOTE] Assembly language … | |
Re: Dear, You should think about Web Services for your project. Web Service provides interoperability between two discrete systems. JNI - is bit complicated feature. | |
Re: [QUOTE] Do not terminate Method unless it is abstract. [/QUOTE] [CODE] Television(boolean power, int channel, int volume); could be Television(boolean power, int channel, int volume) { } [/CODE] | |
Re: Dear, Due to ViewState feature, write your code in page load event with [B]IsPostBack[/B] status: [CODE] if(IsPostBack==false) { cbb_City.DataSource = data; cbb_City.DisplayMember = "Accounts.City"; cbb_City.ValueMember = "Accounts.City"; ... } [/CODE] PS: Check also Select query; It must return unique City name. (Use Distinct phrase) | |
Re: [B]java.io.RandomAccessFile[/B] class - Instances of this class support both reading and writing to a random access file. A random access file behaves like a large array of bytes stored in the file system. There is a kind of cursor, or index into the implied array, called the file pointer; input … | |
Re: Dear, I think you should have to refere some Object-Oriented Programming books before submitting your problems. A code fragment is meaningless. public Point() // This is a no-argument constructor { // initialise instance variables to zero double points [] = {0, 0}; double x = 0; double y = 0; … | |
Re: Dear, I am submitting a code. I hope this will help you. [CODE] package appex; import java.awt.*; import java.awt.image.*; import java.applet.*; public class App12 extends Applet{ Image oldImage,newImage,subImage; ImageProducer filtered,cropped; public void init(){ oldImage=getImage(getDocumentBase(),"long.jpg"); filtered=new FilteredImageSource(oldImage.getSource(),new GrayFilter()); cropped=new FilteredImageSource(oldImage.getSource(),new CropImageFilter(400,400,40,40)); newImage=createImage(filtered); subImage=createImage(cropped); } public void paint(Graphics g){ if(newImage!=null) g.drawImage(newImage,0,0,this); g.clearRect(20,20,140,140); … | |
Re: Dear, Solution of your problem is depend upong following settings: [LIST=1] [*]Create DSN (System DSN) - Control Panel +Administrative Tools + ODBC Data Source + System DSN. [*]Set Default Authorization for MS-Access database while creating DSN. [*]Default Username is [B]Admin [/B]and password is Blank (No password). You may set database … | |
Re: Dear, Abstract method must be impelemented into sub class with same name and signature (parameter datatype, order and return datatype). [CODE] abstract public class Shape { public String color; public void setColor(String c) { color = c; } public String getColor() { return color; } abstract double area(); abstract double … | |
Re: Dear, Applets are designed for rich-client application. So with default implementation of applet, you can't add IO and database operations. But, to do so, you have to create security sub-class and policy. | |
Re: Use Java Media Framework (JMF) and some classes from java.net package. | |
Re: Recursive functions uses STACK frame and for an instance of JVM, it is 1 MB. Please try loop control statements instead of recursion. | |
Re: Web Server Control - Web Server Controls are classes in the .NET Framework that represent visual elements on a web form. Some of these classes are relatively straight forward and map closely to a specific HTML tag. Other controls are must more ambititious abstractions that render a more complex representation … | |
Re: To fetch data from next row, you can do this by invoking dr.Read() method again. | |
Re: Dear, I have a code which uses integer array. Hope this will help you. [CODE] using System; namespace adc { public class Permu { static void permut(int k, int n, int[] nums) { int i, j, tmp; /* when k > n we are done and should print */ if … | |
Re: Dear, Create .jar of those classes you want to use them in different projects and append the entry of .jar file CLASSPATH environment variable. PS: You can place .jar files in [B]\jdk1.6.0\jre\lib\ext [/B]. (shared folder of jvm - am I?, Mr. Ancient Dragon.). | |
Re: Dear, There are some missing statement in your program. Please compare following code with your source code. [CODE] public class QuickSort{ public static void main(String a[]){ int i; int array[] = {12,9,4,99,120,1,3,10,13}; System.out.println("Values Before the sort:\n"); for(i = 0; i < array.length; i++) System.out.print( array[i]+" "); System.out.println(); quick_srt(array,0,array.length-1); System.out.print("Values after … | |
Re: Dear, Use Object Serialization/Deserialization technique. Please refere java.io.Serializable, java.io.ObjectInputStream and java.io.ObjectOutputStream. | |
Re: Yes, you can use .NET dll into java program. Use System.loadLibrary method and some JNI features. Please check : [URL="http://www.codeproject.com/KB/java/JavaHostWPF.aspx"]http://www.codeproject.com/KB/java/JavaHostWPF.aspx[/URL] | |
Re: Dear, Its too difficult to read whole program line by line but I guess you are facing problem due to not closing database connection immediately as soon as a specific database operation is over. | |
Re: Dear, How can you want to understand the meaming of this code? You say that it's variable. In fact it is a static data member (field). I think your code uses some sort of status control mechanism and the field name you mentioned is for that purpose. | |
Re: Dear, Important thing to remember that Java is not a JavaScript and vice-versa. | |
Re: Dear, Set PATH and CLASSPATH environment variables. To do so, Right click on My Computer + Properties + User Variable section. [CODE] PATH=C:\Program Files\Java\jdk1.6.0\bin; CLASSPATH=.;C:\Program Files\Java\jdk1.6.0; [/CODE] | |
Hi, Following code snippet show the maximum number of nodes to be created. I execute this code and show the count : 7874 My problem is that I want to create more node than 7874. I have compiled this code by Turboc version 3.0 on Windows XP. [CODE]#include <stdio.h> #include … | |
Re: This method is an example of memory I/O. If you want to write some data into byte array or stream; for instance, int a=10; float b=20.40f; char name[]="Mr. Rajesh"; char buff[100]; sprintf(buff,"%d %f %s",a,b,name); Values - 10, 10.20f, and "Mr. Rajesh" are copied into the buff - string variable. | |
Re: [QUOTE=Aelphaeis;841860]Hey, I'm a high school student who is fairly programming and I was curious as to how to input a single character without entered an End of Data marker (e.g. newline character/Enter) [CODE] #include <stdio.h> #include <stdlib.h> #include <ctype.h> int main () { char ch; switch (toupper(getchar())) { case 'A': … | |
Re: [QUOTE=kerek2;841916]Hi alls, I need help regarding this method...actually i have display image from database into picturebox using memortstream...then i need to copy this image and save it into file as jpg or bmp......i'm already insert contextmenu for rightclick function to copy image but not working...anyone can give the idea plzzz?..Tq … | |
Re: [QUOTE=Behi Jon;841447]What is the difference between this two codes for Complex class ? What is the preference of code that written by pointers ? Thanks ... First code with pointers : [code=cplusplus] //Complex.h #ifndef COMPLEX_H #define COMPLEX_H class Complex { public: Complex ( double = 1, double = 0 ); … | |
Re: Poor boy! You wrote improper code - check declaration & definition of printGrade function. void printGrade(int score); |-------- here is a problem. remove void at declaration and definition. V void char printGrade(int cScore) { char gr = " "; if (cScore >= 90) gr = "A"; else if (cScore >= … |
The End.