190 Topics

Member Avatar for
Member Avatar for Tycellent

Hey guys, I'm interested in learning about simple multithreading in C++ for Windows. Does anyone have any reccommended tutorials/links thats quite good?

Member Avatar for dinad578
0
414
Member Avatar for robert.knighton.79

I'm simply trying to keep a log list for my application events. I'm trying to send text to the log from a seperate thread with the following code: Imports System.Threading Public Class Main Private worker1 As Thread Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load worker1 = New …

Member Avatar for AleMonteiro
0
485
Member Avatar for krystosan

I am on OSx and I am trying to exit the program by pressing CTRL+C. but it seems like even if I have a signal handler registered in main thread it doesn't exit while the thread is executing on pressing CTRL+C. Here is a piece of cake where I am …

Member Avatar for TrustyTony
0
2K
Member Avatar for getnit

I am trying to establish a pause and play communication between threads.I am spawning two threads for two forms at the startup, one is the mainthread which is for mainwindow and second thread of form2, var thread = new Thread(ThreadStart); thread.TrySetApartmentState(ApartmentState.STA); thread.Start(); private static void ThreadStart() { Application.Run(new SecondForm()); // …

0
145
Member Avatar for Xheis

Hi, I have to create a program that creates N child processes, and they muliply the matrix. I have some base codes but when I try to run them they give me segmentation error and I cant find the problem. #include <stdio.h> #include <stdlib.h> #include <time.h> #include <unistd.h> #include <sys/types.h> …

Member Avatar for David W
0
308
Member Avatar for pwolf

I was following along to the following tutorial - [Derek Banas Java tutorial 18 - Threads pt2](http://www.youtube.com/watch?v=G2Xd5avyk_0) and as I decided to go over his tutorial series by following along in notepad++ and compiling with the command line, so that I can experiment and test things I'm unsure about, I …

Member Avatar for pwolf
0
1K
Member Avatar for dhatsah

Quick question, the answer is eluding me on the internet. Which is unusual. When we reference and call a sub/function from a class is it automatically started on a new thread or will it join the main thread? Cheers in advance.

Member Avatar for Ancient Dragon
0
211
Member Avatar for greatman05

Hello. I need to set up some pipes for a homework assignment as part of a bigger project. The issue I'm having is that the array (args) I'm using to populate the pipe arguments keeps segfaulting and I don't know why. Everything has been malloced beforehand and the faults only …

Member Avatar for greatman05
0
258
Member Avatar for manaila

Hi, I have learned that servlet containers like tomcat handle concurrency in web application. I just want to get a clear comfirmation whether I dont have to multithread my business logic classes/methods(e.g database connections) when I am developing servlet applications. Cheers!

Member Avatar for LastMitch
0
96
Member Avatar for haresh.sankarraj

Hi members, This is a program i wanted to implement semaphore between parent and child processes which are trying to access a shared variable called counter ... i dont know why it is not getting incremented during the child process !! someone help please !! #include <stdio.h> #include <sys/types.h> #include …

Member Avatar for rubberman
0
2K
Member Avatar for emaellie

Hi ya guys, I have been learning about forks and processes, below is my code that i have created but am having difficulty on certain things. **1. Add code to print out and note the values of :** i. The values held within the array fd[ ] from the parent …

0
122
Member Avatar for Qwert_1

Here is a code that creates two childern using fork. My question is how can we create mutiple grandchildern and great grandchildern at the same time . And the line 21 of code gives an unexpected output i.e instead on one parent id it gives three id's. Here is the …

Member Avatar for rubberman
0
1K
Member Avatar for Ancient Dragon

I have a program with DataGridView which is bound to MS Access table. When I addept to update I get "Syntax error in INSERT INTO", but no explanation about the syntax error. Column names in the table have a space in them, such as "Last Name". Could that be the …

Member Avatar for Ancient Dragon
0
522
Member Avatar for yssirhc

Further along in this code I'm trying to access processRow, which is of type DataRow, but I get a RowNotInTableException This row has been removed from a table and does not have any data. In an attempt to figure out when this data is getting deleted, I added a bunch …

Member Avatar for lolafuertes
0
209
Member Avatar for Rahul47

I was reading through Javascript overview on a webiste that stated following: 1) JavaScript can not be used for Networking applications because there is no such support available. 2) JavaScript doesn't have any multithreading or multiprocess capabilities. My Questions: 1) Which kind of 'Networking Applications' are we talking about? 2) …

Member Avatar for Rahul47
0
230
Member Avatar for John Linux

In a past prac. exam for an algorithm course I'm doing is the challenge below, and their are no solutions but it seems like a really interesting one to solve. Can someone please help and point me in the right direction, I would like to try this on my own, …

Member Avatar for Sergio_1
0
507
Member Avatar for poopuh

