Search Results

Search found 46075 results on 1843 pages for 'system cats lol'.

Page 145/1843 | < Previous Page | 141 142 143 144 145 146 147 148 149 150 151 152  | Next Page >

  • C# System.Diagnostics.Process redirecting Standard Out for large amounts of data

    - by Matt
    I running an exe from a .NET app and trying to redirect standard out to a streamreader. The problem is that when I do myprocess.exe out.txt out.txt is close to 14mb. When I do the command line version it is very fast but when I run the process from my csharp app it is excruciatingly slow because I believe the default streamreader flushes every 4096 bytes. Is there a way to change the default stream reader for the Process object?

    Read the article

  • Registry Problem

    - by Dominik
    I made a launcher for my game server. (World of Warcraft) I want to get the installpath of the game, browsed by the user. I'm using this code to browse, and get the installpath, then set some other strings from the installpath string, then just strore in my registry key. using System; using System.Drawing; using System.Reflection; using System.Collections; using System.ComponentModel; using System.Windows.Forms; using System.Data; using Microsoft.Win32; using System.IO; using System.Net.NetworkInformation; using System.Diagnostics; using System.Runtime; using System.Runtime.InteropServices; using System.Security; using System.Security.Cryptography; using System.Text; using System.Net; using System.Linq; using System.Net.Sockets; using System.Collections.Generic; using System.Threading; namespace WindowsFormsApplication1 { public partial class Form1 : Form { public Form1() { InitializeComponent(); } string InstallPath, WoWExe, PatchPath; private void Form1_Load(object sender, EventArgs e) { RegistryKey LocalMachineKey_Existence; MessageBox.Show("Browse your install location.", "Select Wow.exe"); OpenFileDialog BrowseInstallPath = new OpenFileDialog(); BrowseInstallPath.Filter = "wow.exe|*.exe"; if (BrowseInstallPath.ShowDialog() == DialogResult.OK) { InstallPath = System.IO.Path.GetDirectoryName(BrowseInstallPath.FileName); WoWExe = InstallPath + "\\wow.exe"; PatchPath = InstallPath + "\\Data\\"; LocalMachineKey_Existence = Registry.LocalMachine.CreateSubKey(@"SOFTWARE\ExistenceWoW"); LocalMachineKey_Existence.SetValue("InstallPathLocation", InstallPath); LocalMachineKey_Existence.SetValue("PatchPathLocation", PatchPath); LocalMachineKey_Existence.SetValue("WoWExeLocation", WoWExe); } } } } The problem is: On some computer, it doesnt stores like it should be. For example, your wow.exe is in C:\ASD\wow.exe, your select it with the browse windows, then the program should store it in the Existence registry key as C:\ASD\Data\ but it stores like this: C:\ASDData , so it forgots a backslash :S Look at this picture: http://img21.imageshack.us/img21/2829/regedita.jpg My program works cool on my PC, and on my friends pc, but on some pc this "bug" comes out :S I have windows 7, with .NEt 3.5 Please help me.

    Read the article

  • mysql_connect() acces denied for system@localhost(using password NO)

    - by user309381
    class MySQLDatabase { public $connection; function _construct() { $this-open_connection(); } public function open_connection() { $this-connection = mysql_connect(DB_SERVER,DB_USER,DB_PASS); if(!$this-connection) { die("Database Connection Failed" . mysql_error()); } else { $db_select = mysql_select_db(DB_NAME,$this-connection); if(!$db_select) { die("Database Selection Failed" . mysql_error()); } } } function mysql_prep($value) { if (get_magic_quotes_gpc()) { $value = stripslashes($value); } // Quote if not a number if (!is_numeric($value)) { $value = "'" . mysql_real_escape_string($value) . "'"; } return $value; } public function close_connection() { if(isset($this->connection)) { mysql_close($this->connection); unset($this->connection); } } public function query(/*$sql*/) { $sql = "SELECT*FROM users where id = 1"; $result = mysql_query($sql); $this->confirm_query($result); //return $result; while( $found_user = mysql_fetch_assoc($result)) { echo $found_user ['username']; } } private function confirm_query($result) { if(!$result) { die("The Query has problem" . mysql_error()); } } } $database = new MySQLDatabase(); $database-open_connection(); $database-query(); $database-close_connection(); ?

    Read the article

  • Fixing permissions after FTPing ASP.NET code to a Linux system

    - by dnord
    First off, I'm running Mono to run ASP.NET on Linux, but that's not the question. It appears that, every time I clear out my application directory and upload, I have to go back in and fix the permissions. What I'm doing is chmod -R -c 755 /var/www/* ...and there are two questions. What's the deal with having to do this every time I FTP? Feels flaky. Is there a better permissions set than 755? Do I want different permissions for the /bin directory? Or can I fix this all with one fell swoop of chown?

    Read the article

  • Favoriting system on Appengine

    - by Mateusz Cieslak
    Hi, I have the following model structure class Authors(db.Model) : nickname = db.StringProperty(required=True) fullname = db.StringProperty(required=True) class Articles(db.Model) : title = db.StringProperty(required=True) body = db.StringProperty(required=True) author = db.ReferenceProperty(Authors, required=True) class Favorites(db.Model) : who = db.ReferenceProperty(Authors, required=True) what = db.ReferenceProperty(Articles, required=True) I'd like to display 10 last articles according to this pattern: article.title, article.body, article.author(nickname), info if this article has been already favorited by the signed in user. I have added a function which I use to get the authors of these articles using only one query (it is described here) But I don't know what to do with the favorites (I'd like to know which of the displayed articles have been favorited by me using less than 10 queries (I want to display 10 articles)). Is it possible?

    Read the article

  • Using system Sound to play sounds

    - by Shoaibi
    Here is the code: -(void)stop { NSLog(@"Disposing Sounds"); AudioServicesDisposeSystemSoundID (soundID); //AudioServicesRemoveSystemSoundCompletion (soundID); } static void completionCallback (SystemSoundID mySSID, void* myself) { NSLog(@"completion Callback"); } - (void) playall: (id) sender { [self stop]; AudioServicesAddSystemSoundCompletion (soundID,NULL,NULL, completionCallback, (void*) self); OSStatus err = kAudioServicesNoError; NSString *aiffPath = [[NSBundle mainBundle] pathForResource:@"slide1" ofType:@"m4a"]; NSURL *aiffURL = [NSURL fileURLWithPath:aiffPath]; err = AudioServicesCreateSystemSoundID((CFURLRef) aiffURL, &soundID); AudioServicesPlaySystemSound (soundID); NSLog(@"Done Playing"); } Output: Disposing Sounds Done Playing In actual no sound gets play at all and completion call back isn't called as well. Any idea what could be wrong here? I want to stop any previous sound before playing current.

    Read the article

  • iPhone Mobile Safari File System Access

    - by Jon Smallberries
    Is it possible to write to a file in a native iPhone application and have a Safari browser read from that file after having the browser opened from the native app? Alternatively (and this would be great!), would it be possible to launch a mobile Safari webapp from a native iPhone app, and have that application access the OS 3.0 External Accessory Framework? My assumption is no... Basically, I have a functioning iPhone app that wraps a simple mobile Safari webapp, but I'd like to utilize the external accessory framework once I have launched the Safari webapp from the iPhone app...

    Read the article

  • Release management with a distributed version control system

    - by See Sharp Cheddar
    We're considering a switch from SVN to a distributed VCS at my workplace. I'm familiar with all the reasons for wanting to using a DVCS for day-to-day development: local version control, easier branching and merging, etc., but I haven't seen that much that's compelling in terms of managing software releases. Here's our release process: Discover what changes are available for merging. Run a query to find the defects/tickets associated with these changes. Filter out changes associated with "open" tickets. In our environment, tickets must be in a closed state in order to merged with a release branch. Filter out changes we don't want in the release branch. We are very conservative when it comes to merging changes. If a change isn't absolutely necessary, it doesn't get merged. Merge available changes, preferably in chronological order. We group changes together if they're associated with the same ticket. Block unwanted changes from the release branch (svnmerge block) so we don't have to deal with them again. Sometimes we can be juggling 3-5 different milestones at a time. Some milestones have very different constraints, and the block list can get quite long. I've been messing around with git, mercurial and plastic, and as far as I can tell none of them address this model very well. It seems like they would work very well when you have only one product you're releasing, but I can't imagine using them for juggling multiple, very different products from the same codebase. For example, cherry-picking seems to be an afterthought in mercurial. (You have to use the 'transplant' command). After you cherry-pick a change into a branch it still shows up as an available integration. Cherry-picking breaks the mercurial way of working. DVCS seems to be better suited for feature branches. There's no need for cherry-picking if you merge directly from a feature branch to trunk and the release branch. But who wants to do all that merging all the time? And how do you query for what's available to merge? And how do you make sure all the changes in a feature branch belong together? It sounds like total chaos. I'm torn because the coder in me wants DVCS for day-to-day work. I really want it. But I fear the day when I have to put the release manager hat and sort out what needs to be merged and what doesn't. I want to write code, I don't want to be a merge monkey.

    Read the article

  • How to null a translation in gettext system?

    - by Evgeny
    Suppose a simple phrase "In" in English needs to be interpreted as "" - empty string in Russian. Is is possible to specify that in the .po file? What normally happens if you set msgstr "" - you'll get the untranslated key, but I want to get nothing in that specific case. Here is a use case: I have underneath a giant search bar a set of buttons to select questions (for a Q&A site) from particular scopes - like so: (in English) In: [all] [unanswered] [my own] (in Russian I want) [???] [??? ???????] [???] It just sounds more natural. Yes I can leave out In for english, but I don't want to and I do not want to put button (things in [] are buttons) html into the 'po' file. Thanks!

    Read the article

  • Please Find the error :

    - by jagdeep
    using System; using System.Collections; using System.Configuration; using System.Data; using System.Linq; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Xml.Linq; public partial class Expt : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } protected void Bttnadd_Click(object sender, EventArgs e) { FileUpload1.SaveAs(MapPath("~/img//"+DateTime.Now.ToString()+FileUpload1.FileName)); } } Exception Details: System.Web.HttpException: ~/img//1/1/2011 1:47:52 PMWinter.jpg is not a valid virtual path.

    Read the article

  • Ideas for designing an automated content tagging system needed

    - by Benjamin Smith
    I am currently designing a website that amongst other is required to display and organise small amounts of text content (mainly quotes, article stubs, etc.). I currently have a database with 250,000+ items and need to come up with a method of tagging each item with relevant tags which will eventually allow for easy searching/browsing of the content for users. A very simplistic idea I have (and one that I believe is employed by some sites that I have been looking to for inspiration (http://www.brainyquote.com/quotes/topics.html)), is to simply search the database for certain words or phrases and use these words as tags for the content. This can easily be extended so that if for example a user wanted to show all items with a theme of love then I would just return a list of items with words and phrases relating to this theme. This would not be hard to implement but does not provide very good results. For example if I were to search for the month 'May' in the database with the aim of then classifying the items returned as realting to the topic of Spring then I would get back all occurrences of the word May, regardless of the semantic meaning. Another shortcoming of this method is that I believe it would be quite hard to automate the process to any large scale. What I really require is a library that can take an item, break it down and analyse the semantic meaning and also return a list of tags that would correctly classify the item. I know this is a lot to ask and I have a feeling I will end up reverting to the aforementioned method but I just thought I should ask if anyone knew of any pre-existing solution. I think that as the items in the database are short then it is probably quite a hard task to analyse any meaning from them however I may be mistaken. Another path to possibly go down would be to use something like amazon turk to outsource the task which may produce good results but would be expensive. Eventually I would like users to be able to (and want to!) tag content and to vote for the most relevant tags, possibly using a gameification mechanic as motivation however this is some way down the line. A temporary fix may be the best thing if this were the route I decided to go down as I could use the rough results I got as the starting point for a more in depth solution. If you've read this far, thanks for sticking with me, I know I'm spitballing but any input would be really helpful. Thanks.

    Read the article

  • Questions about using git as a backend storage system

    - by XO
    New to git here... I want to commit my personal file share to a git repo (text, docs, images etc). As I make modifications to various files over time, telling git about them along the way, how do go about things so I can: Get out of the business of traditional fulls/incrementals. Be able to do a point-in-time file or full clone restore. Basically, I want something granular, such that, if I make an edit to a file 5 times on a particular day. I will have 5 versions of that file that I can refer back to- forever. Or even just derive the a full copy of everything the way it looked on that particular day. I am currently using rsync for remote incremental syncs (no file versioning).

    Read the article

  • DNS resolve without depending on router for asterisk system

    - by john
    Hello, Basically I have a Debian box running asterisk assigned an IP via DHCP with host-name XXX. My windows browser can resolve the host-name but if I use host-name in X-Lite or my SPA922 phone it fails to resolve. Is there any way of getting this to work without depending on the router or assigning a static IP (request is to make it portable). I was thinking zero-conf but am unsure (box has limited HDD too). Any help is most appreciated.

    Read the article

  • Online Advetisement/Banner Management System

    - by Sumesh Joshi
    I am developing site for online advertisements where sellers and buyers can come and sell/buy advertisements. Just need to develop detailed statistics like click counts, from which page clicks are coming (one advertisement can be placed on many pages), from which position (top, right, left ...) click are coming (one advertisement can be placed in different position on single page) etc. I seen that most of the advertisement on popular websites has following format: http://ads.stackoverflow.com/a.aspx?Task=Click&ZoneID=3&CampaignID=838&AdvertiserID=50&BannerID=1335&SiteID=1&RandomNumber=1463177307&Keywords=c%23%2c.net%2ccollections%2cdictionary%2chashtable It has many parameters like ZoneID, CampaignID, AdvertiserID, BannerID, SiteID, RandomNumber, adid, adcrid, obid, obtid and way. I can use one advertisement (adid) in multiple pages. But can't figure out the way to distinguish between from which pages clicks are coming. How can I use such parameters to generate statistics which tell me the page from which clicks are coming?

    Read the article

  • Start process from System Account with a specific User Name

    - by pavel.tuzov
    Hi, I'm developing a windows service in C# .net, Account: LocalSystem I want this service to check for all currently logged users if a specific application is running and if not - start this application AS corresponding user name. I provide domain, name, password, but Start() throws Win32Exception exception "Access is denied" process.StartInfo.Domain = domain; process.StartInfo.UserName = name; process.StartInfo.Password = password; process.StartInfo.FileName = fileName; process.StartInfo.UseShellExecute = false; process.Start(); The user whose credentials I provide is in administrator group - the application successfully runs if started manually. Is this accomplished in a different way? Thank you!

    Read the article

  • Ideas Needed for a Base Code System

    - by Tegan Snyder
    I've developed a PHP web application that is currently in need of a strategic restructuring. Currently when we setup new clients we give them the entire code base on a subdomain of our main domain and create a new table for them in the database. This results in each client having the entire codebase, meaning when we make bug changes, fixes we have to go back and apply them independently across all clients and this is a pain. What I'd like to create is a base code server that holds all the core PHP files. base.domain.com Then all of our clients (client.domain.com) will only need a few files: config.php would have the database connection information. index.php - displays the login box if session non-existant, otherwise it loads baseline code via remote includes to base.domain.com. My question is does my logic seem feasible? How do other people handle similar situations by having a base code? Also.... Is it even possbile to remotely include PHP files from base.domain.com and include them in client.domain.com? Thanks, Tegan

    Read the article

  • Trying to make a plugin system in C++/Qt

    - by Pirate for Profit
    I'm making a task-based program that needs to have plugins. Tasks need to have properties which can be easily edited, I think this can be done with Qt's Meta-Object Compiler reflection capabilities (I could be wrong, but I should be able to stick this in a QtPropertyBrowser?) So here's the base: class Task : public QObject { Q_OBJECT public: explicit Task(QObject *parent = 0) : QObject(parent){} virtual void run() = 0; signals: void taskFinished(bool success = true); } Then a plugin might have this task: class PrinterTask : public Task { Q_OBJECT public: explicit PrinterTask(QObject *parent = 0) : Task(parent) {} void run() { Printer::getInstance()->Print(this->getData()); // fictional emit taskFinished(true); } inline const QString &getData() const; inline void setData(QString data); Q_PROPERTY(QString data READ getData WRITE setData) // for reflection } In a nutshell, here's what I want to do: // load plugin // find all the Tasks interface implementations in it // have user able to choose a Task and edit its specific Q_PROPERTY's // run the TASK It's important that one .dll has multiple tasks, because I want them to be associated by their module. For instance, "FileTasks.dll" could have tasks for deleting files, making files, etc. The only problem with Qt's plugin setup is I want to store X amount of Tasks in one .dll module. As far as I can tell, you can only load one interface per plugin (I could be wrong?). If so, the only possible way to do accomplish what I want is to create a FactoryInterface with string based keys which return the objects (as in Qt's Plug-And-Paint example), which is a terrible boilerplate that I would like to avoid. Anyone know a cleaner C++ plugin architecture than Qt's to do what I want? Also, am I safely assuming Qt's reflection capabilities will do what I want (i.e. able to edit an unknown dynamically loaded tasks' properties with the QtPropertyBrowser before dispatching)?

    Read the article

  • What's the best way to run a process remotely with capturing the output ?

    - by Homam
    Hi all, I have a windows service responsible for running processes on a remote machine with capturing the output, I googled for that and read a lot of articles and threads, I found two ways: 1) using WMI for call the remote process like this example: http://www.codeproject.com/KB/cs/EverythingInWmi02.aspx 2) using the PsExec tool by System.Diagnostic.Process class ever way of these has many problems, the WMI doesn't support returning the output and doesn't support "WaitingToExit" It just call the process and return the PId, and the PsExec couldn't capture the output programmatically by System.Diagnostic.Process in a clear way, I found only workarounds like redirect the output to a file then read the redirected file..etc, I need a real solution please

    Read the article

  • Writing a custom auth system (like the default django auth system), use it to generate tables in DB

    - by dotty
    Hay all, I've been reading up on middleware and how to use it with a context object. I want to write a simple middleware class which i can use on my own applications, it will essentially be a cut down version of the django one. The problem i seem to have is that if i have INSTALLED_APPS = ('django.contrib.my_auth') in the settings file, all is well. I've also added MIDDLEWARE_CLASSES = ('django.contrib.my_auth.middleware.MyAuthMiddleware') in it and everything is fine. My question is, how would i make my middleware automatically generate tables from a models.py module, much like how the django auth does when i run manage.py syncdb? thanks

    Read the article

  • Browser application & local file system access

    - by Beyond HTML
    I want to enhance my browser-based web application with functionality that enables management of local files and folders. E.g. folder tree structures should be synchronized between local workstation and server via HTTP(S). I am aware of security-related limitations in browser-based applications. However, there are some techniques that "work around" these issues: Signed Java applets (full trust) .NET Windows Forms browser controls (no joke, that works. Just the configuration is horrible) ActiveX My question is: What do you use/suggest, both technology and implementation practice? Key requirement is that the installation process is as simple as possible. Thanks for your opinions!

    Read the article

< Previous Page | 141 142 143 144 145 146 147 148 149 150 151 152  | Next Page >