in

ASP.NET Weblogs

Jason Nadal

Restless C#ding

April 2004 - Posts

  • Javascript Bad Math

    I really wish someone could explain to me how, in javascript, the following calculation happens:

    0.2320 * 100 = 23.20000000000003

    Check out the following script, which I only managed to fix by setting the precision of the offending result to 4 significant digits. The glitch can be seen with the following script:

    <html>
    <body> 
     <script language="javascript">
      var x = Number('0.2320');
      alert(x);
      var y = x*100;
      alert(y);
     </script> 
    </body>
    </html>

  • MVP Summit "Revealed"

    For those of us wondering just what was revealed about certain technologies at the MVP summit (in this case, windows mobile), PocketPC thoughts gives this article:

    http://www.pocketpcthoughts.com/index.php?action=expand,26847

    ...I was surprised to see an article like that after seeing screenshots and in-depth discussions about Windows Mobile 2003SE. Joking aside, the features of SE are pretty impressive.  In my opinion, it's worth it just for the landscape mode.  A brief overview is available here.

  • Longhorn RepeatButton Control

    So, while I was scanning throught the Longhorn SDK, I came across a rather interesting gem of a control: the RepeatButton. This control shares a parent, ButtonBase, with it's siblings, Button, CheckBox, HyperLink, and RadioButton.

    <RepeatButton Delay="100" Interval="100" Click="DoCount"
        DockPanel.Dock="Top"><Text>Count</Text></RepeatButton>

    What this bit of code does, is call the DoCount(object, ClickEventArgs) method every second, after a delay of a second. I imagine this could be used to do some very interesting things with animation....

    Posted Apr 08 2004, 09:18 PM by thejay2 with no comments
    Filed under:
  • VS2005 Newsgroups

    The public newsgroups for whidbey are at:

    http://communities.microsoft.com/newsgroups/default.asp?icp=whidbey&slcid=us

    Some good information in there, including groups for Generics, ObjectSpaces, and ASP.NET admin.

    Now if I could just get VS installed...

  • Announcing.... GetMyNews for Longhorn

    I would post a screenshot, but there's not much to see.  Rather, this is for your aural pleasure.  GetMyNews vA1 listens for any of a set of commands listed in it's its (and that's one of my pet peeves) grammar file, NewsCommand.grxml, and will go out and hit an rss feed provided by http://googlenews.74d.com .

    It will then read the headlines back to you text-to-speech style, while you can do other things.  It listens and speaks via the Longhorn speech API, and the code is provided as a download for those interested. This is among my first steps in my eventual goal of an interactive rss reading program that lets you do other things while you can request news and listen in the background.  Now that's multithreaded pc usage!

  • Audio Under Longhorn

    One of the questions I get asked most often about Longhorn is in regards to audio hardware.  1) What is a card that works under Longhorn, and 2) How do I get the drivers working?

    My only example is the Creative Sound Blaster Audigy 2, (Adam Hill reports that his SoundFusion GX270 functions as well.) a very common card, with varying options, including the platinum version with a drive bay with inputs (but I digress...). Strictly disabling an onboard soundcard is not enough for Longhorn to see the PCI slot card as primary.  On my system, running a dual-boot of Longhorn and XP, XP saw the correctly disabled onboard card, and enabled Audigy2 card as primary. Longhorn decided to try to use the disabled card, resulting in a very soft high-pitch sound out the spk-out jack of the Audigy, and no sound out the onboard card.

    To fix this, simply install the drivers by running setup off of the “Installation and Applications CD, ” but in compatability mode. To do this,

    1. right-click the setup.exe on the cd's root, and copy it.

    2. right-click on your desktop and paste a shortcut to the exe.

    3. right-click the shortcut, and go to properties. 

    4. click “Other Properties” on the left pane, and choose compatibility from the list.

    5. Check “Run this program in compatibility mode for:” and choose “Windows XP.”

    6. Run the shortcut, go through the install process and reboot (or just restart explorer.exe from task manager; it doesn't really require a reboot, although I bluescreened inbetween).

    Audio should be working just fine!

  • Back To Bloggin'

    After a long time off ...a few weeks of sparse posting, I'm back with some new posts. In case anyone was wondering, I had the opportunity to perform the Verdi Requiem at Carnegie Hall under Maestro Vincent La Selva and the New York Grand Opera Company.  It was a blast, but it's time that I got back to some development work.

    I have just had an article published on Developer.com about Databinding and the Avalon UI, and am looking forward to more work on the speech api.

More Posts