I've been asked to edit the code in this post http://www.daniweb.com/software-development/java/threads/455560/java-recursion-brute-force-sim so that it "Runs the function as a thread which wouldn’t then hang the program whilst it’s waiting for the result". I've looked it up, but I'm struggling to apply it to this program, any tips?

Member Avatar for JamesCherrill
0
637
Member Avatar for nitin1

can anyone give me some good references or links or some guidelines to start with this ? i need to learn this. like i want to know how can i implement malloc, calloc, realloc etc. for this thing also, what do i need to learn firstly ? thanks. any kind …

Member Avatar for Ancient Dragon
0
144
Member Avatar for DJ-DOO

Hi Folks, I am writing an app that involves Client -> Server -> Client communication (one way traffic). I have my data transmitted from client A to the server, simple to test, just print to console, however, I'm trying to test to see if the data has been sent on …

Member Avatar for DJ-DOO
0
253
Member Avatar for Ondrej.Behulek

Hello, I have a course that is Operational Systems.. My lecturer doesnt explain so much and after He say, You must solve this problem, because u r a programmer.. I have such a problem with linux programming. I put my code here, He wants, I must allow multi-client to server. …

0
241
Member Avatar for cacofonix

Hi All, In my script, i am trying to call multiple fork call. if i call less than 10 times, its working fine. If i call more than 20 or 30 times, most of the process getting time out or died foreach my $ttyport (@processTTY) { my $pid = fork();Inline …

Member Avatar for coding101
0
144
Member Avatar for Fredszky

So i'm trying to make multiple clients logon to a server through filesockets, and perform simple commands like ls -l, ls, mkdir. I've managed to make one client recieve output of ls -l command, sometimes, its buggy. Now i've been sitting for days trying to figure out how to fork() …

Member Avatar for Fredszky
0
6K
Member Avatar for devilmaycry1

hi friends I've a code to compute integral with area function in code. I used Fork, and for returned values I must use shared memory. now I need to embed a semaphore in my code to control the critical area(here is shared memory). I don't know how to embed semaphore …

Member Avatar for DeanMSands3
0
2K
Member Avatar for AutoPython

[B]!USING PYTHON 3.1![/B] Hello DaniWeb! Today I'm going to be posting a [B]simple[/B] threading tutorial. First of all, what is threading? Well, threading is just another way of doing a side task without interrupting the main program. Now here's a simple example. Let's say we are going to make a …

Member Avatar for nytman
3
1K
Member Avatar for boiishuvo

Okay I am trying to write a program where a parent process creates three child processes. Also waits for each of them to finish. Here is my code: [code] #include <stdio.h> #include <unistd.h> main() { int i; // create 3 child processes for (i = 0; i < 3; i++) …

Member Avatar for rakeshbiswal
0
4K
Member Avatar for fabio.bozzo

Hi to all, I'm using the WIA Aut. Library [url]http://www.microsoft.com/downloads/details.aspx?familyid=a332a77a-01b8-4de6-91c2-b7ea32537e29&displaylang=en[/url] , trying to capture photos from 5 digital cameras (Nikon D90) USB-connected to my pc. Now, I partially achieved my goal, what I do is: - loop through the attached devices, connecting to every camera; - fotocamera.ExecuteCommand (WIA.CommandID.wiaCommandTakePicture) ; - …

Member Avatar for vince8290
0
524
Member Avatar for crownedzero

Still playing with multi-threading and Prod-Con, at this point I've been at this for days. Would love some help debugging; thanks in advance. http://pastebin.com/jhHB9kTY - Main http://pastebin.com/BZSspf3x - Consumer http://pastebin.com/ndzAADJz - Producer http://pastebin.com/p7YdzH1D - Product http://pastebin.com/rxs3WzDT - Message http://pastebin.com/JR5ywgz1 - Utiliy 2 Producers, 4 Consumers Essentially Producers push a message …

Member Avatar for crownedzero
0
250
Member Avatar for shujat132

**My academic assignmentt ** **Please help me in coding for this assignment** In Linux Ubuntu flavor, write a program in C language to do the following tasks. 1) Use fork ( ) system call to create a child process. 2) Child process should first take student name as input and …

Member Avatar for khudayar
0
2K
Member Avatar for crownedzero

I see this example frequently and thought I'd give it a shot but I've got something unexpected happening with my Queue. I have multiple threads utilizing my producer class but the output doesn't show that it is being written to by each thread. protected Queue<ProductMessage> prodQueue = new ConcurrentLinkedQueue<>(); @Override …

Member Avatar for ~s.o.s~
0
279
Member Avatar for jnewman3

I'm applying the peterson solution for protecting memory of the critcal section. Each child process should contain a local variable that keeps track of the number of times it interrupts the other child while it is in its critical section. The process should display this value before terminating. I'm having …

Member Avatar for Ancient Dragon
0
2K

The End.