234 Topics

Member Avatar for
Member Avatar for stevetaylor15

I was just a bit confused about something sorry. If you have two classes, Ribbon1 and ThisAddIN below. How can I call Example()? - All are in the same namespace.. [CODE] public partial class Ribbon1 { private void button1_Click_1(object sender, RibbonControlEventArgs e) { //Call Example() from ThisAddIn Class Example(); } …

Member Avatar for williamrojas78
0
199
Member Avatar for DAlexNagy

This is a request for some 'best practices' comments from experienced OOP practitioners. I have been in IT from the days of punched cards and have had considerable experience with legacy languages like 370 ASM, SAS, and REXX. For fun, I've taken a college class in C++ and am now …

Member Avatar for DAlexNagy
0
165
Member Avatar for morewater14

Hi, I have a project to do for a C++ class that asks us to use a class termed "queue" to store some values (20/100/user defined) and allow the user to add/remove values. I'm sure it seems really basic, but I just can't get my code to display the class. …

Member Avatar for Fbody
0
180
Member Avatar for digan

Hi, i have this assignment to do and i dont really know what i have to do could someone tell me what i have to do in simpler language thanks Here is the assignment: Create a program which: Implements a class called Queue: The class should contain an array of …

Member Avatar for digan
0
95
Member Avatar for hwalsh

Hi, I've been working on this for two days. I need to pass an arraylist to another class. It gets the information, and will print out the menu, until the program goes back to the initial class, then the list empties. I don't get it, and I'm so confused. [CODE]public …

Member Avatar for hwalsh
0
7K
Member Avatar for tshudyb

I have created a JFrame contaning a JTabbedPane. What I am trying to accomplish is the changing of tabs within my 'addCustomer()' class via an ActionListener. What I was trying was to call the method 'setTab(int c)' located in my 'BoatLog()' class, from my 'addCustomer()' class to set the index …

Member Avatar for tshudyb
0
1K
Member Avatar for Dean_Grobler

Hi there, This is just going to be a quick question. Also just note that I am i some "remote location" so I cant even show you my code. But what I want to know is this: Say you have a package called "myPackage" and inside that you have 2 …

Member Avatar for JamesCherrill
0
139
Member Avatar for amandureja

Hey guys! This is my very first post on this website. Anyways, I just started learning Python, and am reading an ebook, called "A Byte Of Python". So at the end, it says to create an address book application. In my application, it basically just creates a text file with …

Member Avatar for richieking
0
2K
Member Avatar for anglwthnati2de

Hi guys. I am hoping for a little help with this. I am pretty new to programming and just can't seem to get things right yet. Here is my code. It returns like 40 errors. Way messed up eh? [CODE]#include <iostream> #include <string> using namespace std; class Date { public: …

Member Avatar for anglwthnati2de
0
192
Member Avatar for TrustyTony

This code is giving minimal change from real Python class to JavaMonster with every method having setter and getter not following the PEP8 naming but capitalizedWordsFormat. When instrunctor turns his head or if you put the code in your library, you can simply remove the setter/getter lines.

0
259
Member Avatar for henryford

Hey guys I have a study guide that I need some assistance with if possible. it is basically definitions. Classes={} Assume these statements are working with classes and objects: Attribute?property Instance Encapsulation Also I need to tell what this code does. I am not good with classes at all please …

Member Avatar for SgtMe
0
115
Member Avatar for Tsunami49

Hi there. I am currently trying to get my head around using classes across two files. I currently have a super class and a sub class stored in a file and the main function in another. When I try and pass arguments to the class they work fine if the …

Member Avatar for Tsunami49
0
135
Member Avatar for Rez11

The point of the program I am making is to have a pure abstract base class called BasicShape and have 2 child classes, Circle and Rectangle. I have the program written but with one unresolved error. [B]Main.cpp file[/B] [CODE]#include "Pure.h" #include <iostream> using namespace std; int main() { Circle pizza(2,2,10); …

Member Avatar for Rez11
0
960
Member Avatar for mommabear

[B]Specifications (minimum):[/B] The CDROM class contains the following, private, data members: string Name; // The Name of the CDROM string CDType; // The Type of CDROM float Cost; // The Cost of the CDROM [I]The ONLY recognized (i.e., legal) CDROM types are, “Game”, “Word”, “Compiler”, “Spreadsheet”, “Dbase”, and “Presentation” (AND, …

Member Avatar for mitrmkar
0
148
Member Avatar for rcogq7

//This is the error that i have Exception in thread "main" java.lang.NullPointerException //at CardTest.main(CardTest.java:16) /** * @(#)CardTest.java * * * @Robert Coughlin * @version 1.00 2010/10/15 */ //this is the main public class CardTest { public static void main(String [] args) { Card [] randomCard=new Card[20]; for(int i= 0; i<20; …

Member Avatar for kramerd
0
219
Member Avatar for Radio2006

I am trying to start this java program using the requirements below, but I have no idea where to start. Just so you guys know, I am just starting out in this language. i have experience in Javascript programming, but this is completely different. I am used to Java programs …

Member Avatar for Radio2006
0
243
Member Avatar for emilyhedgecock

Basically, its all to do with the inventory system, all the other reams of code work fine, thank God! with the inventory, the idea is that each character can hold 5 items, so an array, but the array needs to hold the itemID and the itemName therefore an array wont …

Member Avatar for Stefano Mtangoo
0
153
Member Avatar for ana_1234

This is a friend operator overload function that used addition. It adds two mix fraction by reducing them to simplest form the adding and converting them back to a mixed number [CODE]Mixed operator+(const Mixed& f1, const Mixed& f2) { int newnum, newnum2, gcd, tmpNumerator2, tmpNumerator, tmpInteger, tmpInteger2; Mixed r; tmpNumerator …

Member Avatar for ana_1234
0
419
Member Avatar for doctorjo5

I'm having trouble figuring out a few different methods that I'm putting into a constructor. Any chance for advice? I'm having trouble with the last 3 near the bottom. I want to compare two name variable to each other to see if they are the same regardless of case, then …

Member Avatar for NormR1
0
200
Member Avatar for liran ritkop

Hi I want to build some objects that have a little difference between them. But i wonder how would i do it - 1. build a class with some variables and build objects out of him, or - 2.build class for each object, with the functions dedicated to this 'only …

Member Avatar for mike_2000_17
0
124
Member Avatar for qazplm114477

Is it possible to pass arrays into a function and/or return an array from a function? I think it's possible but I don't really know how to go about it. lets say I have a function that returns a bunch of field from a database ex: [CODE]function a($sql){ $result = …

Member Avatar for qazplm114477
0
85
Member Avatar for Pado

Hi all, I've finally gotten a handle on object-oriented programming (it took ages), and I really like it. But I'm still struggling with conceptualizing some things. For example, if I want to make a form using objects, do I make a Form class with a method like startFORM($name_of_action_page, $method), then …

Member Avatar for Stefano Mtangoo
0
177
Member Avatar for Takeshi91k

This is my first post here on Daniweb and I intend to do things right. I actually did read the "READ THIS FIRST" thread and instead of posting 500 lines of code I whipped up a test program I aptly titled test.cpp First I will walk you through my problem. …

Member Avatar for Takeshi91k
1
134
Member Avatar for kimiko

Just started learning java and i'm having a little trouble with my compiling im supposed to give a screen shots of my outputs if it works but vista is blocking it (asks for permission and then just hangs) ive included the questions just in case its being bleh but it …

Member Avatar for jon.kiparsky
0
226
Member Avatar for BboyRodimus

I got stuck at this error: [B]cannot find symbol symbol: variable BankAddress location: class Bank bankAddress = BankAddress;[/B] [COLOR="Red"]<------pointing at BankAddress;[/COLOR] I'm trying to instantiate an object of Address, calling the constructor of the Address class to create an object of Address. I'll post both classes, Bank and Address [B]Address …

Member Avatar for coil
0
141
Member Avatar for BboyRodimus

Here's the prompt guys: Assignment #4 will be the construction of 2 new classes and a driver program (the class containing a main method). [B]Address class[/B] The Address class describes cpu of a bank. It has following attributes: Attribute name Attribute type Description city String the city of the bank …

Member Avatar for NormR1
0
267
Member Avatar for BboyRodimus

I'm writing two classes for the main program code. I'm stuck trying to do figure out how to instantiate an object of the class Address: [B]Address class:[/B] [CODE]public class Address { private String city; private String state; public Address() { city = "?"; state = "?"; } public Address(String aCity, …

Member Avatar for sneaker
0
1K
Member Avatar for adaniel058

I have tried to create a simple class where the program passes a name and telephone number to my class type and then prints it to the screen. It tells me I have undeclared identifiers, but I am constructing my program just like an example we did in class. Can …

Member Avatar for adaniel058
0
104
Member Avatar for mloC

I was wondering how one would go about creating a structure that cannot be used by itself, i.e. only through a wrapper class. My question is what would be the syntax for this construct? I'm currently on a personal project to make simple tests from old tests, all the questions …

Member Avatar for mloC
0
110
Member Avatar for zreed

I need to code a program for my friend and it has been giving me some difficulties. This needs to have two classes, one called Tester and another called Game. And the data in the Game class needs to be pulled to the tester class after the calculations are finished. …

Member Avatar for CrazyDieter
0
197

The End.