Daily Archives

Articles indexed Thursday April 1 2010

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

  • Weve Moved!

    Ive moved my blog to a new home at http://SilverlightGeek.me.  Within a few days, all the links here should automatically redirect you there. Thanks for sticking with me and I look forward to your feedback.             ( You can also reach the new blog at http://slgeek.com/wordpress )This work is licensed under a Creative Commons license. ...Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • Calling PowerShell from .NET

    I have been working with Windows Server AppFabric caching lately and have found it to be very impressive.  The more that I work with it the more that I can see areas that it can be utilized.  One of the things that will become quite evident as you start using it is that much of the setup and configuration is done through PowerShell cmdlets. I am in the process of putting together an application and I want the application to be able to create and pre-populate the cache.  As I looked...Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • How to know which speed of RAM can I use

    - by Phuong Nguyen
    I have a Dell Vostro 1000 which uses ATI RS480 mainboard. Specification says that the front bus of such mainboard is 1Ghz. However, the default RAM came with mainboard is PC4200 (533Mhz). I wonder if I can replace them with PC6400 (800Mhz) or at least PC5300 (667Mhz)?

    Read the article

  • How Can I Detect A Data Type in AS3

    - by Jascha
    I'd like to make a call to a function and send either a string or an integer... function getImage(val:*):void{ if(val == String){ switch(val){ case'next': loadNext(); break; case'prev': loadPrev(); break } } }else{ loadImg(val); } } and vary my function accordingly... anyone know how to detect the parameter type? Thanks -J

    Read the article

  • Checking if Date is within Range

    - by Brett Powell
    So I am using a scripting language with c++ syntax, and trying to think of the best way to check if a date is within range. The problem I am running into is that if the current day is in a new month, the check is failing. Here is what my code looks like... if(iMonth >= iStartMonth && iMonth <= iEndMonth) { if(iDay >= iStartDay && iDay <= iEndDay) { if(iYear >= iStartYear && iYear <= iEndYear) { bEnabled = true; return; When I have something like this... (Pulled in from cfg file specified by client) Start date: 3 27 2010 End Date: 4 15 2010 Current Date: 3 31 2010 The day check fails because if(iDay <= iEndDay) does not pass. The scripting language doesn't have a lot of time related functions, and I cant compare timestamps because im allowing users to put like "03:27:2010" and "04:15:2010" as start/end dates in a config file. Im assuming I am just not thinking straight and missing an easy fix.

    Read the article

  • Dollar ($) sign in password string treated as variable

    - by ncatnow
    Spent some time troubleshooting a problem whereby a PHP/MySQL web application was having problems connecting to the database. The database could be accessed from the shell and phpMyAdmin with the exact same credentials and it didn't make sense. Turns out the password had a $ sign in it: $_DB["password"] = "mypas$word"; The password being sent was "mypas" which is obviously wrong. What's the best way to handle this problem? I escaped the $ with a \ $_DB["password"] = "mypas\$word"; and it worked. I generally use $string = 'test' for strings which is probably how I avoided running into this before. Is this correct behavious? What if this password was stored in a database and PHP pulled it out - would this same problem occur? What am I missing here...

    Read the article

  • simple c# arithmetics. winForms

    - by jello
    I'm doing simple divisions in c#, and I am a bit puzzled by its intricacies. Here's some code, and in the comments, the result. (btw, I only compile with 1 line not commented, if you say that I have 5 declarations of the same variable) double result = 2 / 3; //gives 0 double result = Convert.ToDouble(2) / Convert.ToDouble(3); // is good double result = double.Parse(2) / double.Parse(3); // gives me errors double result = double.Parse(2 / 3); // gives me errors double result = Convert.ToDouble(2 / 3); // gives 0 MessageBox.Show(result.ToString()); so if you have a bunch of integers you wanna mess with, you have to convert each one to a double. pretty tedious...

    Read the article

  • Converting an AnsiString to a Unicode String

    - by jrodenhi
    I'm converting a D2006 program to D2010. I have a value stored in a single byte per character string in my database and I need to load it into a control that has a LoadFromStream, so my plan was to write the string to a stream and use that with LoadFromStream. But it did not work. In studying the problem, I see an issue that tells me that I don't really understand how conversion from AnsiString to Unicode string works. Here is some code I am puzzling over: oStringStream := TStringStream.Create(sBuffer); sUnicodeStream := oPayGrid.sStream; //explicit conversion to unicode string iSize1 := StringElementSize(oPaygrid.sStream); iSize2 := StringElementSize(sUnicodeStream); oStringStream.WriteString(sUnicodeStream); When I get to the last line, iSize1 does equal 1 and iSize2 does equal 2, so that part is what I understood from my reading. But, on the last line, after I write the string to the stream, and look at the Bytes Property of the string, it shows this (the string starts as '16,159'): (49 {$31}, 54 {$36}, 44 {$2C}, 49 {$31}, 53 {$35}, 57 {$39} ... I was expecting that it might look something like (49 {$31}, 00 {$00}, 54 {$36}, 00 {$00}, 44 {$2C}, 00 {$00}, 49 {$31}, 00 {$00}, 53 {$35}, 00 {$00}, 57 {$39}, 00 {$00} ... I'm not getting the right results out of the LoadFromStream because it is reading from the stream two bytes at a time, but the data it is receiving is not arranged that way. What is it that I should do to give the LoadFromStream a well formed stream of data based on a unicode string? Thank you for your help.

    Read the article

  • Validate a URL string in my iphone app

    - by Derek
    Hi, I am getting really frustrated and I cant seem to check if the user has entered a valid url or not. This is what I have tried: NSString *str = [NSString stringWithFormat:@"%@", [myurl.text stringByAddinPercentEscapesUsingEncoding:NSUTF8StringEncoding]]; NSURL *aurl = [NSURL URLWithString:urlStr[; if(aurl == nil){ //Invalid url }

    Read the article

  • SMTP Mail client settings in app.config file C#

    - by Caveatrob
    I've put mail settings in app.config and can successfully pull them into a mailSettingsSectionGroup object. However, I'm not sure how to send a message using these settings. This is what I have so far: System.Configuration.Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); MailSettingsSectionGroup mailSettings = config.GetSectionGroup("system.net/mailSettings") as System.Net.Configuration.MailSettingsSectionGroup; What do I need to do next to use the mailSettings object?

    Read the article

  • ILMerge: How to configure the corresponding app.config

    - by rdoubleui
    I'm just trying ILMerge to merge my application and the needed libraries into one executable. I'm using the command line just to do some testing. I took a sample project: ilmerge /out:ProgramMerged.exe Program.exe Lib1.dll Lib2.dll This seems to work as intended. But what if I had a Program.exe.config? Is it still applicable? Does anybody how to achieve this?

    Read the article

  • Visual Studio 2010: highlight CSS text and comment

    - by pcampbell
    Consider a snippet of from a .css file in Visual Studio 2010 to be commented out. Normally Ctrl-E + Ctrl-C will comment your selected HTML and other source code. Highlighting CSS code results in: The key combination is bound to command (Comment Selection) which is not currently available. To comment CSS in Visual Studio 2010, is there a toolbar or keyboard shortcut to comment the highlighted text for you?

    Read the article

  • Git command to display HEAD commit id?

    - by Andrew Arnott
    What command can I use to print out the commit id of HEAD? This is what I'm doing by hand: $ cat .git/HEAD ref: refs/heads/v3.3 $ cat .git/refs/heads/v3.3 6050732e725c68b83c35c873ff8808dff1c406e1 But I need a script that can reliably pipe the output of some command to a text file such that the text file contains exactly the commit id of HEAD (nothing more or less, and not just a ref). Can anyone help?

    Read the article

  • For a .Net project, what file extensions should I exclude from source control?

    - by arame3333
    Everytime I start a project I have to think carefully about which files to exclude from source control. Has someone made a list of the criteria so I can look it up from the beginning? I work on my own so I have not got round to it. I appreciate that in the case of a DLL, you would want to include some and exclude others, so it is not just dependent on the file extension. My projects are ASP.Net, although a general discussion of other templates would also be useful.

    Read the article

  • ASP.net DAL DatasSet and Table Adapter not in namespace - Northwind Tutorial

    - by Alan
    I've been attempting to walk through the "Creating a Data Access Layer" tutorial found http://www.asp.net/learn/data-access/tutorial-01-cs.aspx I create the DB connection, create the typed dataset and table adapter, specify the sql, etc. When I add the code to the presentation layer (in this case a page called AllProducts.aspx) I am unable to find the NorthwindTableAdapters.ProductsTableAdapter class. I tried to import the NorthwindTableAdapters namespace, but it is not showing up. Looking in the solution explorer Class View confirms that there is a Northwind class, but not the namespace I'm looking for. I've tried several online tutorials that all have essentially the same steps, and I'm getting the same results. Can anyone give me a push in the right direction? I'm getting error: Namespace or type specified in the Imports 'NorthwindTableAdapters' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. I think I might need to add a reference OR they may be creating a separate class and importing it into their main project. If that's the case, the tutorials do not mention this. SuppliersTest2.aspx.vb: Imports NorthwindTableAdapters Partial Class SuppliersTest2 Inherits System.Web.UI.Page Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load Dim suppliersAdapter As New SuppliersTableAdapter GridView1.DataSource = suppliersAdapter.GetAllSuppliers() GridView1.DataBind() End Sub End Class

    Read the article

  • Can't start gdb.exe in Qt Creator

    - by Ben
    I have a project in Qt Creator that builds fine, but when I try to debug it I get this message: Adapter start failed Unable to start gdb 'C:\Qt\2010.02.1\mingw\bin\gdb.exe': Process failed to start: The directory name is invalid If I navigate to the debug build folder and directly run my compiled application, it will run fine, but obviously there's no debugging support. Additionally, gdb.exe is present at C:\Qt\2010.02.1\mingw\bin\gdb.exe, but Qt Creator can't seem to run it. How can I fix this problem?

    Read the article

  • AutoIncrement in SQLite with Subsonic 3

    - by Cooter
    This is probably a simple matter, but when I create a new object, the ID property starts off as 0 rather than null. As I understand it, SQLite takes/needs a value of null for the PK column to do the AutoIncrement. So the short question is how to get the ID in the object to start life as null? Thanks cooter

    Read the article

  • Reduce Mac OS X's Flash CPU usage

    - by elhombre
    I have been experiencing high CPU usage (138%) on my MacBook, while looking at flash videos on the internet with the Firefox browser. Mostly this usage makes itself noticeable by the loud noise of the fans and a hot MacBook which is very annoying for me. Does anyone know how to solve this problem or a workaround in of any kind?

    Read the article

  • Please explain this python behavior

    - by StackUnderflow
    class SomeClass(object): def __init__(self, key_text_pairs = None): ..... for key, text in key_text_pairs: ...... ...... x = SomeClass([1, 2, 3]) The value of key_text_pairs inside the init is None even if I pass a list as in the above statement. Why is it so?? I want to write a generic init which can take all iterator objects... Thanks

    Read the article

  • cross-platform frameworks for storage + metadata?

    - by Jason S
    I don't quite know what to use for terminology, so bear with me... Are there any cross-platform frameworks out there that facilitate a kind of "virtual file storage" to encapsulate adding files along with a database of metadata? I'm thinking about something along the lines of iTunes or iPhoto, where the program manages a whole bunch of files (in those cases audio or image files) and has a database of metadata so you can organize/find those files easily. I'd like to cobble together something along those lines for files in general. edit: I am hesitant to store files in a database alone, e.g. MySQL, as there would be potentially tens of gigabytes in my application (this issue has been mentioned in several SO posts, see this one that gives several links to others). I'm looking at CouchDB though and maybe it has promise....

    Read the article

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