Daily Archives

Articles indexed Thursday June 3 2010

Page 4/111 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Having Issues with a utility app...

    - by Alex
    How do I accept data on the backside of a utility app, and then how do I let users modify that data? I've tried all sorts of tutorials, but to no avail. If you need further information let me know. Thanks in advanced.

    Read the article

  • Flex 4 Spark VideoDisplay in Popup causes memory leak

    - by Ben
    Hi, I'm currently building an air app with FB 4. I have a custom control that contains a VideoDisplay control, and which loaded using the PopupManager. Using the profiler, i've noticed that every time the my popup is loaded the memory for it gets allocated, but when it's closed the memory is never recovered. There's nothing else holding a reference to the popup. And if I don't set the source of the VideoDisplay object, then there is no leak - but as soon as the source is set I get a leak. I can't see any method to force close the stream or anything on the spark VideoDisplay control. Any idea or suggestions? EDIT: I have tried setting the source to null before closing the popup but that doesn't change anything. Also, I'm not holding any event listener to the video

    Read the article

  • Hiding Text in ie7

    - by user356849
    So I have this text generated by a javascript plugin. <a class="className">Text</a> a.className { background: url(images/a-image.png) no-repeat; } But the "Text" shows on top of the image... Now... with any respectable web browser, I can use color: rgba(0,0,0,0); to solve the problem, but IE7 doesn't obey standards of any sort. Any ideas?

    Read the article

  • Network communication for a turn based board game

    - by randooom
    Hi all, my first question here, so please don't be to harsh if something went wrong :) I'm currently a CS student (from Germany, if this info is of any use ;) ) and we got a, free selectable, programming assignment, which we have to write in a C++/CLI Windows Forms Application. My team, two others and me, decided to go for a network-compatible port of the board game Risk. We divided the work in 3 Parts, namely UI, game logic and network. Now we're on the part where we have to get everything working together and the big question mark is, how to get the clients synchronized with each other? Our approach so far is, that each client has all information necessary to calculate and/or execute all possible actions. Actually the clients have all information available at all, aside from the game-initializing phase (add players, select map, etc.), which needs one "super-client" with some extra stuff to control things. This is the standard scenario of our approach: player performs action, the action is valid and got executed on the players client action is sent over the network action is executed on the other clients The design (i.e. no or code so far) we came up with so far, is something like the following pseudo sequence diagram. Gui, Controller and Network implement all possible actions (i.e. all actions which change data) as methods from an interface. So each part can implement the method in a way to get their job done. Example with Action(): On the player side's Client: Player-->Gui.Action() Gui-->Controller.Action() Controller-->Logic.Action (Logic.Action() == NoError)? Controller-->Network.Action() Network-->Parser.ParseAction() Network.Send(msg) On all other clients: Network.Recv(msg) Network-->Parser.Deparse(msg) Parser-->Logic.Action() Logic-->Gui.Action() The questions: Is this a viable approach to our task? Any better/easier way to this? Recommendations, critique? Our knowledge (so you can better target your answer): We are on the beginner side, in regards to programming on a somewhat larger projects with a small team. All of us have some general programming experience and basic understanding of the .Net Libraries and Windows Forms. If you need any further information, please feel free to ask.

    Read the article

  • Fetch request error: no entity? Probably easy, but help!

    - by cksubs
    Hi, I'm going through the Stanford iPhone course. I'm on the second Paparazzi assignment. I'm getting this error: * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'executeFetchRequest:error: A fetch request must have an entity.' I've copied a lot of the code from this walkthrough site. Running his source code works perfectly, and at this point my code is pretty much exactly the same as his. But it throws that error. See below for the relavent bits: // Create FetchRequest NSFetchRequest *request = [[NSFetchRequest alloc] init]; NSEntityDescription *entity = [NSEntityDescription entityForName:@"Person" inManagedObjectContext:context]; [request setEntity:entity]; // Set the sort descriptor NSSortDescriptor *sortDescriptor = [[NSSortDescriptor alloc] initWithKey:@"personName" ascending:NO]; NSArray *sortDescriptors = [[NSArray alloc] initWithObjects:sortDescriptor, nil]; [request setSortDescriptors:sortDescriptors]; [sortDescriptors release]; [sortDescriptor release]; // set up NSFetchedResultsController to hold the fetch NSFetchedResultsController *frc = [[NSFetchedResultsController alloc] initWithFetchRequest:request managedObjectContext:context sectionNameKeyPath:nil cacheName:@"personCache"]; // execute the fetch NSError *error; NSLog(@"Prints Here"); [frc performFetch:&error]; NSLog(@"Doesn't Print Here"); I'm clearly setting the entity with [request setEntity:entity]. So the error has me stumped. Is there something I'm missing? Maybe in another file? I don't know. I'm still so confused with Objective-C.... Thanks.

    Read the article

  • How can the javascript plugin architecture in raphael/jquery be done?

    - by TimDog
    I'm looking for a barebones javascript example that demonstrates how the javascript plugin architecture works with large javascript libraries (such as raphael or jquery). In either scenario, you build plugins by ensuring your custom plugin follows this pattern: jQuery.fn.pluginName -- so assume I have a library: myLibrary = (function() { //my fancy javascript code return function() { //my return object }; }); How would fn be incorporated into the above myLibrary object to ensure that he resulting plugin is callable? I instantiate myLibrary like so: var lib = new myLibrary(); And now I have included a reference to my plugin in my page: myLibrary.fn.simplePlugin = function() { //more fancy code } So finally, I can just call: lib.simplePlugin(); Basically, what magic is actually occuring when the .fn is used during the creation of the plugin?

    Read the article

  • Microcontroller to Microcontroller SPI communication

    - by onaclov2000
    Hello again, I was doing some reading and have even gotten a "master" SPI working on my microcontroller. Here is my question, basically if the master wants to initialize a write to the slave we write to the SSPBUF, how do we control what the slave responds with? The datasheet doesn't seem really clear to me the order of events in that case. I.E. Master puts a char into the SSPBUF, this initiates the SPI module to send data to the slave, during the shift, the slave returns a byte. In the slave side, is there something that tells you you have incoming data, and you can write to your SSPBUF first, THEN accept the data? OR Do you have to write to the SSPBUF the first "return value" you want sent back before the master can have an opportunity to initiate a transfer?

    Read the article

  • How do I use django settings in my logging.ini file?

    - by slypete
    I have a BASE_DIR setting in my settings.py file: BASE_DIR = os.path.dirname(os.path.abspath(__file__)) I need to use this variable in my logging.ini file to setup my file handler paths. The initialization of logging happens in the same file, the settings.py file, below my BASE_DIR variable: LOG_INIT_DONE=False if not LOG_INIT_DONE: logging.config.fileConfig(LOGGING_INI) LOG_INIT_DONE=True Thanks, Pete

    Read the article

  • jQuery .ajax() call to page method works in FF only when async is false

    - by Steve
    I'm calling a page method using .ajax() and it works in IE8 whatever the value of async is. However, in FF3.6, it only works with async set to false. When async is set to true, in Firebug, I just see status aborted. The page validates. I can work with async set to false, but any clues as to why FF can't work with async set to true? $("[id$='_www']").click(function() { var hhh = false; $.ajax({ async: false, cache: false, type: "POST", url: "/abc/def.aspx/jkl", contentType: "application/json; charset=utf-8", dataType: "json", data: "{ 'eee': '" + window.location.href.match(/\d{1,3}$/) + "', 'ttt': '" + $("[id$='_zzz']").val() + "' }", success: function(msg) { $("#ggg").html(msg.d); }, error: function(xhr, err) { hhh = true; } }); return hhh; });

    Read the article

  • IPv6 parsing in C

    - by The Stig
    I wanted to know how i can parse an IPv6 address in 'C' and convert it to a 128 bit value? So a hex address like 1:22:333:aaaa:b:c:d:e:f needs to be converted to its 128 bit equivalent binary. The problem is the IP address could be of the type ::2 and its variant since they are valid IPv6 address. The input is from the keyboard and hence is in ASCII format. Any suggestions or pointers will be appreciated. Thanks!!!

    Read the article

  • Is there a good way to QuickCheck Happstack.State methods?

    - by Paul Kuliniewicz
    I have a set of Happstack.State MACID methods that I want to test using QuickCheck, but I'm having trouble figuring out the most elegant way to accomplish that. The problems I'm running into are: The only way to evaluate an Ev monad computation is in the IO monad via query or update. There's no way to create a purely in-memory MACID store; this is by design. Therefore, running things in the IO monad means there are temporary files to clean up after each test. There's no way to initialize a new MACID store except with the initialValue for the state; it can't be generated via Arbitrary unless I expose an access method that replaces the state wholesale. Working around all of the above means writing methods that only use features of MonadReader or MonadState (and running the test inside Reader or State instead of Ev. This means forgoing the use of getRandom or getEventClockTime and the like inside the method definitions. The only options I can see are: Run the methods in a throw-away on-disk MACID store, cleaning up after each test and settling for starting from initialValue each time. Write the methods to have most of the code run in a MonadReader or MonadState (which is more easily testable), and rely on a small amount of non-QuickCheck-able glue around it that calls getRandom or getEventClockTime as necessary. Is there a better solution that I'm overlooking?

    Read the article

  • Creating a NAS Box with an Existing System

    <B>Linux Magazine:</B> "Standalone Network Attached Storage (NAS) servers provide file level storage to heterogeneous clients, enabling shared storage. This article presents the basics of NAS units (NFS servers) and how you can create one from an existing system"

    Read the article

  • How do I permanently delete e-mail messages in the sendmail queue and keep them from coming back?

    - by Steven Oxley
    I have a pretty annoying problem here. I have been testing an application and have created some test e-mails to bogus e-mail addresses (not to mention that my server isn't really set up to send e-mail anyway). Of course, sendmail is not able to send these messages and they have been getting stuck in the sendmail queue. I want to manually delete the messages that have been building up in the queue instead of waiting the 5 days that sendmail usually takes to stop retrying. I am using Ubuntu 10.04 and /var/spool/mqueue/ is the directory in which every how-to I have read says the e-mails that are queued up are kept. When I delete the files in this directory, sendmail stops trying to process the e-mails until what appears to be a cron script runs and re-populates this directory with the messages I don't want sent. Here are some lines from my syslog: Jun 2 17:35:19 sajo-laptop sm-mta[9367]: o530SlbK009365: to=, ctladdr= (33/33), delay=00:06:27, xdelay=00:06:22, mailer=esmtp, pri=120418, relay=e.mx.mail.yahoo.com. [67.195.168.230], dsn=4.0.0, stat=Deferred: Connection timed out with e.mx.mail.yahoo.com. Jun 2 17:35:48 sajo-laptop sm-mta[9149]: o4VHn3cw003597: to=, ctladdr= (33/33), delay=2+06:46:45, xdelay=00:34:12, mailer=esmtp, pri=3540649, relay=mx2.hotmail.com. [65.54.188.94], dsn=4.0.0, stat=Deferred: Connection timed out with mx2.hotmail.com. Jun 2 17:39:02 sajo-laptop CRON[9510]: (root) CMD ( [ -x /usr/lib/php5/maxlifetime ] && [ -d /var/lib/php5 ] && find /var/lib/php5/ -type f -cmin +$(/usr/lib/php5/maxlifetime) -print0 | xargs -n 200 -r -0 rm) Jun 2 17:39:43 sajo-laptop sm-mta[9372]: o52LHK4s007585: to=, ctladdr= (33/33), delay=03:22:18, xdelay=00:06:28, mailer=esmtp, pri=1470404, relay=c.mx.mail.yahoo.com. [206.190.54.127], dsn=4.0.0, stat=Deferred: Connection timed out with c.mx.mail.yahoo.com. Jun 2 17:39:50 sajo-laptop sm-mta[9149]: o51I8ieV004377: to=, ctladdr= (33/33), delay=1+06:31:06, xdelay=00:03:57, mailer=esmtp, pri=6601668, relay=alt4.gmail-smtp-in.l.google.com. [74.125.79.114], dsn=4.0.0, stat=Deferred: Connection timed out with alt4.gmail-smtp-in.l.google.com. Jun 2 17:40:01 sajo-laptop CRON[9523]: (smmsp) CMD (test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-msp) Does anyone know how I can get rid of these messages permanently? As a side note, I'd also like to know if there is a way to set up sendmail to "fake" sending e-mail. Is there?

    Read the article

  • Regular expression in Ruby

    - by Sainath Mallidi
    Hi, Could anybody help me make a proper regular expression from a bunch of text in Ruby. I tried a lot but I don't know how to handle variable length titles. The string will be of format <sometext>title:"<actual_title>"<sometext>. I want to extract actual_title from this string. I tried /title:"."/ but it doesnt find any matches as it expects a closing quotation after one variable from opening quotation. I couldn't figure how to make it check for variable length of string. Any help is appreciated. Thanks.

    Read the article

  • Java webapp: where/how to automatically set each picture's width/height

    - by NoozNooz42
    For several reasons, a lot of "webmaster guides" (like Google and Yahoo!'s webmaster guides/guidelines) repeats several times that it is better to always put the width and height attribute of the img tag. One of the most obvious reason is that the elements in the page won't seem to be "jumping around" to a new location after every picture is loaded (always setting the correct width/height sure gets rid of this behavior). And there are other reasons to follow these guidelines / best practices. So: if we consider that these are indeed good practices if there are a lot of pictures and they are changing often if pictures aren't changing between two .war re-deploy (that is: there's no user-contributed picture) if we don't want to manually edit all these width/height attributes How do we automatically/programmatically serve HTML pages where every img tag have their width/height attribute correctly set as the best practice recommend?

    Read the article

  • wpf treeview does not show child objects

    - by gangt
    I have an object with child object(s) and I load it using linq. And I assign it to a treeView's itemssource. treeView.DisplayMemberPath = "Name"; treeView.ItemsSource = tasks; It shows only the parent nodes (task.name), I couldn't figure out how to add children (TaskItems.name). All the examples show HierarchicalData in xaml. I need to do it in code-behind, just like the above code. Is it possible? public class Task { public int Id; public string Name; public bool IsActive; public List<TaskItem> TaskItems = new List<TaskItem>(); } public class TaskItem { public int TaskId; public string Name; public string Value; } -------------- var tasks1 = from t in xd.Descendants("taskheader") select new Task { Id = (int)t.Element("id"), Name = t.Element("name").Value, IsActive = t.Element("isactive").Value == "1", TaskItems = t.Elements("taskdetail").Select(e => new TaskItem { TaskId = (int)e.Element("taskid"), Name = (string)e.Element("name"), Value = (string)e.Element("value"), }).ToList() }; -------------- List<Task> tasks = new List<Task>(); tasks = tasks1;

    Read the article

  • Resizable Button with background in flash CS4

    - by Bhavesh.Bagadiya
    Hi, I want to create a button which resize dynamically with content. to achieve this, I created a MovieClip in library and added four layers into it namely - text, bg, shadow and border. Problem I'm having is, if I make textfield autosize, only textfield resizes and others stuff remain as it is. if I calculate width required using xxxLineMetrics function and apply it to Button, background resizes properly but textfield also stretches with them and looks ugly. I want backgrounds(sibling of textfield) resize properly with textfield so button looks nice with resized background and normal autosized textfield. I hope u guys got what I want...any help appreciated... Thanks,

    Read the article

  • The future of SSRS

    - by graham.reeds
    Does anyone know of where future features of SSRS are listed? I found a page that describes the features that are released with SS2K8 R2 but they don't solve the main problem I have porting our Excel reports to SSRS which is vertical merging (plus rotated text to go in those cells) and horizontal tables. I would like to be able to tell my angry users if/when they will be available...

    Read the article

  • Tomcat and proxy request

    - by Raghuram
    I configure a default tomcat installation (running on "localhost" at port "8080") as a proxy server in my browser and try to connect to http://www.google.com. I would expect either an error message saying tomcat is not configured as a proxy server or I should get the contents of google website. Instead I get the index.html page of my tomcat installation. What is going wrong?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >