42 Posted Topics
Hello everyone, I want to start implementing some of my mathematics knowledge into programming through AI. Back 3 months ago I had no idea what is AI, but then I took Machine Learning course on Coursera and finally realized how much maths is included in AI. However I wasn't able … | |
Hi guys, I haven't been on daniweb for a while, I've started learning scripting in UDK. But still I wish to make smaller games using native languages. So here goes my question: what is the best IDE for programming small games with nice UI? So far, for programming win apps … | |
Re: [QUOTE]Allrigt.. I was having the same "id returned 1 exit status". I googled some, ended up here. Then I found out the solution for my problem. Lol. Make sure you have finished running you program in the console, the try to compile again. OP's don't usually like it when you … | |
Hi people, I am making a little experiment to see something. I wished to inherit "string" class and add a function to child class. Function should take a char as parameter and return bool depending on is there such a character in our string or not. I have started off … | |
Hi, Do you have any useful explanation of how to create a draggable window? What I wish to say is when you select your window will have no border ( considering that, it cannot be dragged around screen), how to make it draggable, for example by making a certain area … | |
Hi, I need little help with using MediaPlayer from System tab in Borland Builder 6 for C++. Does anyone know what member function of MediaPlayer returns bool variable which tells us is music currently being played or not? I have seen solution for this problem where we use Timer which … | |
Hi, Is anyone familiar with this problem in BorlandBuilderC++: void Print(AnsiString Path){ Label1->Caption=Path.c_str(); } ... Print("C:\Directory1\Directory2\Music.mp3"); When I pass this string to Print(AnsiString) and try to display it in Label1, I lose all '' signs and text in Label1 looks like this : **"C:Directory1Directory2Music.mp3"** Why is this like that? Thank … | |
Hi, I have simple question: how do I make Windows Media Player in BorlandC++ ( an ActiveX component ) plays all songs from specified folder? Thanks. | |
Hi, There is short explanation of queue at cplusplus.com site which tells that queue should contain front() and back() functions. As I have tested in VC++, if I use queue from <queue> and call any of these functions for an empty queue, program crashes. Could this problem be solved by … | |
Hi, Can you tell me how can I make my application recognizes when the user presses a button on keyboard? *For example*: presses 'S', application prints "Hello.". I need this information for BorlandC++, but it would be useful even though you provide the same for VC++ :) *(I am not … | |
Hi, I am learning queues and I have found 2 examples. Both examples represent queues with limited size, for example 30. But <queue> allows us to create queue that is not limited by ***pre-set** queue size. Can anyone explain me how have they created something like that? Thanks! ***By *pre-set* … | |
Hi, I have read this on IBM: > > An exception specification may only appear at the end of a function declarator of a function, pointer to function, reference to function, pointer to member function declaration, or pointer to member function definition. An exception specification cannot appear in a typedef … | |
Hi, I have read something on IBM's site about exception specification and pointers to functions: void (*f)(); void (*g)(); void (*h)() throw (int); void i() { f = h; // h = g; This is an error. } IBM says: > The compiler allows the assignment f = h because … | |
Hi, I have been playing around with pointers and made a little mistake of this type: class D{ public: int a; }; int main() { D *x; //As you can see I didn't allocate memory at all... x->a=3; // ... but initialized a member variable cout<<x->a<<endl; return EXIT_SUCCESS; } I … | |
Hi, I've been searching around about DLLs and I can't get what they actually are. Why do we need .cpp, .h and .dll file and how do we link it using CodeBlocks? I used tutorials to create DLL files, and it was successful, they contained 2 functions, but linking is … | |
Re: How did you make a keylogger in VC++ without knowing how to compile the exe file and use it independently outside of the compiler? | |
Hi, I have recently finished first game in C++ which has huge code which will be fixed in future who knows how many times. It is really not practical to publish entire .exe launcher as fix, but I heard that it isn't case with DLL files. I could simply create … | |
Hi, I found the examples of explicit specialization, but I have a vagueness about code: using namespace std; template<class T = float, int i = 5> class A { public: A(); int value; }; template<> class A<> { public: A(); }; template<> class A<double, 10> { public: A(); }; template<class … | |
Hi, I have made some sorting function based on finding largest element and swapping its place with last element of array and then searching largest element of rest of array and putting it on one place before last one and so on. I am curious about is there a name … | |
Re: [QUOTE]i am making hangman game and i want the program to pick up random wrds... how can i do it???[/QUOTE] I haven't done anything similar to it, but you'd need database which contains words. And you'll need some "Input/Output with files" skills to get words from database ( for example … | |
Hi, When writing a little code for showing ASCII characters in C++ and C, the only difference is when I do it in C++ I print until char ( or integer ) reaches value of 127, and in C I print until it reaches 255. Why it's like that? Thanks! | |
Hi, I am learning templates so I have one question for this code: [CODE]template<typename T, int Number> class Data{ T Array[Number]; public: T& operator[](int); }; template <typename T,int Number> T& Data<T,Number>::operator[](int element){ return Array[element]; }[/CODE] I wish to create specialization for that class template, for any random data type, but … | |
Hi, I noticed many programmers accuse C++ as very hard language for GUI and very good language for the code. Is there any way to integrate 2 languages, C++ and any other language which is easy to make GUI with? Thanks. | |
Hi, I need help about launching a web site in default browser using Borland ( button click = launch google.com, for example ). I found solution valid in DEV: [CODE]ShellExecute(NULL, "open", "http://google.net", NULL, NULL, SW_SHOWNORMAL);[/CODE] But it shows an error if used in Borland: [ICODE]Access violation at address 0A1826C8 in … | |
Hi, I have an app created in Borland Builder 6, on Win 7, but I tested it on Win XP, and font's size changed, some forms resized... This guy has explained the problem >> [url]http://www.tek-tips.com/viewthread.cfm?qid=1668509[/url] Anyone experienced with this? | |
Hi, Has anyone any clue why message boxes keep showing 2-3 times after clicking one of their button in Borland? Please answer, I need help. Thanks! | |
Hi, I need to create 39 images in Borland and set what will they do if you click on them. It'd be really long time to create all these using classic method ( adding images, and setting OnClick option ). But I figured out how to insert so many bitmaps: … | |
Hi, I am creating the game which has a lot of images which present buttons and their different "surfaces" which depend of cursor ( move over it, click, mouse up... ). It's really boring to add so many options, to make the button look like Vista-style, so is there any … | |
Hi, Is there any way to add specific location for images in Borland C++ Builder? For example, I have background image, but I want it to be in root folder, together with exe file (reason: I want to make it accessible for users, who has no access to the source … | |
Hi, I made code of several classes for game, not 3D nor 2D, it's like those on FaceBook where buttons are main. I'm curious, could code for that type of game be called Game Engine? Hmm... Thanks! :) | |
Re: [QUOTE]Is it possible to make an array of doubles like a c-style string to make a bigger number? Or is an array of chars a special thing to a compiler?[/QUOTE] Do you need something like this? [CODE]char Array[100]={'1','2','3','4','.','1','2','3','4','5','6','7','8'}; [/CODE] If so, I could help, I remember I did one task … | |
Re: ( I don't want to repeat 3rd time what guys above had have already done, I just want to explain why you need to do that ) Compiler reads from the top to the bottom of code, just like you read the lesson from physics. Now imagine that you read, … | |
I wonder why it ain't possible to manipulate with static member of base class from derived class. [CODE]#include <cstdlib> #include <iostream> using namespace std; class Base{ public: static double BaseValue; void Set(double a){BaseValue=a;} void GetBaseValue(){cout<<BaseValue<<endl;}}; class Derived:public Base{ public: double Count(){ return BaseValue*2; } }; int main(int argc, char *argv[]) … | |
Hi, I'm playing around with pointers and I found out something. For example, I have the array of objects of structure, and wished to point to it over the pointer which already points to it ( pointer to pointer to array of objects. ). Confusing? Code: [CODE]struct person{int number;}; int … | |
Hi, Is there any possible way to create program which'd take some data from net and store it in program memory ( some variable, irrelevant ), for example - currency list? If there's no way in console, what about using Borland Builder 6? I hope my idea ain't so absurd … | |
Hi, What's wrong with this code: [CODE] //Comments explain what I check int Array[9]={1,2,3,4,5,6,7,8,9}; int Integer=0; int i=8,n=0; for(int x=0;x<9;x++) cout<<"array="<<Array[x]<<endl; //Are all members ok? for(int exp=0;i>=0;i--){ Integer+=Array[i]*pow(10,exp); cout<<"Integer1="<<Integer<<endl; //Is Integer being summed fine? exp++; } cout<<"Integer="<<Integer<<endl; [/CODE] Program's function is to create an integer from array ( for example: … | |
Hi, I'm about to start making some little program with input of type string which'll later be converted into numbers, but it has to pass the check is there any non-digit character. Considering I was lazy to search for functions like that I decided to make my own header for … | |
Hi, I wondered if it was possible to declare the friends of class but out of it? Like this: You have created class: [CODE]class myclass{ int x; public: bla bla bla };[/CODE] And instead of this: [CODE]class myclass{ int x; public: bla bla bla friend class someclass; };[/CODE] If it … | |
Hi, I created the class for converting decimal to binary numbers and I wish to make the Windows application but there's an error: [ICODE]E2285 Could not find a match for 'TForm1::TForm1()' [/ICODE] The source code: [CODE]//--------------------------------------------------------------------------- #include <vcl.h> #include<math.h> #pragma hdrstop #include "Unit1.h" //--------------------------------------------------------------------------- #pragma package(smart_init) #pragma resource "*.dfm" TForm1 … | |
Hi, I wish to start making Windows Applications, but I need a good compiler. Considering I work in DEVC++, I can't make buttons, textboxes and other objects that easy. I wonder if there's any compiler like BorlandBuilder for C, but for C++. That'd really help me :icon_cool: So do you … | |
Hi programmers, I'm Stevan ( online nick: MrEARTHSHAcKER ). I program in C++, currently console only, but I plan to start making Windows Applications. I'm 16 and program since 14, when I started VB 2010, afterwards I learned some C and finally I decided I will be a C++ programmer … | |
Re: [QUOTE]function a() calls iteslf, which calls itself; when the third invocation returns, control picks back up in the second invocation; when the second invocation returns, control picks back up in the original.[/QUOTE] Yes, but the code goes like this: [CODE] if (level == N) print(Value, N); else for (int i … |
The End.