Search Results

Search found 3487 results on 140 pages for 'soe naung win'.

Page 57/140 | < Previous Page | 53 54 55 56 57 58 59 60 61 62 63 64  | Next Page >

  • Missing chars in JpGraph

    - by Álvaro G. Vicario
    I have a web site that runs on Windows and uses cp1252 (aka Win-1252) so it can display Spanish characters. The app generates some plots with JpGraph 2.3. These plots use the Tahoma Open Type font family to display text labels. Strings are provided in ANSI (i.e., cp1252) and font files support cp1252 (actually, the *.ttf files were copied from the system's font folder). It's been working fine in several setups from PHP/5.2.6 to PHP/5.3.0. Problems started when I ran the app under PHP/5.3.1: all non-ASCII are replaced by the hollow rectangle that represents missing or unknown chars. JpGraph's documentation is not very precise about how it expects international chars. Apparently, text is handled internally by the imagettftext() function, which expects UTF-8. However, encoding everything as UTF-8 breaks the app in all the systems. Where ANSI used to work fine, I get wrong characters (Ê instead of Ú). Where I got missing chars, now I get a PHP error: Warning: imagettftext(): any2eucjp(): something happen Do you have any clue about what changed in GD2 from PHP/5.3.0 to 5.3.1 that could be affecting the rendering on non-ASCII chars? How am I expected to feed JpGraph with strings in the Win-1252 charset?

    Read the article

  • desktop shortcut icon not showing in web setup project

    - by davsan
    i've created a web setup project and i wanted it to create a desktop shortcut to the web application (ex: http://localhost/xx/yy.aspx). up to this point it was pretty easy: i created a shortcut (doesnt matter where), gave it the url i wanted, added this to the User's Desktop special folder of my web setup project, and it was placed on the desktop after the installation. but then i wanted to display my custom shortcut icon. i set the icon of the shortcut i've created on my file system. then i re-included this to the setup project. however after the installation the shortcut kept showing the default IE icon again. (i tried these on windows 2003 server, on win xp the shortcut showed up iconless) after some trials i found another way: i recreated an iconless shortcut on my file system, opened my web setup project, included this shortcut and my icon to Web Application Folder under File System on Target Machine, then clicked on User's Desktop, right clicked on the right hand side blank area, selected Create New Shortcut and chose the shortcut i've just added. Then under User's Desktop i clicked on the newly created shortcut, opened the Properties window and set its Icon property to my included icon. These steps solved it all both on 2003 server and win xp. Though this wasnt really a question i wanted to share it anyways because it was quite annoying.

    Read the article

  • Linq to SQL Problem System.Data.Linq.IdentityManager.StandardIdentityManager.MultiKeyManager

    - by luckyluke
    I have a really tricky thing going up here. My project has around 100 tables and they are all mapped by LINQ. Everything works fine in a dev and test environment. These enviroments are MS Win 2008 r2 servers with SQL 2008 sp1 databases. IIS and SQL are on a different machines. Now on production enviroment which is MS Win 2003 x64 web farm + geoclustered SQL 2008 IT DOES not work. All I get is the exception System.IndexOutOfRangeException: Index was outside the bounds of the array. at System.Data.Linq.IdentityManager.StandardIdentityManager.MultiKeyManager3.TryCreateKeyFr>om Values(Object[] values, MultiKey& k) at System.Data.Linq.IdentityManager.StandardIdentityManager.IdentityCache2.Find(Object[] keyValues) at System.Data.Linq.ChangeProcessor.GetOtherItem(MetaAssociation assoc, Object instance) at System.Data.Linq.ChangeProcessor.BuildEdgeMaps() at System.Data.Linq.ChangeProcessor.SubmitChanges(ConflictMode failureMode) at System.Data.Linq.DataContext.SubmitChanges(ConflictMode failureMode) at ERS.IIMP.Services.ExposuresSrv.Update(Int32 ExpID, Int32 AssID) Services\ExposuresSrv.cs` My question is What the hell. They have precisely the same DBML, the DB has exactly THE SAME structure (when I get the DB from prod to TEST and mount it eveything works just great), the binaries on the WEB Server are the same. I seriously do not know what to do.... Did anyone found that Linq works on one env and does not on the second?? I mam really lost here. I really hope You can help me:)

    Read the article

  • function (blurClass) NOT WORKING IN IE

    - by Erik
    I can't get this plugin to function properly in IE.... Check out my homepage and look at the huge search field toward the top... www.naturalskin.com Whenever I refresh the screen the "blur" looses its function and I'm stuck with text..... Here is the script that I place in an external js page: http://www.naturalskin.com/src/js/javascript/batches.js jQuery.fn.hint = function (blurClass) { if (!blurClass) { blurClass = 'blur'; } return this.each(function () { // get jQuery version of 'this' var $input = jQuery(this), // capture the rest of the variable to allow for reuse title = $input.attr('title'), $form = jQuery(this.form), $win = jQuery(window); function remove() { if ($input.val() === title && $input.hasClass(blurClass)) { $input.val('').removeClass(blurClass); } } // only apply logic if the element has the attribute if (title) { // on blur, set value to title attr if text is blank $input.blur(function () { if (this.value === '') { $input.val(title).addClass(blurClass); } }).focus(remove).blur(); // now change all inputs to title // clear the pre-defined text when form is submitted $form.submit(remove); $win.unload(remove); // handles Firefox's autocomplete } }); }; Erik

    Read the article

  • How to Write to a User.Config file through ConfigurationManager?

    - by Josh G
    I'm trying to persist user settings to a configuration file using ConfigurationManager. I want to scope these settings to the user only, because application changes can't be saved on Vista/Win 7 without admin privileges. This seems to get me the user's configuration, which appears to be saved here in Win 7 ([Drive]:\Users\[Username]\AppData\Local\[ApplicationName]\[AssemblyName][hash]\[Version\) Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.PerUserRoamingAndLocal); Whenever I try to save any changes at all to this config I get this exception: InnerException: System.InvalidOperationException Message="ConfigurationSection properties cannot be edited when locked." Source="System.Configuration" StackTrace: at System.Configuration.SectionInformation.VerifyIsEditable() at System.Configuration.MgmtConfigurationRecord.GetConfigDefinitionUpdates(Boolean requireUpdates, ConfigurationSaveMode saveMode, Boolean forceSaveAll, ConfigDefinitionUpdates& definitionUpdates, ArrayList& configSourceUpdates) I have tried adding a custom ConfigurationSection to this config. I have tried adding to the AppSettingsSection. Whenever I call config.Save() it throws the exception above. Any ideas? I tried using the ApplicationSettingsBase class through the Project-Settings designer, but it doesn't appear that you can save custom types with this. I want similar functionality with the ability to save custom types. Thanks.

    Read the article

  • Access Denied while using System.Diagnostics.Process

    - by Mike C
    I am trying to use the unmanaged ImageMagick library in my ASP.NET application from the command line using System.Diagnostics.Process. Basically, users will upload an .eps file to the site, and then I will run the command line command to convert it into .jpg. This is the code I'm using to try and run the command: Dim proc As New System.Diagnostics.Process proc.StartInfo.RedirectStandardOutput = True proc.StartInfo.RedirectStandardError = True proc.StartInfo.FileName = "C:\Program Files (x86)\ImageMagick-6.6.1-Q16\convert.exe" proc.StartInfo.UseShellExecute = False proc.StartInfo.Arguments = String.Format("{0} {1}", Server.MapPath("~/logo/test.eps"), _ Server.MapPath("~/certificates/temp/test-1234.jpg")) proc.StartInfo.CreateNoWindow = True proc.Start() I am able to run this code just fine on our development Win 2k3 server, but not on our production Win 2k3 Server. I get the error "System.ComponentModel.Win32Exception: Access is denied". The main between the two servers is that the production is 64-bit and runs Plesk to manage multiple domains. I've tried adding rights asp.net user to the ImageMagick directory. The PS Admin says that in the case of Plesk, it's the same account that I use to access the site in VS using FPE. Does anyone know what I might do in order to allow this process to run on my production server? Thanks, Mike

    Read the article

  • VB.Net Application Settings / ClickOnce

    - by B Z
    VS 2008 / VB.Net / WinForms I have an application setting (Settings.settings) for a project and I am using Click Once deployment. I used the VS Editor to create the setting and I can see the setting in the app.config file <applicationSettings> <MyApp.Win.My.MySettings> <setting name="MySetting" serializeAs="String"> <value>False</value> </setting> </MyApp.ArtTracker.Win.My.MySettings> </applicationSettings> I would like to update this setting after the application is compiled. The setting is for testing purposes only. If I change the xxx.config.deploy and I reinstall the app with click once. The new setting value doesn't change (seems to be cached somewhere). Even if I change in my local pc the setting seems to be cached somewhere. If I go in VS it asks me to Re-Sync the settings. But I need to do this after the application is compiled. Thanks for any help

    Read the article

  • GetEffectiveRightsFromAcl throws invalid acl error

    - by apoorv020
    I am trying to get the effective rights a user has on a file using interop in C#. Following is the code I am using : public static FileSystemRights GetFileEffectiveRights(string FileName, string UserName) { IntPtr pDacl, pZero = IntPtr.Zero; int Mask = 0; uint errorReturn = GetNamedSecurityInfo(FileName, SE_OBJECT_TYPE.SE_FILE_OBJECT, SECURITY_INFORMATION.Dacl , out pZero, out pZero, out pDacl, out pZero, out pZero); if (errorReturn != 0) { throw new Exception("Win error : " + errorReturn); } Program.TRUSTEE pTrustee = new TRUSTEE(); pTrustee.pMultipleTrustee = IntPtr.Zero; pTrustee.MultipleTrusteeOperation = (int)Program.MULTIPLE_TRUSTEE_OPERATION.NO_MULTIPLE_TRUSTEE; pTrustee.ptstrName = UserName; pTrustee.TrusteeForm = (int)Program.TRUSTEE_FORM.TRUSTEE_IS_NAME; pTrustee.TrusteeType = (int)Program.TRUSTEE_TYPE.TRUSTEE_IS_USER; errorReturn = GetEffectiveRightsFromAcl(pDacl, ref pTrustee, ref Mask); if (errorReturn != 0) { throw new Exception("Win error : " + errorReturn); } return (FileSystemRights)Mask; } This code works fine until I start modifying the ACL structure using the classes FileAccessRule and FileInfo, and then I start getting Windows Error 1336 : ERROR_INVALID_ACL. Same is the case if I debug the process call GetFileEffectiveRights once, pause the process,change the ACL through windows API, and resume and call GetFileEffectiveRights again(the 1st call succeeds but the second gives 1336.) What is going wrong?

    Read the article

  • Ultrawingrid - how to display #1/1/1800# as blank ( as if null )

    - by Charles Hankey
    Ultrawingrid 9.2 VS2008 .net 3.5 My wingrid uses a bindingsource. All datetimes which are null in SQL Server are delivered to the bindingsource as #1/1/1800# I would like Ultrawingrid to display this date as blank as it would a null from source. Also, if the date is null in the grid ( i.e. blanked out ) I would like to update the data source to the date #1/1/1800# ( the framework takes care of getting that date back into the backend as a null ) This seems like it should be a trivial matter but I can find no documentation on just where to intervene so the grid will see a particular date as a null and save a null as a particular date. This is the direction I've been headed but I don't think either is the right place and I can't even get the syntax to work in the BeforeRowUpdate as I cannot see how to set a value that is passed to the data binding without setting the value of control itself, which I think has to remain null in order to display as blank Private Sub ugPropMaster_BeforeRowUpdate(ByVal sender As Object, ByVal e As _ Infragistics.Win.UltraWinGrid.CancelableRowEventArgs) Handles _ ugPropMaster.BeforeRowUpdate If e.Row.Cells.Item("Exdate").Value Is Nothing Then e.Row.Cells("Exdate").Value = CDate(#1/1/1800#) End If End Sub Private Sub ugPropMaster_InitializeRow(ByVal sender As Object, ByVal e As _ Infragistics.Win.UltraWinGrid.InitializeRowEventArgs) Handles _ ugPropMaster.InitializeRow If CDate(e.Row.Cells.Item("Exdate").Value) = CDate(#1/1/1800#) Then e.Row.Cells.Item("Exdate").Value = Nothing End If End Sub Guidance much appreciated

    Read the article

  • cant get connexion using MongoTor

    - by Abdelouahab Pp
    i was trying to change my code to make it asynchronous using MongoTor here is my simple code: class BaseHandler(tornado.web.RequestHandler): @property def db(self): if not hasattr(self,"_db"): _db = Database.connect('localhost:27017', 'essog') return _db @property def fs(self): if not hasattr(BaseHandler,"_fs"): _fs = gridfs.GridFS(self.db) return _fs class LoginHandler(BaseHandler): @tornado.web.asynchronous @tornado.gen.engine def post(self): email = self.get_argument("email") password = self.get_argument("pass1") try: search = yield tornado.gen.Task(self.db.users.find, {"prs.mail":email}) .... i got this error: Traceback (most recent call last): File "C:\Python27\lib\site-packages\tornado-2.4.post1-py2.7.egg\tornado\web.py", line 1043, in _stack_context_handle_exception raise_exc_info((type, value, traceback)) File "C:\Python27\lib\site-packages\tornado-2.4.post1-py2.7.egg\tornado\web.py", line 1162, in wrapper return method(self, *args, **kwargs) File "C:\Python27\lib\site-packages\tornado-2.4.post1-py2.7.egg\tornado\gen.py", line 122, in wrapper runner.run() File "C:\Python27\lib\site-packages\tornado-2.4.post1-py2.7.egg\tornado\gen.py", line 365, in run yielded = self.gen.send(next) File "G:\Mon projet\essog\handlers.py", line 92, in post search = yield tornado.gen.Task(self.db.users.find, {"prs.mail":email}) File "G:\Mon projet\essog\handlers.py", line 62, in db _db = Database.connect('localhost:27017', 'essog') File "build\bdist.win-amd64\egg\mongotor\database.py", line 131, in connect database.init(addresses, dbname, read_preference, **kwargs) File "build\bdist.win-amd64\egg\mongotor\database.py", line 62, in init ioloop_is_running = IOLoop.instance().running() AttributeError: 'SelectIOLoop' object has no attribute 'running' ERROR:tornado.access:500 POST /login (::1) 3.00ms and, excuse me for this other question, but how do i make distinct in this case? here is what worked in blocking mode: search = self.db.users.find({"prs.mail":email}).distinct("prs.mail")[0] Update: it seems that this error happenes when there is no Tornado running! it's the same error raised when using only the module in console. test = Database.connect("localhost:27017", "essog") --------------------------------------------------------------------------- AttributeError Traceback (most recent call last) in () ---- 1 test = Database.connect("localhost:27017", "essog") C:\Python27\lib\site-packages\mongotor-0.0.10-py2.7.egg\mongotor\database.pyc in connect(cls, addresses, dbname, read_preference, **kwargs) 131 132 database = Database() -- 133 database.init(addresses, dbname, read_preference, **kwargs) 134 135 return database C:\Python27\lib\site-packages\mongotor-0.0.10-py2.7.egg\mongotor\database.pyc in init(self, addresses, dbname, read_preference, **kwargs) 60 self._nodes.append(node) 61 --- 62 ioloop_is_running = IOLoop.instance().running() 63 self._config_nodes(callback=partial(self._on_config_node, ioloop_is_running)) 64 AttributeError: 'SelectIOLoop' object has no attribute 'running'

    Read the article

  • Get notified when objective-c dom updates are ready initiated from webview

    - by Josh
    I am programmatically updating the DOM on a WebKit webview via DOMElement objects - for complex UI, there is usually a javascript component to any element that I add. This begs the need to be notified when the updates complete -- is there any such event? I know regular divs dont fire an onload or onready event, correct? The other assumption I had, which may be totally wrong, is that DOMElement updates aren't synchronous, so I can't do something like this and be confident it will meet with the label actually in the DOM: DOMElement *displayNameLabel = [document createElement:@"div"]; [displayNameLabel setAttribute:@"class" value:@"user-display-name"]; [displayNameLabel setTextContent:currentAvatar.avatarData.displayName]; [[document getElementById:@"user-card-content"] appendChild:displayNameLabel]; id win = [webView windowScriptObject]; [win evaluateWebScript:@"javascriptInstantiateLabel()"]; Is this true? I am using jquery within the body of the html already, so I don't mind subscribing to a particular classes set of events via "live." I thought I might be able to do something like: $(".some-class-to-be-added-later").live( "ready", function(){ // Instantiate some fantastic javascript here for .some-class }); but have experienced no joy so far. Is there any way on either side (objective-c since I don't programmatically firing javascript post load, or javascript) to be notified when the element is in the DOM? Thanks, Josh

    Read the article

  • Will Apple bundle the Mono Touch runtime with every iPhone?

    - by Zoran Simic
    It strikes me as a good idea for Apple to negotiate with Novell and bundle the Mono Touch runtime (only the runtime of course) into every iPhone and iPod Touch. Perhaps even make it a "one time install" that automatically gets downloaded from the App Store the first time one downloads an app build with Mono Touch, making every subsequent Mono Touch app much lighter to download (without the runtime). Doing so would be similar in a way to adding Bootcamp to OS X: it would make it easier for C# developers to join the party, but that wouldn't mean these developers will all stick to C#... What convinced me to buy a Mac is Bootcamp - I figured I could always install Windows if I didn't like OS X (and I liked the hardware, so no problem there). 6 months later, I'm using OS X full time... Would there be any technical issues in doing so? I see only advantages for all parties, not one disadvantage to anyone (except maybe for the few unfortunate Apple employees who would have to test the crap out of the Mono Touch runtime before bundling it): Novell wins because Mono Touch becomes much more viable (Mono Touch apps become much lighter all of the sudden) Developers win because now there's one more tool in the tool belt Many C# Developers would be very interested by this Apple wins because that would bring even more attention to the platform, more revenue in developer fees, more potential great apps, etc Users win because less space is used by different Apps having copies of the same runtime accumulating on their devices Would there be a major technical obstacle in bundling Mono Touch to iPhone OS? Edit: Changed the title from "Should" to "Will Apple bundle the runtime?", I think the consensus on predicting that means a lot to those considering going with Mono Touch.

    Read the article

  • wxpython: adding panel to wx.Frame disables/conflicts with wx.Frame's OnPaint?!

    - by sdaau
    Hi all, I just encountered this strange situation: I found an example, where wx.Frame's OnPaint is overridden, and a circle is drawn. Funnily, as soon as I add even a single panel to the frame, the circle is not drawn anymore - in fact, OnPaint is not called at all anymore ! Can anyone explain me if this is the expected behavior, and how to correctly handle a wx.Frame's OnPaint, if the wx.Frame has child panels ? Small code example is below.. Thanks in advance for any answers, Cheers! The code: #!/usr/bin/env python # http://www.linuxquestions.org/questions/programming-9/wxwidgets-wxpython-drawing-problems-with-onpaint-event-703946/ import wx class MainWindow(wx.Frame): def __init__(self, parent, title, size=wx.DefaultSize): wx.Frame.__init__(self, parent, wx.ID_ANY, title, wx.DefaultPosition, size) self.circles = list() self.displaceX = 30 self.displaceY = 30 circlePos = (self.displaceX, self.displaceY) self.circles.append(circlePos) ## uncommenting either only first, or both of ## the commands below, causes OnPaint *not* to be called anymore! #~ self.panel = wx.Panel(self, wx.ID_ANY) #~ self.mpanelA = wx.Panel(self.panel, -1, size=(200,50)) self.Bind(wx.EVT_PAINT, self.OnPaint) def OnPaint(self, e): print "OnPaint called" dc = wx.PaintDC(self) dc.SetPen(wx.Pen(wx.BLUE)) dc.SetBrush(wx.Brush(wx.BLUE)) # Go through the list of circles to draw all of them for circle in self.circles: dc.DrawCircle(circle[0], circle[1], 10) def main(): app = wx.App() win = MainWindow(None, "Draw delayed circles", size=(620,460)) win.Show() app.MainLoop() if __name__ == "__main__": main()

    Read the article

  • Detecting an online poker cheat

    - by Tom Gullen
    It recently emerged on a large poker site that some players were possibly able to see all opponents cards as they played through exploiting a security vulnerability that was discovered. A naïve cheater would win at an incredibly fast rate, and these cheats are caught very quickly usually, and if not caught quickly they are easy to detect through a quick scan through their hand histories. The more difficult problem occurs when the cheater exhibits intelligence, bluffing in spots they are bound to be called in, calling river bets with the worst hands, the basic premise is that they lose pots on purpose to disguise their ability to see other players cards, and they win at a reasonably realistic rate. Given: A data set of millions of verified and complete information hand histories Theoretical unlimited computer power Assume the game No Limit Hold'em, although suggestions on Omaha or limit poker may be beneficial How could we reasonably accurately classify these cheaters? The original 2+2 thread appeals for ideas, and I thought that the SO community might have some useful suggestions. It's an interesting problem also because it is current, and has real application in bettering the world if someone finds a creative solution, as there is a good chance genuine players will have funds refunded to them when identified cheaters are discovered.

    Read the article

  • Undefined Web.config error in VS 2008

    - by user1066050
    I'm working on a web app using VS 2008, .Net 3.5 and C#. Most of the projects in the solution are either classic asp.net pages with some MVC 1 in the mix, the rest is shared libraries. The solution is one that is some 5 years old and has gone through a variety of developers working on it and clearly has some performance and architectural issues. Previously, I've been working on the project using VS 2008 on a Win XP machine, but have just transitioned over to a new box using Win 7 Ultimate. To do so, I've installed VS 2008, asp.net 3.5. To support future work on the solution I've also installed VS 2010 and asp.net 4.0. Opening the solution on the new box with VS 2008 works fine, and it builds without error. However, when I attempt to run it with the debugger, I get the following message: "There is an error in web.config. Please correct before proceeding. (You might rename the current web.config and add a new one.)" I think it's clear that there is some sort of environmental issue regarding web.config on the new machine, but the error message is not "helpful". Adding a new web.config is not an option as the existing one is quite long and involved (too much to post here). I'm hoping someone has a suggestion or two about where I might look for missing elements or changed configurations that might produce such an error message. Lacking that, I'll revisit this post and provide the web.config in the hope that will elicit further help. Thanks to all in advance for taking a look at this. The StackOverflow community has helped me many times in the past with pertinent answers although this is my first posting. Jeff

    Read the article

  • query structure - ignoring entries for the same event from multiple users?

    - by Andrew Heath
    One table in my MySQL database tracks game plays. It has the following structure: SCENARIO_VICTORIES [ID] [scenario_id] [game] [timestamp] [user_id] [winning_side] [play_date] ID is the autoincremented primary key. timestamp records the moment of submission for the record. winning_side has one of three possible values: 1, 2, or 0 (meaning a draw) One of the queries done on this table calculates the victory percentage for each scenario, when that scenario's page is viewed. The output is expressed as: Side 1 win % Side 2 win % Draw % and queried with: SELECT winning_side, COUNT(scenario_id) FROM scenario_victories WHERE scenario_id='$scenID' GROUP BY winning_side ORDER BY winning_side ASC and then processed into the percentages and such. Sorry for the long setup. My problem is this: several of my users play each other, and record their mutual results. So these battles are being doubly represented in the victory percentages and result counts. Though this happens infrequently, the userbase isn't large and the double entries do have a noticeable effect on the data. Given the table and query above - does anyone have any suggestions for how I can "collapse" records that have the same play_date & game & scenario_id & winning_side so that they're only counted once?

    Read the article

  • Avoiding seasonality assumption for stl() or decompose() in R

    - by user303922
    Hello everybody, I have high frequency commodity price data that I need to analyze. My objective is to not assume any seasonal component and just identify a trend. Here is where I run into problems with R. There are two main functions that I know of to analyze this time series: decompose() and stl(). The problem is that they both take a ts object type with a frequency parameter greater than or equal to 2. Is there some way I can assume a frequency of 1 per unit time and still analyze this time series using R? I'm afraid that if I assume frequency greater than 1 per unit time, and seasonality is calculated using the frequency parameter, then my forecasts are going to depend on that assumption. names(crude.data)=c('Date','Time','Price') names(crude.data) freq = 2 win.graph() plot(crude.data$Time,crude.data$Price, type="l") crude.data$Price = ts(crude.data$Price,frequency=freq) I want frequency to be 1 per unit time but then decompose() and stl() don't work! dim(crude.data$Price) decom = decompose(crude.data$Price) win.graph() plot(decom$random[2:200],type="line") acf(decom$random[freq:length(decom$random-freq)]) Thank you.

    Read the article

  • Looking for a 'pick a-or-b' voting system script

    - by user324455
    Apologies: this is my first time on stackoverflow and I'm starting with a question and seeking advice. Sorry. Caveats: I know HTML and CSS pretty well. Javascript and PHP are not completely alien, but I'm really pretty basic on those. That said, I'm pretty sharp and willing to search for explanations independently. Ok, so my question is this: I want to create a site with a voting system very much like the one on kittenwar.com - the page loads 2 random images from a db of some sort and you click on the one you want to 'win'. Ranked pairs kind of deal. Then there is a leaderboard of those images which have the highest win-loss ratio. There also needs to be an uploader for peeps to upload their own images and have them go into an approval workflow, and from there into the db that feeds the voting thing. I tried a pre-made solution ('photo battle') but found it was completely standalone, so trying to integrate it or change any of the options was a nightmare, plus it was buggy. i'm sure there has to be a relatively easy way to do this, right? Ideally I'd like to build my site in Joomla and integrate this functionality somehow. I'd be very grateful for any advice on this. Thanks Tom

    Read the article

  • WinUSB failing on non-development computers

    - by Giawa
    Good afternoon, WinUSB is working well on the development computer that I am using (Win XP SP3). I am able to download new firmware to the Cypress FX2, and then connect to the new USB device once it 'renumerates'. However, if I've tried the same code with the WinUSB driver on a few other computers (Win XP SP3, Win7 x64) and they both returned the error "A device attached to the system is not functioning." when trying to use CreateFile to get a handle to the USB device. The devicePath was found successfully, so I'm not sure why it cannot connect to the device. Furthermore, the device manager states that my device is working properly. I'm curious if I'm missing something when compiling the code? I would guess that my development computer has something installed on it that the other computers do not? Or perhaps it's a power setting and the device is going to sleep (although I've fooled around with the Power Options on each computer to no avail). Does anyone have any ideas? I've compiled under Visual Studio 2008, and have installed the Microsoft C++ 2008 Redistributable Package on the computers that I've tested on. Thanks, Giawa

    Read the article

  • asp.net 3.5 app - can not load asemblies, "Strong name signature could not be verified", only when d

    - by hitsolutions
    Have developed an asp.net 3.5 application which consists of a we-site, some developed assemblies and some 3rd party assembles such as Telerik, Jayrock etc, all very much standard 3rd party apps. Created and built this app, tested on Win 2008 Eval running on a VM, all fine. Imagine my frustration when after installing on clients production Win 2008 server, that the app could not run and the error message was the "Strong name signature could not be verified. The assembly may have been tampered with, or it was delay signed ..." one. This was for all assembles in app (removed one and this kept popping up for a different assembly). Attempted to install on a machine on the network and received the same error. I am fairly baffled and a little freaked as I can not figure this out and time is rapidly running out. Have inspected all parts of server I know about (.NET, IIS7) but all seems fine. What could cause this? It sounds like there is a stricter security manifest on the production server - but where would I look and for what? It must be a group policy. only other item is that the machines are running Symantec ante-virus. The IT head is on hols so can't quiz him which is also frustrating - but as they say time waits for no man!

    Read the article

  • Limiting the width of a TextBlock in Silverlight

    - by Druzil
    The obvious MaxWidth gets ignored and the text in the "DisplayBox" TextBlock displays the whole text even if this text continues past the parent container controls (to the edge of the silverlight area. <win:HierarchicalDataTemplate x:Key="hierarchicalTemplate" ItemsSource="{Binding _children}"> <Border BorderThickness="0" BorderBrush="Orange" HorizontalAlignment="Stretch" Background="{Binding Converter={StaticResource BackgroundConverter}}"> <toolkit:DockPanel LastChildFill="True" Width="{Binding HeirarchyLevel, Converter={StaticResource WidthConverter}}" Height="20"> <Canvas toolkit:DockPanel.Dock="Right" Width="20" MouseLeftButtonUp="Arrow_MouseLeftButtonDown"> <Rectangle Width="20" Height="20" Fill="Transparent" /> <Line Stroke="Black" X1="5" Y1="10" X2="17" Y2="10" /> <Line Stroke="Black" X1="11" Y1="5" X2="17" Y2="10" /> <Line Stroke="Black" X1="11" Y1="15" X2="17" Y2="10" /> </Canvas> <Ellipse Canvas.Top="5" Width="10" Height="10" Fill="Green" toolkit:DockPanel.Dock="Right" MouseLeftButtonDown="Ellipse_MouseLeftButtonDown" /> <Canvas Width="Auto" Loaded="TextArea_Loaded"> <TextBlock Name="DisplayBox" FontFamily="Arial" FontSize="17" Foreground="Black" Width="Auto" Text="{Binding TaskName}" MouseLeftButtonUp="TextBlock_MouseLeftButtonUp" /> <TextBox Name="EditBox" FontFamily="Arial" FontSize="10" Foreground="Black" Height="20" Text="{Binding TaskName}" Visibility="Collapsed" LostFocus="TextBox_LostFocus" /> <Line Stroke="Black" X1="0" Y1="10" X2="202" Y2="10" Width="Auto" /> </Canvas> </toolkit:DockPanel> </Border> </win:HierarchicalDataTemplate>

    Read the article

  • Javafx Layout problem with VBox & HBoxes

    - by pgpatrudu
    When I run the following, I noticed spacing between nodes; My research revealed that - 1) If I do not add any text to win1 via setwininfo, then there is no problem. 2) When I include this code in a larger app, and when a button click is reveived from some where else, mysteriously the spacing gets corrected. 3) I tried binding the win1 & win2 nodes to content of scene - but no luck. def mainframew : Integer = 250; def mainframeh : Integer = 500; class CtrlWindow extends CustomNode { var wininfo : String; var fsize : Integer; var width : Integer; public function setWinInfo(info : String) { wininfo = info; } override protected function create () : Node { var win = Group { content: [ VBox { content: [ Text { font : Font { size: fsize } content : bind wininfo textAlignment : TextAlignment.CENTER // did not work } ] } Rectangle { width: width, height: 25 fill: Color.TRANSPARENT strokeWidth : 2 stroke : Color.SILVER } ] } return win; } } public function run(args : String[]) { var win1 = CtrlWindow{fsize:14, width:mainframew}; var win2 = CtrlWindow{fsize:14, width:mainframew}; win1.setWinInfo("The spacing between these nodes"); win2.setWinInfo("corrects itself after receiving an event"); Stage { title : "MyApp" scene: Scene { width: mainframew height: mainframeh content: [ VBox { spacing: 0 content: [ HBox { content: win1 } HBox { content: win2 } ] } ] } }

    Read the article

  • How to delete Drawn Line in java?

    - by Jeyjey
    Hello Folks, well this is my code: import javax.swing.; import javax.; import java.awt.; import java.awt.Color; import java.awt.Graphics.; import java.awt.event.*; import javax.swing.UIManager; public class SimpleGUI extends JFrame{ public SimpleGUI(){ this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE) ; } public void go(){ Drawpanel = new Mypanel(); JFrame frame = new JFrame("Chasing Line"); frame.getContentPane().add(BorderLayout.CENTER, Drawpanel); frame.setSize(300,300); frame.setVisible(true); Drawpanel.addMouseMotionListener(new java.awt.event.MouseMotionAdapter() { public void mouseMoved(java.awt.event.MouseEvent evt) { DrawpanelMouseMoved(evt); } }); } public void DrawpanelMouseMoved(java.awt.event.MouseEvent evt) { xpos=evt.getX(); ypos=evt.getY(); System.out.println("Coordinates : X :"+ xpos+"Y: "+ypos); Drawpanel.paintImage(xpos,ypos); } class Mypanel extends JPanel{ public void paintImage(int xpost,int ypost){ Graphics d = getGraphics(); d.setColor(Color.black); d.drawLine(xpost, 0, xpost, this.getHeight()); d.setColor(Color.red); d.drawLine(0, ypost, this.getWidth(),ypost); this.validate(); } } // end the inner class public static void main(String[] args){ try { UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel"); } catch(Exception e) { System.err.println("Look and feel not set"); } SimpleGUI win = new SimpleGUI(); win.go(); } Mypanel Drawpanel; private int xpos=0; private int ypos=0; } // close SimpleGUI class The problem is how can i delete the old lines?, i mea,make only the current x and y lines appear on the screen, make the intersection between both lines "follow" the mouse pointer. thanks for any reply.

    Read the article

  • Window manipulation and inctences control

    - by touki
    In my application there are only 2 windows — win_a & win_b, on each of these windows there is button that call another window, e.g. click on btn1 of win_a will call win_b, click on btn2 of win_b will show win_a. Desired behaviour: 1. Only one instance of object is premitted at the same time, e.g. situation, where 2 instances of win_a running at the same time is not permitted. When you click on button that calls windows that already exist this action will only change a focus to needed window. If you call a window that previously had been created, but after this has been closed this action will create a new instance of this window. E.g. there are 2 running windows. you close one of them and after try to call this window back, so related button will create it. How to write it in WPF (XAML + C#). For the moment I wrote a version that can create a lot of instances of the same window (no number of instances control implemented), but I want to see only one instance of the same window, as we can see it in a lot of applications. Example of my code: Window win = new Window(); win.Show(); Thanks.

    Read the article

  • Calculating percent "x/y * 100" always results in 0?

    - by Patrick Beninga
    In my assignment i have to make a simple version of Craps, for some reason the percentage assignments always produce 0 even when both variables are non 0, here is the code. import java.util.Random; Header, note the variables public class Craps { private int die1, die2,myRoll ,myBet,point,myWins,myLosses; private double winPercent,lossPercent; private Random r = new Random(); Just rolls two dies and produces their some. public int roll(){ die1 = r.nextInt(6)+1; die2 = r.nextInt(6)+1; return(die1 + die2); } The Play method, this just loops through the game. public void play(){ myRoll = roll(); point = 0; if(myRoll == 2 ||myRoll == 3 || myRoll == 12){ System.out.println("You lose!"); myLosses++; }else if(myRoll == 7 || myRoll == 11){ System.out.println("You win!"); myWins++; }else{ point = myRoll; do { myRoll = roll(); }while(myRoll != 7 && myRoll != point); if(myRoll == point){ System.out.println("You win!"); myWins++; }else{ System.out.println("You lose!"); myLosses++; } } } This is where the bug is, this is the tester method. public void tester(int howMany){ int i = 0; while(i < howMany){ play(); i++; } bug is right here in these assignments statements winPercent = myWins/i * 100; lossPercent = myLosses/i* 100; System.out.println("program ran "+i+" times "+winPercent+"% wins "+ lossPercent+"% losses with "+myWins+" wins and "+myLosses+" losses"); } }

    Read the article

< Previous Page | 53 54 55 56 57 58 59 60 61 62 63 64  | Next Page >