Programming :: JTexrField Needs To Respond To Drop - Starting Up Another Void() With The Received ID
Mar 14, 2010
So, DnD is cool - and in Java, it works. Just set the component where the drag starts to allow that:
Quote: tblMain.setDragEnabled(true);
and - yes - the rest pretty much runs itself. I have a JTextField that happily takes the drop from the JTable (be it the whole row - I'm not there yet, still working on that)...but does not raise any events. I'd like the JTextField to raise an event:
- cleaning up the received data, now it gets the raw stuff, and I need an ID from that string
- starting up another void() with the received ID
I read the tutorials but - for blisters - cannot see the "light", please shed some (light, that is)
View 1 Replies
ADVERTISEMENT
Mar 1, 2010
I am interested in trying 64bit Ubuntu Cloud ... downloaded the file ...copied to disk ... ran the installation disk (many more setup questions that were a bit more complicated than 32bit) but successfully completed ... required to remove disk and restart ..after restart I received a black drop-down page listing (with no exit option) requiring that I enter my user name and password ... all good so far but then I was asked to enter my root administrator account number which apparently requires a sudo command. nothing I have tried in sudo commands works and my computer was blocked thereafter so I had to reinstall Ubuntu 9.10 32bit in order to just make this request...
View 4 Replies
View Related
Feb 8, 2011
I have written a small character driver, in the cleanup module at the line
int a=unregister_chrdev(Major,DEVICE_NAME);
I am getting the following error
error: void value not ignored as it ought to be
If the value return by unregister_chrdev() function is not stored in any variable it is working fine...
View 2 Replies
View Related
Mar 20, 2010
So far I have this:
Code:
int mm_init (mm_t *MM, int hm, int sz) {
int i;
[code]...
View 4 Replies
View Related
Sep 29, 2010
I have been trying to get a void pointer cast to work and I seem to have some problems. My code compiles, but when I execute it gives back garbage data. I'm not sure what I'm doing wrong.
Code:
int main()
{
[code]....
View 7 Replies
View Related
Feb 5, 2011
I have a problem with correctly using a void pointer. I am writing a system that can open plugins and run them, and so far everything is going fine: I have a struct with some variables in, some function pointers, and I've written a small library to handle these correctly to communicate with the plugin. My challenge is that I need to put a pointer (let's call it "context") into this struct. The type is not important to the main body of code, and it is not ever used except by the plugin. The plugin will malloc some space for itself, and this *context will then point to whatever malloc returned. context is the address to a struct that I typedeffed to "ctxt".
Here is the first struct I mentioned:
Code:
typedef struct slave {
int val1;
int val2;
int (*entry)(struct slave*, int a, int b);
void *context;
} target;
Here are some snippets from the plugin:
Code:
typedef struct context {
int a;
int b;
} ctxt;
(*target).context = malloc(sizeof(struct ctxt));
So that (*target).*(ctxt)*context.a should refer to the int a in struct context.
But the error that the compiler gives me is a syntax one:
"expected identifier before '*' token"
Is my logic correct? Is my C correct?
View 11 Replies
View Related
Aug 27, 2010
I was going through a file known as linux-2.6.34/kernel/timer.c and found following code.
static inline void
timer_set_base(struct timer_list *timer, struct tvec_base *new_base)
{
timer->base = (struct tvec_base *)((unsigned long)(new_base) |
tbase_get_deferrable(timer->base));
}
I want to understand what is it doing. What is the meaning of static inline in above? I searched and came across
[Code]...
View 4 Replies
View Related
May 11, 2011
i have problem in socket programming, while displaying received message in file,i got a problem... i cant able to write it in the file.... this is the code....
Code:
/* tcpserver.c */
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <stdio.h>
[Code]....
now my problem is run time error i can able to create file but i cant able to write file....log.txt contain nothing.... as here i have give sample code... dont say not initialising function and all.... i have initialised , please only see func1() - my problem is only not able to write msg which i got received from the client..
View 2 Replies
View Related
Apr 25, 2009
I was wondering if you could recommend a simple way to achieve functionality where received email messages are automatically processed and used in SQL commands (depending on certain criteria, of course). For example, say I have made a PHP-based blog application and it's located at example.com and I'd like to give members the option of posting to their blogs by sending email to a special @example.com address. The email messages received there will be inserted into a database depending on the sender's address, with the body becoming the post and the subject line becoming the post's title, etc.
Another example could be how those trouble ticket systems let customers submit tickets via email, while the support agents operate via a database-driven Web application. Is this the type of thing one must code from scratch, or is there an open source solution out there which only needs to be configured accordingly?
View 4 Replies
View Related
May 29, 2010
I'm working on an application that makes http requests using HttpRequest and it's been doing what I need so far without a problem. Now I need to make https requests as well and when I try to make the request, i get this error message:
Code:
Fatal error: Uncaught exception 'HttpInvalidParamException' with message 'Empty or too short HTTP message: ''' in /home/antoranz/waneesia/html/index.php:0 inner exception 'HttpRequestException' with message 'SSL connect error; gnutls_handshake() failed: A TLS packet with unexpected length was received. (https://www.paypal.com/)' in /home/antoranz/waneesia/html/index.php:104 Stack trace: #0 /home/antoranz/waneesia/html/index.php(0): HttpRequest->send() #1 {main} thrown in /home/antoranz/waneesia/html/index.php on line 0
What's going on?
The project: url
View 1 Replies
View Related
Feb 27, 2010
I wanted to know how can I set a period of time to a tcp connection to wait for request or respond for tcp block read. which system call or function I can use? Does any body know a very simple quick and easy reference on web for socket programing that has lots of socket programing examples in it?
View 1 Replies
View Related
May 24, 2010
I have tried to google it around and couldn't find any good solution for it. What I want is to hook up to the kernel network hooks and for example investigate all of the packets (maybe keep some in the buffer and drop in the kernel so I could send them out lets say 10 minutes later) but from a C / C++ program perspective / level. I know it can be done via iptables but isn't there a way to do it from a program ?? I have found a library called ipq but apparently doesn't work with kernel 2.6.x anymore.
View 10 Replies
View Related
May 3, 2010
I have a script that writes the following type lines to a file. The lines include some html tags. Here is an example:<p>Total = 5</h2></b></center>I want to keep the <p> tag, but remove the ending 3 tags. Sometimes the line can have a 1, 2, or perhaps a 3 digit Total. So I could have a Total = 125.Anyway, after the removal of the ending tags the result would be:<p>Total = 5There are some lines in the file that end with </h2></b></center> that I want to keep. These lines looks generally like this:
<p><b><center><h2>Events Summary for Sun May 02 2010</h2></center></b>
As you can see I am using sed to change the beginning and end of lines to make a very simple web page.The file actually displays ok in a browser with the extra tags on the end, but it is just sloppy work to have these unneeded tags in the output file.
View 2 Replies
View Related
Jun 4, 2011
I've got a non-urgent but itchy thing here - I'm implementing a drag-and-drop. All rolls well, but I'd like to have the component be "followed" - if there is a drag on the component, the form should be visible. I'd like to make a puzzle where the player can see the perimeter of the piece to see if it fits where (s)he'd want to drop it. Before I delve into the tons of code, I'd like to know if that (the following) can be done.
View 2 Replies
View Related
Feb 9, 2011
I'm trying to make a very small script with greasemonkey to do some automatic things when a page loads. The first thing I need to do is to click on a link. I've done that. Then I need to select the 3rd element of a drop down list that appears a few moments (depending on the connection) after the link is pressed, without reloading the page (ajax or something like that). This I can't get to work, The select has no id or class, but I can get its xpath value. There is only one select on the page. I've tried both setTimeOut and the DOMNodeInserted event with no effect.
Code:
// ==UserScript==
// @name test
// @namespace "www.google.com"
// @include www.mywebpage.com
// ==/UserScript==
[Code]....
View 11 Replies
View Related
Jul 26, 2011
We have an application which allows user to perform Drag and Drop operations. The problem we are facing now is the application crash. System works fine for some time and allows user to perform many drag drops successfully. But after running for some time and user perform a drag and drop the system crashes.Following stack trace we are getting while system crashes.
XtDispatchEvent [Event.c]
RemoveAllPMgr [libXm.so.3]
XtCallCallbackList [Callback.c]
[code]....
View 1 Replies
View Related
Apr 26, 2010
When I paste a text selection from a Firefox page into a text field in the page, the selection becomes void.
View 5 Replies
View Related
Nov 28, 2010
I just bought an... Acer Aspire 4 gig on board 750 gig hard drive I5 processor Question is, if I install dual boot with Windows 7 and Ubuntu, will that VOID my warranty?
View 4 Replies
View Related
Jan 25, 2011
I would like with bash to output the content of my very last email that has been received (I use gmail), especially using fetchmail or mutt.
View 1 Replies
View Related
Jul 20, 2010
I read that ZONE_HIGHMEM (high memory) in linux starts from 896MB. Why it is starting from 896? what is the reason behind that?
View 1 Replies
View Related
Mar 24, 2011
I have a multiple txt file in one folder. I would like to remove everything from starting until find string keyword in one folder. Here is the sample of my text:
Code:
5a651a62sf1a54f2a1sf6a4f50a5f4a2f1a2d1sfs11231211f61d021sd1fs1Reassembles21f2sdf122dfs21fs212sdfdsf1s65f1s62f1
So i want to remove everything from starting until reassemble. Here is the sample output:
Code:
s21f2sdf122dfs21fs212sdfdsf1s65f1s62f1
I have multiple file in one folder. So how to use any script to read in one directory folder and do a same task. I prefer using awk, sed or perl.
View 5 Replies
View Related
Mar 28, 2010
I've been recently interested in shell scripts.. and my friend wants me to create a script that allows you to ping.Ive been trying to find info about how i could set this up but found nothing..also all i really need to create a shell script is the note pad and set it as a .bat file?? or do i need a program to make a shell?
View 8 Replies
View Related
May 15, 2011
I tried, of course:
Code:
awk '/^./ {print}' FILE.TXT
That does not work, I just get an empty output, even if FILE.TXT contains lines which fit the desired regexp I've searched but did not found my way. I'd like to do it with awk, as I want my program to rely only on awk, nothing else such as sed, grep, etc.
View 12 Replies
View Related
Nov 10, 2010
I created a small C++ program which starts a server in a separate thread and waits the user to press q using the standard input/output. Something like:
Code:
printf(...);
server->Start();
[code]....
View 8 Replies
View Related
Dec 14, 2014
I'm trying to start Chrome in kiosk mode from a systemd service on boot. The 'webserver app' named 'xx' in the samples launches but chromium never comes up.
xx.service :
Code: Select all[Unit]
Description=xx Service
After=syslog.target
[Service]
Environment="DISPLAY=:0.0"
Type=forking
WorkingDirectory=/usr/bin/xx/
ExecStart=/usr/bin/xx/xx
ExecStartPost=/usr/local/xx/chromium.sh
Restart=on-abort
[Install]
WantedBy=multi-user.target
chromium.sh
Code: Select allchromium-browser --kiosk http://xx-01.local:8081 &
View 1 Replies
View Related
Jun 8, 2011
How can i use different starting and ending delimiters in awk to search for strings or numbers like:
:string"another_string
'number+another_number
now i want string and number as output from above lines. But if i use delimiter as : or ' it will print the entire line coz second delimiter is not same as first one.
View 4 Replies
View Related
Jun 23, 2011
I am loading the file in Fortran. File looks something like this (shown below) I am interested in Velocity values and not Pressure values. Is there a way to code in Fortran which finds the staring LINE of Velocity values and ending LINE of values or I have to manually find the lines? IN this case it should return Starting line : 9 Ending line: 11
PHP Code:
[code]....
View 2 Replies
View Related
Jan 17, 2009
I have an old-address-list file which is having around 1500 entries. I need to convert this addresses in to a specific format.
The old-address-list file>
# cat old-address-list-file
dn: CN=Muhammad Hadhi K.M,OU=IT Dept,OU=Example Company H.O,DC=example,DC=com
cn: Muhammad Hadhi K.M
[code]....
View 6 Replies
View Related
Oct 5, 2010
I am facing a problem with my AT91SAM9260 customized board. Board is almost same as the evaluation kit.
I could download the binaries ( Bootstrap-v1.16, u-boot-1.3.4, linux kernel 2.6.20) successfully to the DATAFLASH/NANDFlash in my board by using atmel SAM-BA tool with usb/serialport/jlink.
Here I describe the problem.
When I power up the board, boot strap is not jumping to U-boot location, in the normal boot sequence and board stuck with bootstrap.
But when I disconnect/connect the JTAG USB cable ( provided with SAM-BA ICE) , it's jumping to u-boot location and booting the board properly. I'm getting the same error in NAND FLASH also.
I have tried one more test case.I copied bootstrap binary at the flash location, [location which is specified for u-boot binary] instead of U-boot.bin (location: 0x8400 in dataflash), I got continous bootstrap debug messages in my console. [ So can I conclude SDRAM doesn't have any problem? ]
Bootstrap code or U-boot code ?
View 4 Replies
View Related
Jul 18, 2011
I installed OS11.4 on my old laptop, Compaq Armada E500., 512MB RAM, ATI Rage Mobility. During installation I chose "minimal server" and added some development packages, lxde and a little more. I chose to start in runlevel 3 which is full networking without X. Still, when computer is booted it tries to start Xorg which doesn't work because of some problem w driver. The start-up seems to stop there, it never loads completely - seems most things in runlevel 3 are not started (see below) I can manually login on laptop and fix it - but never permanently, same thing again after reboot.
I have checked /etc/inittab & yast - both states default runlevel is 3. I have checked services to be started both directly, browsing directory /etc/rc.d/rc3.d/, and with YaST, it is very clear X should not load during boot. But, as said, it does.. I don't really care about the driver problem right now, I can fix that later when I have more time. So how do I stop X from getting started automatically?
More info, if needed: The installation also stopped with message on tty1 "Starting YaST2" and tty8 showing errors with graphics driver (mach64). The system seemed to be installed though, so I simply rebooted (issuing "reboot" from tty2).
[Code]....
I'm not completely sure where it stops, network is configured but keyboard is wrong and mysql & everything after is not started, so somewhere between S02network and S06kbd. I'm going to use it as a server for testing purposes so no X is actually needed - however I do want to have X & lxde installed just in case, my Internet connection at home is terribly slow so I need most things I might need in the future installed today.
View 1 Replies
View Related