Daily Archives

Articles indexed Thursday April 15 2010

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

  • Rebol MSAccess ODBC: works with DNS connection but not with DNSLess Connection

    - by Rebol Tutorial
    I have tested the new free Rebol ODBC with MS Access after reading the doc here http://www.rebol.com/docs/database.html It works with ODBC DNS connection but when I tested with this DNSLess connection (MSAccess2003 file with MSAccess2007 installed): connect-name: open [ scheme: 'odbc target: join "{DRIVER=Microsoft Access Driver (*.mdb)}; " "DBQ=c:\test\test.mdb" ] It shows this error: >> connect-name: open [ [ scheme: 'odbc [ target: join "{DRIVER=Microsoft Access Driver (*.mdb)}; " [ "DBQ=c:\test\test.mdb" [ ] ** Access Error: Invalid port spec: scheme odbc target join {DRIVER=Microsoft Access Driver (*.mdb)}; DBQ=c:\test\test.mdb ** Near: connect-name: open [ scheme: 'odbc target: join "{DRIVER=Microsoft Access Driver (*.mdb)}; " "DBQ=c:\test\... >> >> Do you know why ? Thanks.

    Read the article

  • Deployment Setup (.Net) - Search target machine -> Registry search (64 bit)

    - by Joonas Kirsebom
    I have a windows installer project which installs some software (winform, service, mce addin). During the installation I need to search the machine for a registry key. This is done with with the "Launch Condition" - "Add Registry Search" (Deployment Project). I have filled out all the properties right, and checked against the regestry that the value actually can be found. The problem is that the "Registry Search" searches in the x86 part of the registry (HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\...) although my system is a x64 and the deployment setup is also set to x64. Does anyone know how to force the "Registry Search" to search the x64 registry? Or know about a workaround? The weird thing about this, is that Registry setting in the deployment setup is writing to the right registry (x64). My idea is that the "Registry Search" program is only developed to the x86 architecture, and therefore can't read the right registry. I found this article from microsoft, so it seams that they know about this problem. https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=110105&wa=wsignin1.0#details My system is: Windows 7 64bit Visual Studio 2008

    Read the article

  • Create ntp time stamp from gettimeofday

    - by krunk
    I need to calculate an ntp time stamp using gettimeofday. Below is how I've done it with comments on method. Look good to you guys? (minus error checking). Also, here's a codepad link. #include <unistd.h> #include <sys/time.h> const unsigned long EPOCH = 2208988800UL; // delta between epoch time and ntp time const double NTP_SCALE_FRAC = 4294967295.0; // maximum value of the ntp fractional part int main() { struct timeval tv; uint64_t ntp_time; uint64_t tv_ntp; double tv_usecs; gettimeofday(&tv, NULL); tv_ntp = tv.tv_sec + EPOCH; // convert tv_usec to a fraction of a second // next, we multiply this fraction times the NTP_SCALE_FRAC, which represents // the maximum value of the fraction until it rolls over to one. Thus, // .05 seconds is represented in NTP as (.05 * NTP_SCALE_FRAC) tv_usecs = (tv.tv_usec * 1e-6) * NTP_SCALE_FRAC; // next we take the tv_ntp seconds value and shift it 32 bits to the left. This puts the // seconds in the proper location for NTP time stamps. I recognize this method has an // overflow hazard if used after around the year 2106 // Next we do a bitwise AND with the tv_usecs cast as a uin32_t, dropping the fractional // part ntp_time = ((tv_ntp << 32) & (uint32_t)tv_usecs); }

    Read the article

  • Is there any way to create a dynamic list of strings (based on language) in XAML?

    - by Xin
    Just wondering if it is possible to dynamically create a list of strings in XAML based on language/culture? Say if user logs in as an English user it shows Client Name, Order Number... and if user logs in as a Polish user it shows Nazwa klienta, Numer zamówienia instead? I only know the hardcoded one like below: <System_Collections_Generic:List`1 x:Key="columnNameList"> <System:String>Client Name</System:String> <System:String>Order Number</System:String> <System:String>Date</System:String> </System_Collections_Generic:List`1>

    Read the article

  • Ubiquity CmdUtils.setSelection won't replace HTML

    - by Josh Timmer
    I'm attempting to write a Ubiquity command that allows you to replace a selected link or URL pointing to an image with that image itself. However, the CmdUtils.setSelection() function (documented here) seems to do nothing if any html tags are present in the selection, making it useless for replacing any links. When selecting plain text, it functions exactly as intended, replacing the text with an <img src="text"/> tag. Is there something I'm missing, or will this function simply not allow me to replace html? If the latter is the case, is there a function or method that will allow me to do this? Any other advice is welcome as well! CmdUtils.CreateCommand({ name: "fetch-image", author: {name: "Josh Timmer"}, license: "GPL", description: "Replaces links or URLs pointing to images with the image itself", help: "Highlight text or a hyperlink and execute this command", takes: {"image URL": /.*/}, _getImgUrl: function(itemIq) { if (itemIq.html.indexOf("<a ",0) < 0) return itemIq.text; var refPos = itemIq.html.indexOf("href=\"",0); if (refPos < 0) return "Error, no URL found!"; var startPos = itemIq.html.indexOf("\"", refPos); var endPos = itemIq.html.indexOf("\"", startPos + 1); startPos += 1; var url = itemIq.html.substring(startPos, endPos); return url; }, preview: function(pblock, input) { pblock.innerHTML = "Image URL: " + this._getImgUrl(input) + "<br/><br/><img src='" + this._getImgUrl(input) + "'/>"; }, execute: function img_insert(input) { CmdUtils.setSelection("<img src='" + this._getImgUrl(input) + "'/>"); displayMessage("Executed: " + this._getImgUrl(input)); } });

    Read the article

  • What useful GDB scripts have you used/written?

    - by nik
    People use gdb on and off for debugging, of course there are lots of other debugging tools across the varied OSes, with and without GUI and, maybe other fancy IDE features. I would like to know what useful gdb scripts you have written and liked. While, I do not mean a dump of commands in a something.gdb file that you source to pull out a bunch of data, if that made your day, go ahead and talk about it. Lets think conditional processing, control loops and functions written for more elegant and refined programming to debug and, maybe even for whitebox testing Things get interesting when you start debugging remote systems (say, over a serial/ethernet interface) And, what if the target is a multi-processor (and, multithreaded) system Let me put a simple case as an example... Say, A script that traversed serially over entries to locate a bad entry in a large hash-table that is implemented on an embedded platform. That helped me debug a broken hash-table once.

    Read the article

  • EDIT Control Showing Squares Instead Of Returns

    - by Nathan Campos
    I'm playing a little bit with PocketC by doing a simple text editor. But with this code to read and to display the contents of the file on the EDIT control: int filehandle; int file_len; string file_mode; initComponents() { createctrl("EDIT", "test", 2, 1, 0, 24, 70, 25, TEXTBOX); wndshow(TEXTBOX, SW_SHOW); guigetfocus(); } main() { filehandle = fileopen(OpenFileDlg("Plain Text Files (*.txt)|*.txt; All Files (*.*)|*.*"), 0, FILE_READWRITE); file_len = filegetlen(filehandle); if(filehandle == -1) { MessageBox("File Could Not Be Found!", "Error", 3, 1); } initComponents(); editset(TEXTBOX, fileread(filehandle, file_len)); } It's all ok, but my test file, now have returns: Hello, World! PocketC Test Of My Editor Then when I open this file on the editor, instead of returns, I just see two squares(that means that it's a unknown character for that control), but if I change the control to a STATIC, it does he returns ok, but I can't edit the text if I use a STATIC. Then I want to know what I need to do to do the returns instead of showing those squares.

    Read the article

  • Set the title of a UIButton with a single method invocation?

    - by Greg Maletic
    I'd like to set the title of a UIButton via code. I find myself having to call -[UIButton setTitle:forState:] for UIControlStateNormal, UIControlStateHighlighted, UIControlStateDisabled, UIControlStateSelected. And that doesn't even take into account all of the combinations of these states together. Needless to say, this is tiresome. Is there a single call I can make that will set one string as the title for all of the states? (Since, I assume that in 95% of the cases, that's the desired behavior?)

    Read the article

  • Is there a fast way to jump to element using XMLReader?

    - by Derk
    I am using XMLReader to read a large XML file with about 1 million elements on the level I am reading from. However, I've calculated it will take over 10 seconds when I jump to -for instance- element 500.000 using XMLReader::next ([ string $localname ] ) or XMLReader::read ( void ) This is not very usable. Is there a faster way to do this?

    Read the article

  • Membership Website - 6 Success Strategies to Implement

    Here are some strategies that have helped me create a highly profitable membership website and can help you do the same. Make your membership website a continuity program. Not all membership websites are continuity programs, some have a course format and have a distinct beginning and ending.

    Read the article

  • How can I equalize the heights of text input fields?

    - by David
    What is the best way to equalize the height of my <select..> elements and my <input type="text"..> elements? It's proving difficult because of differences in box-sizing models. Google Chrome's user agent stylesheet has this: select { -webkit-box-sizing: border-box; } ..whereas other text input fields use the content box model. Why the difference? Should I perhaps make all of my text-based input fields use the border-box model? BTW, I'm using standards-compliant mode (by using <!DOCTYPE html>).

    Read the article

  • How can I get it the Free Music Archive audio player or is there a better alternative?

    - by Dennis Hodapp
    I'm looking at free streaming audio players for web browsers that I can use in a project. I really like the audio player used on http://freemusicarchive.org/. Are they using an open source audio player and can I get a hold of it? Or is it closed source? Also if there are any open-source audio players that anybody knows about I'd love to know about them (preferable to have one with no flash). Last thing...is HTML5 going to be able to replace audio streaming players?

    Read the article

  • UIView's frame, bounds, center, origin, when to use what?

    - by Boon
    UIView has the concept of frame, bounds, center, and origin, and they all seem to be interrelated. Most of the time, I deal with frame when setting the position and size of a UIView (or subclass). I understand that the frame is using global coordinate system and the bounds is using coordinate of the local view (therefore it's x and y are 0, but not always), but it's still confusing to me when to use what. Question: Under what context (and what's the right time) the other properties (bounds, center, origin) should be used?

    Read the article

  • Custom whiteSpace using Haskell Parsec

    - by fryguybob
    I would like to use Parsec's makeTokenParser to build my parser, but I want to use my own definition of whiteSpace. Doing the following replaces whiteSpace with my definition, but all the lexeme parsers still use the old definition (e.g. P.identifier lexer will use the old whiteSpace). ... lexer :: P.TokenParser () lexer = l { P.whiteSpace = myWhiteSpace } where l = P.makeTokenParser myLanguageDef ... Looking at the code for makeTokenParser I think I understand why it works this way. I want to know if there are any workarounds to avoid completely duplicating the code for makeTokenParser?

    Read the article

  • gitosis did not generate projects.list automatically, gitweb can't work.

    - by Readon Shaw
    I setup a gitosis managed git server. git clone is ok. but when I set gitweb via gitweb.conf as below: $projectroot = "/srv/gitosis/repositories"; $git_temp = "/tmp"; $home_text = "indextext.html"; $projects_list = "/srv/gitosis/gitosis/projects.list"; $stylesheet = "/gitweb/gitweb.css"; $logo = "/gitweb/git-logo.png"; $favicon = "/gitweb/git-favicon.png"; Btw, the commet was deleted because of the special symbol # is using as bold prefix. "403 Forbidden - No projects found" is reported when I access gitweb through "http://localhost/cgi-bin/gitweb.cgi" I checked the projects.list file it is empty, is that the reason why gitweb access failed? what would be the correct content? can i add it manually?

    Read the article

  • ESXi 4.0 Licensing Limits

    - by Ramsey
    From what I understand, the software is free and you just need to register to remove the 60-day limitation. Does this mean I have to register every time I install ESXi on a new machine? Or can I use the same key for different ESXi 4.0 installations?

    Read the article

  • abstract class in C++

    - by Alexander
    I have a derived derived class from an abstract class. The code is below. I have a FishTank class which is derived from an Aquarium and Aquarium is derived from item. My question is that should I put the definition of virtual int minWidth() const = 0; in aquarium again or is the code below sufficient? class Item{ public: virtual int minWidth() const = 0; }; class Aquarium{ public: virtual int calWidth() = 0; // Pure virtual function. }; class FishTank : public Aquarium{ public: FishTank(int base1, int base2, int height); ~FishTank(); int calWidth(); int minWidth(); };

    Read the article

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