Daily Archives

Articles indexed Thursday May 13 2010

Page 12/119 | < Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >

  • Script for run script

    - by user31568
    Hello everyone. There is script: Dim WSHShell, WinDir, Value, wshProcEnv, fso, Spath Set WSHShell = CreateObject("WScript.Shell") Dim objFSO, objFileCopy Dim strFilePath, strDestination Const OverwriteExisting = True Set objFSO = CreateObject("Scripting.FileSystemObject") Set windir = objFSO.getspecialfolder(0) objFSO.CopyFile "\dv.rt.ru\SYSVOL\DV.RT.RU\scripts\shutdown.vbs", windir&"\", OverwriteExisting strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\" _ & strComputer & "\root\cimv2") JobID = "1" Set colScheduledJobs = objWMIService.ExecQuery _ ("Select * from Win32_ScheduledJob") For Each objJob in colScheduledJobs objJob.Delete Next Set objNewJob = objWMIService.Get("Win32_ScheduledJob") errJobCreate = objNewJob.Create _ (windir & "\shutdown.vbs", "**093000.000000+660", _ True, 1 OR 2 OR 4 OR 8 OR 16 OR 32 OR 64, ,True, JobId) How make that shutdown.vbs run not at 9:00 once, but run for 9:00 to 12:00 Thanks

    Read the article

  • Acer Aspire PC locked up and won't re-start

    - by Jim Scott
    Vista Home Premium locked up on 5/12/10 while on a website and could not get to 'control-alt-delete.' Mouse locked, too. On/off switch would not work (stayed lit) so I unplugged the power cord. When I tried to re-start the computer I could hear a fan running but it would not boot up, nothing on the monitor and no lights on the keyboard. O/S was preloaded so I do not have a boot disk.I tried pressing F1, F2 and F11 and also with monitor off but nothing worked. Computer has not been been moved or abused so all internal connections should be fine. Have updated Windows Vista Home Premium regularly and also updated Avira anti virus and anti malware programs regularly. Using Firefox and Vista Home Premium O/S. Computer is 2 years old and was purchased new from Best Buy.

    Read the article

  • Have you ever seen an install of IE 8 whose version number was still 6.0?

    - by Justin
    I was at a local university computer lab presenting a website I work on and I discovered something that looked really unusual to me. Their machines had Internet Explorer 8 installed, but when you check the version number (Help-About Internet Explorer) it listed the version number as 6.0. It also gave me an "Operation Aborted" error that is supposed to be gone in IE8. Has anyone else run across this situation?

    Read the article

  • How can I modify my code to line through the bezier control points?

    - by WillyCornbread
    HI all - I am using anchor points and control points to create a shape using curveTo. It's all working fine, but I cannot figure out how to get my lines to go through the center of the control points (blue dots) when the line is not straight. Here is my code for drawing the shape: // clear old line and draw new / begin fill var g:Graphics = graphics; g.clear(); g.lineStyle(2, 0, 1); g.beginFill(0x0099FF,.1); //move to starting anchor point var startX:Number = anchorPoints[0].x; var startY:Number = anchorPoints[0].y; g.moveTo(startX, startY); // Connect the dots var numAnchors:Number = anchorPoints.length; for (var i:Number=1; i<numAnchors; i++) { // curve to next anchor through control g.curveTo(controlPoints[i].x,controlPoints[i].y, anchorPoints[i].x, anchorPoints[i].y); } // Close the loop g.curveTo(controlPoints[0].x,controlPoints[0].y,startX,startY); And the shape I'm drawing for reference: How can I modify my code so that the lines go directly through the blue control points? Thanks in advance! b

    Read the article

  • Most efficient way to check if a date falls between two dates?

    - by Dave Jarvis
    Given: Start Month & Start Day End Month & End Day Any Year What SQL statement results in TRUE if a date lands between the Start and End days? 1st example: Start Date = 11-22 End Date = 01-17 Year = 2009 Specific Date = 2010-01-14 TRUE 2nd example: Start Date = 11-22 End Date = 11-16 Year = 2009 Specific Date = 2010-11-20 FALSE 3rd example: Start Date = 02-25 End Date = 03-19 Year = 2004 Specific Date = 2004-02-29 TRUE I was thinking of using the MySQL functions datediff and sign plus a CASE condition to determine whether the year wraps, but it seems rather expensive. Am looking for a simple, efficient calculation. Update The problem is the end date cannot simply use the year. The year must be increased if the end month/day combination happens before the start date. The start date is easy: Start Date = date( concat_ws( '-', year, Start Month, Start Day ) The end date is not so simple. Thank you!

    Read the article

  • How to customize flash message based on success or failure with Inherited Resources Rails plugin?

    - by wgpubs
    I'm using the inherited resources plugin in a 2.3.5 Rails application and was wondering how to change the flash[:notice] (or any other flash) based on the success OR failure in my create and update actions. So given the below, how do I add flash[:notice] = "All good" if success ... and flash[:notice] = "All bad" if failure? Thanks class ArticleController < InheritedResources::Base actions :show, :create, :update respond_to :html, :json before_filter :authorize_upsert, :only => [:create, :update] def create #init new game @article = Article.new set_article_attributes_from_app @article.is_published = params[:article_publish_to_web] || false @ article.game_source = @client_application create! do |success, failure| success.html {redirect_to(@article)} success.json {render :json => {:id=>@article.id, :created_at=>@article.created_at, :picture_urls=> @article.assets.map { |a| root_url.chop + a.photo.url}}} failure.html {render :action => "show"} failure.json {render :json=>@article.errors, :status => :unprocessable_entity} end end

    Read the article

  • Find messages[from-to]

    - by Alfred
    I would like to return all messages from certain key to a certain key. The class should be thread-safe and old keys should be able to be deleted say for example after 30 seconds. I was thinking of using a concurrentskiplistset or concurrentskiplist map. Also I was thinking of deleting the items from inside a newSingleThreadScheduledExecutor. I would like to know how you would implement this or maybe use a library?

    Read the article

  • Using Sendkeys in python to press {F12} results in other keys pressed?

    - by ThantiK
    import time from ctypes import * import win32gui import win32com.client as comclt X = 119 Y = 53 def PILColorToRGB(pil_color): """ convert a PIL-compatible integer into an (r, g, b) tuple """ hexstr = '%06x' % pil_color # reverse byte order r, g, b = hexstr[4:], hexstr[2:4], hexstr[:2] r, g, b = [int(n, 16) for n in (r, g, b)] return (r, g, b) wsh = comclt.Dispatch("WScript.Shell") w = win32gui user = windll.LoadLibrary("c:\\windows\\system32\\user32.dll") h = user.GetDC(0) gdi = windll.LoadLibrary("c:\\windows\\system32\\gdi32.dll") while True: FG = w.GetWindowText(w.GetForegroundWindow()) #FG = Foreground window title. if FG == "World of Warcraft": rgb = (PILColorToRGB(gdi.GetPixel(h,X,Y))) #X, Y time.sleep(0.333) #don't check too often. if (rgb[0] >= 130): #While Pixel (X, Y) is Red... #print "%d %d %d" % (rgb[0], rgb[1], rgb[2]) #Debug wsh.SendKeys("{F12}") #Send a key. time.sleep(0.7) #Add some extra down-time if we send the key. else: time.sleep(5) Basically all this code does is read a pixel on the screen, and send a key (F12) if the pixel is red. But when using this code I regularly get some phantom key-code being pressed. The application I'm using this on is obviously world of warcraft, and I have checked that all keybinds are standard keybinds. However randomly it seems I get either an up arrow, or a w pressed, which moves my character forward whenever this code executes (F12 is bound to a macro, unbound from any movement. If I press f12 with a hardware event, it does not exhibit this behavior. What in the world could be going on here?

    Read the article

  • How to process large block data visualization with Flex?

    - by hydra1983
    I know that's a big topic. However, it's better to know some general ideas to handle such problems. I have an application which requires Flex to render statistics data calculated instantly on the client side from a downloaded data set. The problems are: the data set is large and needs more than 10 seconds to be downloaded. there are some filters to control the statistics calculation algorithms. If user changes the filters, it would take a long time to recalculate the result and freeze the UI.

    Read the article

  • WPF integrate Windows live authentication for windows health vault

    - by AnD
    Hi all, I'm just wondering if there's any way for WPF application integrated with windows live ID? and it's actually for windows health vault [www.healthvault.com] so health vault is using windows live id or open id to login into their system. and what i gonna do is, creating wpf application (instead of web application) for health vault, so all of the login form username pass and everything is handled inside the wpf application without showing/using any internet browser. so since this's quite new for me, i hope if there's somebody ever did this before especially for health vault system that run on standalone wpf app. alright, so that's it, thank you in advance!

    Read the article

  • Problem with iPhone interoperability and Flash

    - by asksuperuser
    Many Fortune 500 companies have incorporated flash in their websites. What solution to port them to all Mobiles as I hear Apple refuses to get flash ? So what solution does one have ? Redevelop everything at awfull cost using different apis for different mobiles ? Why does iphone refuses to incorporate flash ? What's the purpose of such restriction ?

    Read the article

  • Calling a function within a class

    - by JM4
    I am having trouble calling a specific function within a class. The call is made: case "Mod10": if (!validateCreditCard($fields[$field_name])) $errors[] = $error_message; break; and the class code is: class CreditCardValidationSolution { var $CCVSNumber = ''; var $CCVSNumberLeft = ''; var $CCVSNumberRight = ''; var $CCVSType = ''; var $CCVSError = ''; function validateCreditCard($Number) { $this->CCVSNumber = ''; $this->CCVSNumberLeft = ''; $this->CCVSNumberRight = ''; $this->CCVSType = ''; $this->CCVSError = ''; // Catch malformed input. if (empty($Number) || !is_string($Number)) { $this->CCVSError = $CCVSErrNumberString; return FALSE; } // Ensure number doesn't overrun. $Number = substr($Number, 0, 20); // Remove non-numeric characters. $this->CCVSNumber = preg_replace('/[^0-9]/', '', $Number); // Set up variables. $this->CCVSNumberLeft = substr($this->CCVSNumber, 0, 4); $this->CCVSNumberRight = substr($this->CCVSNumber, -4); $NumberLength = strlen($this->CCVSNumber); $DoChecksum = 'Y'; // Mod10 checksum process... if ($DoChecksum == 'Y') { $Checksum = 0; // Add even digits in even length strings or odd digits in odd length strings. for ($Location = 1 - ($NumberLength % 2); $Location < $NumberLength; $Location += 2) { $Checksum += substr($this->CCVSNumber, $Location, 1); } // Analyze odd digits in even length strings or even digits in odd length strings. for ($Location = ($NumberLength % 2); $Location < $NumberLength; $Location += 2) { $Digit = substr($this->CCVSNumber, $Location, 1) * 2; if ($Digit < 10) { $Checksum += $Digit; } else { $Checksum += $Digit - 9; } } // Checksums not divisible by 10 are bad. if ($Checksum % 10 != 0) { $this->CCVSError = $CCVSErrChecksum; return FALSE; } } return TRUE; } } When I run the application - I get the following message: Fatal error: Call to undefined function validateCreditCard() in C:\xampp\htdocs\validation.php on line 339 any ideas?

    Read the article

  • Testing Shake events on Android Emulator

    - by mob-king
    Can any one help with how to test sensor events like shake on Android Emulator. I have found some posts pointing to openintents but can anyone explain how to use it in android 2.0 avd http://code.google.com/p/openintents/wiki/SensorSimulator This has some solution but while installing OpenIntents.apk on emulator gives missing library error.

    Read the article

  • Are there any design-patterns specifically useful for game-development?

    - by Baelnorn
    This question's been bugging me for a long time. I've always wondered how game developers were solving certain problems or situations that are quite common in certain genres. For example, how would one implement the quests of a typical role-playing game (e.g. BG or TES)? Or how would you implement weapons with multiple stacking effects in a first-person shooter (e.g. the Shrink-gun or Freezer from DN3D)? How would you implement multiple choice options with a possibly intricate decision tree leading to several different outcomes (e.g. the mission trees in WC)? Are there any examples or other resources for that? Blogs? Books? Sourcecode?

    Read the article

  • How to wire a verifier to a 2.0m5 Restlet using the spring extension and an xml config?

    - by Kevin Pauli
    I can't seem to find any example of how to do this. Imperatively in java it would be a piece of cake of course, but I can't seem to figure out how to inject my JaasVerifier into my SpringComponent declaratively from within the xml. It appears from the method signatures that Verifier is designed to be attached to Context, but the instance of Context itself is created as a side effect of the SpringComponent creation so I can't get a hold of it in Spring. There must be something I am missing.

    Read the article

  • What application have you integrated with/developed on - that you would intentionally leave off your

    - by scunliffe
    You may well be an expert now working with "Application X"... However the hair pulling was so much that you'd never add it to your resume (even though it might sound impressive) for fear that a future employer might think your the ideal candidate to "migrate", "integrate" or otherwise work with "Application X". Feel free to elaborate on why... (e.g. their APIs change monthly, there is/was no API, etc.) (made into a community wiki)

    Read the article

  • Adding a hyperlink in a client report definition file (RDLC)

    - by rajbk
    This post shows you how to add a hyperlink to your RDLC report. In a previous post, I showed you how to create an RDLC report. We have been given the requirement to the report we created earlier, the Northwind Product report, to add a column that will contain hyperlinks which are unique per row.  The URLs will be RESTful with the ProductID at the end. Clicking on the URL will take them to a website like so: http://localhost/products/3  where 3 is the primary key of the product row clicked on. To start off, open the RDLC and add a new column to the product table.   Add text to the header (Details) and row (Product Website). Right click on the row (not header) and select “TextBox properties” Select Action – Go to URL. You could hard code a URL here but what we need is a URL that changes based on the ProductID.   Click on the expression button (fx) The expression builder gives you access to several functions and constants including the fields in your dataset. See this reference for more details: Common Expressions for ReportViewer Reports. Add the following expression: = "http://localhost/products/" & Fields!ProductID.Value Click OK to exit the Expression Builder. The report will not render because hyperlinks are disabled by default in the ReportViewer control. To enable it, add the following in your page load event (where rvProducts is the ID of your ReportViewerControl): protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { rvProducts.LocalReport.EnableHyperlinks = true; } } We want our links to open in a new window so set the HyperLinkTarget property of the ReportViewer control to “_blank”   We are done adding hyperlinks to our report. Clicking on the links for each product pops open a new windows. The URL has the ProductID added at the end. Enjoy!

    Read the article

  • Developer Developer Developer Scotland 2010

    - by Chris Hardy (ChrisNTR)
    This past weekend, I headed up to Glasgow thanks to Plip for driving and Dave Sussman for some light entertainment to do a session on C# on the iPhone with MonoTouch. I had already presented a session similar to this one at DDD8 in Reading, which you can watch on Vimeo ( http://vimeo.com/9150434 ) but in this session I covered more topics such as the new 3.3.1 section of the new terms of service Apple released. I also showed a Twitter example written in MonoTouch, which was reused from the DDD8 session...(read more)

    Read the article

  • Live Meeting error: malformed email address... or IS IT???

    - by PeterBrunone
    During a remote SharePoint training session this morning, Live Meeting presented one of our instructors with the following gem:  "An attendee email address is malformed".  This was particularly troubling since a wizard took care of adding all the entries, and they looked correct (even after being sifted through my character analysis tool).As it turns out, the addresses were indeed correct.  As sometimes happens, though, at the line breaks, it looked like there was no space between the semicolon and the following email address.  Since I'm a member in good standing of the "I wonder what this button does" school of thought, I added an extra space after each of these cramped little semicolons -- and the invitation executed flawlessly.Coincidence?  Maybe... but you can bet I'm going to keep trying dumb stuff like that when the error message doesn't make sense.  Think of it as the tech support equivalent of "Ask a silly question..."

    Read the article

  • Need Help with fixing permissions in mounted Drive

    - by Master
    I am trying a lot still my problem is not solved. I have a partion called Server and inside it i have 5 folders like Folder 1 FOlder 2 Folder 3 I am mounting the drive on startup by using following command as told to me by some senoir members and it works but with some problems /dev/sdb1 /media/Server ntfs defaults,umask=006,fmask=000,dmask=007,uid=1000,gid=1001 0 0 The problem is with this command the permission are applied to all folders like Folder 1 , Folder 2 , FOlder3 But i want that only FOlder 3 should be publicly readable and writable while all other should be private and no one should have access to that. How can i achieve that

    Read the article

  • How to calibrate your mouse's X/Y in Windows Vista

    - by GateKiller
    I've just installed a new Microsoft Wireless Laser Mouse 5000 and it's X/Y calibration/alignment seems to be off. If I move the mouse from left to right, the cursor will go up and down slightly. If I move the mouse from top to bottom, the cursor will also move from left to right slightly too. I seem to remember in earlier version of Windows or Intelli Point, there was a calibration tool which would fix this issue. Can anyone help? Many Thanks Stephen

    Read the article

  • PORT FORWARDING TO PUT MY WEB SERVER ON THE INTERNET

    - by Chadworthington
    I went to http://canyouseeme.org/ to check to see what my external IP address. Regardless of what port I enter, it tells me that the port is blocked. I have a LinkSys router that basically has the default settings with the exception that I have WEP encrptin setup and I have forwarded a few ports, including 80 and 69. I forwarded them to the 192.x.x.103 IP address of the PC which is running IIS. That PC runs Symantec Endpoint Protection, which I right mouse clicked in the tray to Disable. These steps used to make my PC visible so I could host my own web site in IIS on port 80, or some other port, like 69. Yet, the Open Port tool cannot see my IP when it checks eiether port and when I navigate to http://my external ip/ I get "page cant be displayed" At first I was thinking that maybe Comcast is blocking port 80, but 69 doesnt work eiether. I do not see any other blockking set up in my router and, as I mentioned, I went with teh defaults except where discussed. This is a corporate PC and Symantec End Point Protecion is new to it (this previously worked on teh same PC with Symantec Protection Agent), but I thought that disabling Sym End Pt from the tray, that that would effectively neutralize it. I do not have the rights to kill the program itself. Any suggestions on what else to try to make my PC externally visible?

    Read the article

  • Panel not displaying while dowloading file

    - by James123
    I wrote download excel file in my code. If I click download button I need show ajax-load image (pnlPopup panel). But it is not displaying. I think because of Some "Response" statements (see below code). Download working fine, but simultaniously I want show loader panel too. <asp:Panel ID="pnlPopup" runat="server" visible="false"> <div align="center" style="margin-top: 13px;"> <asp:Image runat ="server" ID="imgDownload" src="Images/ajax-loader.gif" alt="" /> <br /> <span class="updateProgressMessage">downloading ...</span> </div> Protected Sub btnDownload_Click(ByVal sender As Object, ByVal e As EventArgs) 'Handles btnDownload.Click' Try pnlPopup.Visible = True Dim mSurvey As New Survey Dim mUser As New User Dim dtExcel As DataTable mUser = CType(Session("user"), User) dtExcel = mSurvey.CreateExcelWorkbook(mUser.UserID, mUser.Client.ID) Dim filename As String = "Download.xls" InitializeWorkbook() GenerateData(dtExcel) Response.ContentType = "application/vnd.ms-excel" Response.AddHeader("Content-Disposition", String.Format("attachment;filename={0}", filename)) Response.Clear() Response.BinaryWrite(WriteToStream.GetBuffer) Response.End() Catch ex As Exception Finally End Try End Sub

    Read the article

< Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >