I edited my code. My original program is very long, so I posted only the main part of my program where I am having doubt. Thank you.
Type: Posts; User: chaituchemico
I edited my code. My original program is very long, so I posted only the main part of my program where I am having doubt. Thank you.
Hi everyone.
I am writing a program for address book. There are insert, display and delete options. In insertion, it takes input data and stores them to a file. whenever I add new contact it adds...
Thank you anduril462
This is my code with corrections. Now the code is compiling without any errors. The insertion part is doing good but there is a problem with display part. It is displaying only one person details...
Thank you anduril462. I edited my code, now it is running with no errors.
Hi guys, With your help I am able to send data between two processes using sockets. Thank you.
I tried to extend my program. This is to insert and display the details of a person.
there are two...
I am able to correct my errors guys with your suggestions. Thank you.
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<sys/socket.h>
#include<sys/un.h>
#include<unistd.h>...
I am sorry, I did not do it by purpose. May be I just overlooked it. Sorry man.
Sorry for the late reply because we did not have power for last 11 hours.
I edited my post with indented code and...
I am trying to send details of a person from client to sever and display them by server.
I am errors while compiling this code. Please help me, whether is this the correct way or not.
...
Thank you MK27.
I have gone through Serialization, it was a good document.
const char* const message = argv[2];
In the above program, I am sending data from the command prompt.
If I wish to...
Thank you MK27.
const char* const socket_name = argv[1];
Here we are giving the same socket name for server & client using command prompt.
Is there any other way I can include same socket...
SERVER.C
int server (int client_socket)
{
while (1) {
int length;
char* text;
/* First, read the length of the text message from the socket.
read returns zero, the client closed the...
@tabstop and @anduril462. Thank you guys. Now my doubt is cleared.
Guys can anyone help me to How to pass data between two different processes using sockets.
Here are the steps using sockets (correct me if I am wrong)
Process1(server):
1. Create a socket
2....
I did not get it. How to put it in the first part of shared memory.
thank you tabstop.
Is there any other way to pass the 'select' option to the second application, other than defining it in the struct and equating to particular value in its function as i did.
...
Thank you anduril462. In my code above, I have used arrays to store the data. If I want to delete or modify, can anyone help me how to write code for delete and modify in my program so that if I...
@MK27.
What you said is correct. This program should be like a address book in a phone. It should be capable of parallel processing(like in phone, though we open a contact in address book and make...
@tabstop. We have to save the data to files whenever we insert, modify or delete them immediately. So that if we display them, it should display the updated data(like address book in phone).
@anduril462 yeah sure i will make changes.
Can we use use linked lists in this program, so that it will be easy to modify and delete contacts from the file. Please anyone suggest me how to use...
@anduril462 thank you. it was a blunder i made (a[i].select=3). yes, variable 'i' has to be synchronized between two applications.
yes what you said was correct, after delete and modify it must...
yeah it make sense. thank you @tabstop.
Can anyone please tell me how to pass the select option along with data to the second application. I am getting something wrong in passing the select option...
Hi everyone. I am new to Cboard. This is my first post.
I am practicing Linux Programming. I am doing an Addressbook program in C using IPC. This program does Insert, Display, Delete and Modify. ...