17 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for hotelsinger

I am a programmer. That's why I'm receiving a paycheck. I sit alone in a small cubicle and do my work. I don't do desktop support and I'm not interested in working closely with users. So my boss says to me today that I am being signed up for a …

Member Avatar for diafol
2
390
Member Avatar for NardCake

Hello! So I currently have a class titled Appliciation which contains a method called start. <?php class Application { /* * Application class */ public function __construct($IceTray){ $this->IceTray = $IceTray; } /* Starts application */ public function start(){ /* Confiures error reporting */ $this->IceTray->Error->configure(); $Path = $IceTray->Path; include APPDIR.'/paths.php'; $Path->start(); …

Member Avatar for NardCake
0
290
Member Avatar for singularity~

I have declared a local variable inside of getAddress. When I try to access that variable inside a local function it falls outside its scope. What am I doing wrong? function getAddress(latlon, map) { var data = ""; $("#map-canvas").gmap3({ marker: { latLng: latlon, options:{ draggable:false, }, }, getaddress:{ latLng: latlon, …

Member Avatar for singularity~
0
268
Member Avatar for pars99

Can you please help me and tell me what I am doing wrong? I have been looking at the program for two hours and need help. I keep getting this error: 'triangle' was not declared in this scope. Also, that is the only error, so I don't have anymore. Thank …

Member Avatar for pars99
0
2K
Member Avatar for dancks

Based off some stuff from my last thread I tried to write a search results page using maximum 3 parameters. I used a couple of function to try and get everything organized. One: sort_mysql_results has no defined parameters so I can put in as many parameters as needed. The code …

Member Avatar for dancks
0
325
Member Avatar for nexocentric

I'm having a small problem with a variable in one of my PHP scripts. The variable is `$isSubMenu`. It gets set using a function that runs recursively called createNavigationMenu. However, even though I have set it, the interpreter keeps telling me that the variable is undefined. I really don't know …

Member Avatar for nexocentric
0
563
Member Avatar for kutchbhi

This is the project I am reading from . [url]https://github.com/sasatomislav/PHP5-OOP-Cart[/url] [CODE] class Cart { <snip> private function __construct() {} /** * Fetch Cart instance * * @return Cart */ public function getInstance() { if (NULL === self::$_instance) { self::$_instance = new self; } return self::$_instance; } } <snip> // initialize …

Member Avatar for pritaeas
0
262
Member Avatar for Labdabeta

I was working on a project when I thought that maybe a ::. operator would look funny in some code. Just for fun I typed that into the global scope area like this: [CODE]::. int main() { //etc...[/CODE] and my code completion software said too many results to display. My …

Member Avatar for Labdabeta
0
190
Member Avatar for learningcpp

Hi Guys, What is the scope of the exception variables when I catch them by reference. [CODE] try{ throw AnExceptionObect("Exception message"); } catch(AnExceptionObect &exp){ logger << exp.what(); //logger is a dummy object throw; //what will happend now? is it going to be throwen by value? and what if I catch …

Member Avatar for learningcpp
0
197
Member Avatar for IMJS

Hello, please can I have some clarification to check I am not doing something very stupid? It seems sensible with all that I have read, but I'm not confident. I suspect I have memory leaks and want to make sure some fundamentals are correct before I start looking deeper. My …

Member Avatar for mrnutty
0
172
Member Avatar for mklein

Dear all I am brand new to C# and have previously only written programs in Javascript, so go easy on me ! I have written an "app launcher" program which reads a text file line by line. Each line is just a path to a program e.g. C:\Users\Matt\Desktop\Gravity.exe So far, …

Member Avatar for mklein
0
198
Member Avatar for Jsplinter

I have a nested class declared as: [CODE]class A { class B { // members }; // members }; [/CODE] Is there a good way to avoid typing A::B every time I need to access B's members? I'd just like to do this in one .cpp file. I tried "using …

Member Avatar for Jsplinter
0
223
Member Avatar for techie1991

Even after looking at a lot of books, I am not able to understand the problem in the following code: [CODE] //1.c static int y=23; void abc(int a){ printf("%d\n",a); } [/CODE] [CODE] //2.c #include<stdio.h> #include "1.c" int main(){ abc(12); printf("\n"); printf("%d\n",y); return 0; } [/CODE] I can understand that the …

Member Avatar for techie1991
0
233
Member Avatar for dare599z

Hello all, I'm taking a intro computer science course, yet somehow I'm much better at c++ than python. My professor is essentially useless. Can anyone show me how to let these variables persist into global scope? I assumed declaring them globally would make them persist, yet it appears to not. …

Member Avatar for dare599z
0
183
Member Avatar for adaniel058

[ATTACH]17854[/ATTACH] [ATTACH]17855[/ATTACH] [ATTACH]17856[/ATTACH] Guys I am trying to help a friend of mine with this project they have due in a few days and because I program in Java mainly I am a bit rusty with this. I can not figure out why my getInput function shows up under the …

Member Avatar for adaniel058
0
135
Member Avatar for jwebb

Hello, I'm trying to create a program to calculate the factorial of variable int input. I am using xcode, and it's giving me an error saying "factorial was not declared in this scope" on the line within the else statement. I have found other programs on the internet, but I …

Member Avatar for jwebb
0
658
Member Avatar for richman0829

If I uncomment the 'int x;' above main, and comment out the int x = 0 inside of main, it works, but I don't want to use global variables. What I can't understand is why x is out of scope. The text I'm using says “vars having local or block …

Member Avatar for richman0829
0
123

The End.