04-11-2012
How to use functions as a system commands?
I have few functions which do some things which i have programmed to do. I want them to use that functions anytime i want. Right now if i need to use that function i have to copied that to putty and then call that function. Is it possible to do that so that i don't need to call that function. And i can use that function like unix commands.
Thanks for your help.
pd
10 More Discussions You Might Find Interesting
1. AIX
Hi,
I want to find some information regarding system specs such as CPU speed, total disk space, total RAM, network topology eg. ethernet, patch number, OS patches, database. Thanks (2 Replies)
Discussion started by: DarReNz
2 Replies
2. Solaris
Hi Friends,
I am trying to execute rsh commands from Solaris 10 system to AIX system.
When I give;
Solaris10# rsh <hostname> ls -l , it gives me an error
rshd : 0826-826 The host name for your address is not known
At the same time,
Solaris10# rsh <hostname> ---- gives me remote shell of... (25 Replies)
Discussion started by: jumadhiya
25 Replies
3. AIX
Hey Guyz,
I am preparing an inventory kindof thing about the aix servers.. I need help to find out the below details for many AIX servers..
Machine model and version
Disk Size
RAM size
no. of CPUs and thier information
list of softwares installed
I searched in web.. but not much info I... (4 Replies)
Discussion started by: thariqueakbar
4 Replies
4. Shell Programming and Scripting
Hi guys
i wanna to buil small pro as calc to do many things
for example
clear memory
specify a memory register
and so on
and quit
using scripting language like perl or awk
which command i use to deal with memory like m0 and how to clear or specify regester... (2 Replies)
Discussion started by: Ame
2 Replies
5. Linux
Am actually am new to the linux operating system and knda wana knw more about it.Please could u help me with some commands so i can start with that first.Really need your help (5 Replies)
Discussion started by: GODBLESSME
5 Replies
6. Programming
hello all,
i'm a beginner in linux programming. I need to know what is the difference between system calls and normal functions like fopen, fread etc in C?Also how to set permissions by using open system call? (11 Replies)
Discussion started by: aarathy
11 Replies
7. Shell Programming and Scripting
:wall:i'm system administrator. now i have a trouble. i want to fetch the command which the login users performed by shell.but i don't know how to process this problem.if anyone tell me how to do this work I would be very grateful.thank you! (4 Replies)
Discussion started by: anline5104
4 Replies
8. Programming
Hi friends,
I hope everyone is fine and doing well. I am facing this irritating problem. As you know that manual pages are available for both unix commands and c functions. Now when I try to check the manual pages for functions like
read
write
exit
I get the manual pages for the... (3 Replies)
Discussion started by: gabam
3 Replies
9. Shell Programming and Scripting
I have 7 functions those need to be executed as command line inputs, I tried with below code it’s not executing function. If I run the ./script 2 then fun2 should execute , how to initiate that function I tried case and if else also, how to initiate function from command line
if
then... (8 Replies)
Discussion started by: saku
8 Replies
10. UNIX for Dummies Questions & Answers
Hello!
Is File System stored in unix kernel or in pc memory?
Are unix commands stored in kernel?
many thanks! (1 Reply)
Discussion started by: pinklemon
1 Replies
LEARN ABOUT CENTOS
xmclipboardretrieve
XmClipboardRetrieve(library call) XmClipboardRetrieve(library call)
NAME
XmClipboardRetrieve -- A clipboard function that retrieves a data item from the clipboard
SYNOPSIS
#include <Xm/CutPaste.h>
int XmClipboardRetrieve (display, window, format_name,
buffer, length, num_bytes, private_id)
Display * display;
Window window;
char * format_name;
XtPointer buffer;
unsigned long length;
unsigned long * num_bytes;
long * private_id;
(void)
DESCRIPTION
XmClipboardRetrieve retrieves the current data item from clipboard storage. It returns a warning if the clipboard is locked, if there is no
data on the clipboard, or if the data needs to be truncated because the buffer length is too short.
Between a call to XmClipboardStartRetrieve and a call to XmClipboardEndRetrieve, multiple calls to XmClipboardRetrieve with the same format
name result in data being incrementally copied from the clipboard until the data in that format has all been copied.
The return value XmClipboardTruncate from calls to XmClipboardRetrieve indicates that more data remains to be copied in the given format.
It is recommended that any calls to the Inquire functions that the application needs to make to effect the copy from the clipboard be made
between the call to XmClipboardStartRetrieve and the first call to XmClipboardRetrieve. This way, the application does not need to call
XmClipboardLock and XmClipboardUnlock.
display Specifies a pointer to the Display structure that was returned in a previous call to XOpenDisplay or XtDisplay.
window Specifies the window ID of a widget that relates the application window to the clipboard. The widget's window ID can be obtained
through XtWindow. The same application instance should pass the same window ID to each of the clipboard functions that it calls.
format_name
Specifies the name of a format in which the data is stored on the clipboard.
buffer Specifies the buffer to which the application wants the clipboard to copy the data. The function allocates space to hold the
data returned into the buffer. The application is responsible for managing this allocated space. The application can recover
this allocated space by calling XtFree.
length Specifies the length of the application buffer.
num_bytes Specifies the number of bytes of data copied into the application buffer.
private_id
Specifies the private data stored with the data item by the application that placed the data item on the clipboard. If the appli-
cation did not store private data with the data item, this argument returns 0 (zero).
RETURN
XmClipboardSuccess
The function was successful.
XmClipboardLocked
The function failed because the clipboard was locked by another application. The application can continue to call the function
again with the same parameters until the lock goes away. This gives the application the opportunity to ask if the user wants to
keep trying or to give up on the operation.
XmClipboardTruncate
The data returned is truncated because the user did not provide a buffer large enough to hold the data.
XmClipboardNoData
The function could not find data on the clipboard corresponding to the format requested. This could occur because the clipboard
is empty; there is data on the clipboard but not in the requested format; or the data in the requested format was passed by name
and is no longer available.
RELATED
XmClipboardEndRetrieve(3), XmClipboardLock(3), XmClipboardStartCopy(3), XmClipboardStartRetrieve(3), and XmClipboardUnlock(3).
XmClipboardRetrieve(library call)