49,761 Topics

Member Avatar for
Member Avatar for martindeveloper

Hello. Right now I'm trying to write simple C++ application for internal website testing. I need to send request (ping) to website and do it repeatedly. But I do not know how can I simple ping website without using [ICODE]system("ping xxxxx");[/ICODE] My current code: [CODE] #include <iostream> #include <Windows.h> void …

0
39
Member Avatar for nekoleon64

My name is Leonard Norwood Jr. If anyone knows a program that will estimate the number of boxes of tile needed for a job. A job is estimated by taking the dimensions of each room in feet and inches and converting these into a multiple of the tile size (rounding …

Member Avatar for nekoleon64
0
545
Member Avatar for Ahmed2

hello there, I'm trying to sort a list according to the "length" paramter in ascending order, which represents the third coloumn. List elements are read from a csv file contains 9 coloumns, I only push 6 coloumns in "futurelist" which is the information i'm intersted in. //input csv data [CODE] …

0
112
Member Avatar for K0ns3rv

Hey! So I've been playing around with OpenCl a lot recently and it's pretty impressive. The first thing I wanted to do was to make an mandelbrot set generator, so I did. It works wonderful and I am really amazed by the results, almost a thousand times faster than my …

Member Avatar for K0ns3rv
0
407
Member Avatar for dlmagers

Ok, I am trying to work through this program and it is stopping at asking me what is my current salary. The problem is this: Starting January 1st, of each year for three years, I will be getting a raise of .05 on my previous years salary. I wasnt a …

Member Avatar for zeroliken
0
114
Member Avatar for triumphost

Hey guys I'm having an extremely hard time splitting or combining values into binary.. [CODE] #define Chr(n) ((char)(n)) #define Ord(c) ((int)(unsigned char)(c)) int DecToBin(int Num) { int Bin = 0, Pos = 1; while (Num > 0) { Bin += (Num % 2) * Pos; Num /= 2; Pos *= …

Member Avatar for histrungalot
0
203
Member Avatar for Yaguma

Hi all, I am trying to write a C++ program to create a simple text-based interface that should print out the relevant stubs when a certain choice is made. I am however getting linking errors such as-->[Linker error] undefined reference to `Database::AddStudent()' , that i cant seem to fix. Any …

Member Avatar for Yaguma
0
188
Member Avatar for dymatic

So, just for fun I have been making a small text-based game to test my knowledge of C++ so far. However, I have encountered an odd error where commands will execute once, and then after that return the same output repeatedly. Could anyone analyze this and see what's wrong? Here …

Member Avatar for Ancient Dragon
0
255
Member Avatar for infamous5

Hello, I am a beginner at programming and I am having some trouble finding the error in my code(pasted below). I am first trying to come up with a (1) function to evaluate integers at a given power.(2) A function to check if an integer is a perfect number. I …

0
138
Member Avatar for freedomflyer

I am running into (pretty serious) valgrind issues as I run my application. As far as I can tell, my BST has some memory loss, to put it rather clinically. I've tried to create the right destructor on my BST<T> class, which contains BSTNode<T> nodes (both are shown below in …

Member Avatar for mike_2000_17
0
590
Member Avatar for dasdgfds

*Pass by value, reference I need to write 4 functions including main to display a report with the size of room in square feet, cost of carpet,cost to install the carpet. I am having trouble with using the last function to compute the costs using data from the other functions …

Member Avatar for dasdgfds
0
159
Member Avatar for luislupe

Hi, I'd like to print a line of 'double' or of 'integer' type according to T typename. I tried to compare T with typeof but to no success. [CODE] template <typename T> void printArray(unsigned int x_sz, unsigned int y_sz, T * arr[], std::string title) { double f; unsigned short int …

Member Avatar for mike_2000_17
0
164
Member Avatar for bloominninja

Hi, I'm getting pretty frustrated with my code at this point, Im trying to implement a queue class to hold a number of integers... however dev (the compiler im using) keeps spitting out the errors [CODE] [Linker error] undefined reference to `QueueType<int>::QueueType()' [Linker error] undefined reference to `QueueType<int>::~QueueType()' [/CODE] here …

Member Avatar for bloominninja
0
235
Member Avatar for nunca

Hello I had a problem about using mathematical formulas. someone showed this this site : [url]http://software-dev.jimdo.com/[/url] I found there the application, but I don't know how to get the unit. did someone already use it?

Member Avatar for ravenous
0
101
Member Avatar for abhishekagrawal

Dear All, I have written a code to implement an algorithm for base conversion from decimal to any base between 2 and 36 given in RG Dromey. Below is my code and I have a few questions relating to it: [CODE] #include<stdio.h> #include<stdlib.h> int main() { int newbase,zero=atoi(0),q,ndigit=0,r,ascii,i; char newrep[100]; …

Member Avatar for thines01
0
275
Member Avatar for tahir696

i want to perform operations on large integers which are of 256 bits i mean i want to handle a hundred digit integer and perform multiplication and division on them is there any good idea to store them and then use them easily

Member Avatar for gerard4143
0
33
Member Avatar for Programming++

So, I'm working on making a encrypted in C++, just a basic one. The encrypter needs to have a minimum character limit but it's not working. It's not coming up with any compiler errors, but instead just acting as if the if statement isn't there... [code] #define _WIN32_WINNT 0x0500 #include …

Member Avatar for mazzica1
0
208
Member Avatar for meme meme

please help meeee write a program for a local bank to manage their accounts. the bank offers two account types,saving and checking,each customer must maintain a minimum balance, if the customer`s balance falls below the minimum ,ther is a service charge 10 aed for saving and 25AED for checking. the …

-4
45
Member Avatar for Johnathon332

Hi I have wrote some code but it never seems to reach the for loop and cannot understand why. I want it to check whether or not the word is in the array and if it is it will break out and leave the method else it will add to …

Member Avatar for Johnathon332
0
116
Member Avatar for revenge2

hello there. i've installed mingw compiler and im wondering how i would go about setting up notepad++ to compile my c/c++ code?. How do i do this? -regards.

Member Avatar for jussij
1
840
Member Avatar for mattiapdo

It doesn't run! Can you help me please? Devc++ compiles it, and also launch the exe file, but it stops after the second for cycle! Why? :D [CODE]#include <iostream> #include <string> using namespace std; int main() { int N,i,z; cout<<"Digitare il umero di caratteri che contengono il nome "; cin>>N; …

Member Avatar for LdaXy
0
168
Member Avatar for BillyD282

I am receiving the following error messages and I can't figure out why, I'm guessing there's just some syntax rule or something I am just unaware of... there errors are: error LNK2019: unresolved external symbol "void __cdecl validateWidgets(int &)" (?validateWidgets@@YAXAAH@Z) referenced in function "void __cdecl manager(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)" …

Member Avatar for MandrewP
0
437
Member Avatar for triumphost

How can I make my DLL constantly check for hotkeys but without affecting other functions in it? If I put a loop, it will not be able to get any other calls to functions.. Do I create a thread and pass my functions to the thread upon attachment? My silly …

Member Avatar for LdaXy
0
244
Member Avatar for triumphost

I'm trying to convert this (Pascal) to C++.. My attempt is below this.. [CODE] function CompressString(const Str: string): string; var Destlen:longword; begin result := ''; Destlen :=BufferLen; if length(str) < 1 then exit; if compress(BufferString,destlen,PChar(Str),length(str)) = Z_OK then begin setlength(result,Destlen + SizeOf(Integer)); PInteger(@result[1])^ := Length(str); Move(bufferstring[0],result[5],Destlen); end; end; [/CODE] [CODE] …

0
78
Member Avatar for tom12

HEY guys i have a question, i have a program that takes a string and then it gives three levels of encryption 1 to 3. i have no problem with the code as its working. its just when i compile it, if i choose option 1, i need to recompile …

Member Avatar for Ancient Dragon
0
91
Member Avatar for Labdabeta

I recently looked at [URL="http://www.songho.ca/opengl/gl_vbo.html"]this[/URL] description of VBOs and a sample implementation of them. When I ran the executable, it was significantly faster with no VBOs than with them. I don't understand why it should be slower with the VBOs than without. Can anybody explain why?

Member Avatar for raptr_dflo
0
329
Member Avatar for triumphost

My code is: [CODE] #include <windows.h> #include <iostream> using namespace std; struct ReplacementFlags { public: bool rfReplaceAll, rfIgnoreCase; ReplacementFlags(bool ReplaceAll = false, bool IgnoreCase = false) : rfReplaceAll(ReplaceAll), rfIgnoreCase(IgnoreCase) {} ~ReplacementFlags() {} ReplacementFlags& operator ()(bool ReplaceAll = false, bool IgnoreCase = false) { if((rfReplaceAll != ReplaceAll) && (rfIgnoreCase != IgnoreCase)) …

Member Avatar for triumphost
0
205
Member Avatar for TheWind147

Hello! Below is a function exhibiting a simple stopwatch mechanism. It stops when the user presses any key and goes back to the main menu. My question is, is there anyway I can pause the time and continue it as desired by the user? I would like to use "P" …

Member Avatar for WaltP
0
3K
Member Avatar for nuclear

Example code: [CODE]HWND CreateButton(const HWND hParent,const HINSTANCE hInst,DWORD dwStyle, const RECT& rc,const int id,const ustring& caption) { dwStyle|=WS_CHILD|WS_VISIBLE; return CreateWindowEx(0, _T("button"), caption.c_str(), dwStyle, rc.left, rc.top, rc.right, rc.bottom, hParent, reinterpret_cast<HMENU>(static_cast<INT_PTR>(id)), hInst, 0); }[/CODE] The part I dont get is: [CODE]dwStyle|=WS_CHILD|WS_VISIBLE;[/CODE] So the question would be why do we use '|' and …

Member Avatar for VernonDozier
0
242
Member Avatar for tj104

hey what's up guys, I'm writing some C++ code used to do math operations on polynomials that are contained in a input file. Right now I'm stuck on the actual streaming in of the files. The .txt input file is in the format as follows 1 1 2 2 3 …

Member Avatar for Lerner
0
146

The End.