• 0

.NET Framework


Question

Recommended Posts

  • 0

This .NET Framework will be a pain in the A$$ at first, just like any update that needs bringing into the Windows Community, all Microsoft are trying to do is get it out to almost everyone in the world who owns a Microsoft PC. So soon everyone will have .NET Framework. Of course it's going to be a rough ride at first. Just like anything else ?_?

  • 0
This .NET Framework will be a pain in the A$$ at first, just like any update that needs bringing into the Windows Community, all Microsoft are trying to do is get it out to almost everyone in the world who owns a Microsoft PC. So soon everyone will have .NET Framework. Of course it's going to be a rough ride at first. Just like anything else ?_?

Quite true. Aside from the whole getting users to download it thing, there are other pains that go with .NET for the time being.

For one thing, it's not QUITE as Windows version-neutral as Microsoft would like everyone to believe. Some of my users using XP Home have had some significant problems with .NET code that runs perfectly fine on XP Pro.

And for another, there are a lot of really weird crashing bugs that pop up for no particular reason. For example, changing a selection in a list view will always throw an ArgumentOutOfRangeException. There's nothing actually wrong (you can catch the exception and discard it, and everything will work as it should), but it will still crash the app.

Once the minor stuff like that gets worked out, .NET will be a lot less painful.

--

Danny Smurf

  • 0

Danny, thats also quite true. But what I think Microsoft is trying to do, is get programmers to start getting used to the .NET functionality and the way .NET works, all for the release of Longhorn. Which I'm pretty sure will be using .NET Framework in it's coding. So I guess what Microsoft are trying to do is say "Get ready, look at whats coming"

  • 0
I KNOW that Longhorn's version of Explorer.exe is a .NET app. Play with the latest build and when it crashes, an unhandled .NET exception is displayed. Cool!

I think that's just the CLR debugger that has been integrated along with the normal JIT debugger. Try crashing another normal Win32 app and see if the same message appears as for the Explorer crash.

  • 0
I KNOW that Longhorn's version of Explorer.exe is a .NET app. Play with the latest build and when it crashes, an unhandled .NET exception is displayed. Cool!

Well, my suspicion is that explorer.exe is still same C++ code just with the "Use Managed Extensions for C++" option ticked on build... or maybe I'm totally wrong!

  • 0
I think longhorn is just an XP makeover right now, not hardly enough code to call it a .NET OS

It hardly has any managed code... to be a .NET OS, it should have at least 50%+ managed code... which it clearly doesn't.

But, we still see some shipping Microsoft apps with managed code- eg UUDI, XP Media Center, the Outlook BCM... which is pretty encouraging. And since WinFS is supposed to be based on Yukon, which is supposed to use .NET v2.0, then maybe WinFS will be written in managed code too!

  • 0
It hardly has any managed code... to be a .NET OS, it should have at least 50%+ managed code... which it clearly doesn't.

YET.

Don't forget, it's not even in the beta stage yet. And we don't know how much managed code is really in there. It may just have "the "Use Managed Extensions for C++" option ticked on build," but that would indeed make it managed code, since that will compile it to run on the .NET Framework. And that's all it takes to make a lot of programs managed. We have no idea how much of that Microsoft has done.

--

Danny Smurf

  • 0
And for another, there are a lot of really weird crashing bugs that pop up for no particular reason. For example, changing a selection in a list view will always throw an ArgumentOutOfRangeException. There's nothing actually wrong (you can catch the exception and discard it, and everything will work as it should), but it will still crash the app.

Hey Danny Smurf,

I read your post and checked out that behavior. The reason you're getting that exception is because the list view item that is being deselected is firing the event, as well as the item that is being selected. Just test the SelectedIndices.Count before you do anything.

private void listView1_SelectedIndexChanged(object sender, System.EventArgs e)
{
    if( listView1.SelectedIndices.Count < 1 )
        return;
    // other code

That is probably expected behavior since the event is firing when the index changes, just once for each item being selected and deselected.

Cheers!

  • 0
Having that option ticked doesn't mean it is managed code - it could see be using traditional C++, and not taking any advantages of the Managed Extensions.

It doesn't matter if it's written in "traditional" or not. Ticking that option compiles it to run on the Framework. The language it was actually written in is irrelevant. Managed code is "managed" because the CLR "manages" its execution.

--

Danny Smurf

  • 0
I read your post and checked out that behavior. The reason you're getting that exception is because the list view item that is being deselected is firing the event, as well as the item that is being selected. Just test the SelectedIndices.Count before you do anything.

Thanks for that. That's... rather odd behaviour. I'd think that the event should only fire once, since the selected index is only changing once (one unselect + one select = one change). I'll give that code you posted a try. Thanks. :)

--

Danny Smurf

  • 0
how many people actally have the framework? I mean it wasn't in windows xp but it came on on xp SP1 and it wasn't on windows 2000 sp3. How many people actually have the framework? If microsoft wants people to programme with .NET then they have some work to do...

I have it, it is on windows update, and I always install it after a clean install :p

2k3 is the only OS now to come with it atm :p

Before .net was final, the framework was 34mb, so they have improved it a lot :p

Test: .net framework

  • 0
It doesn't matter if it's written in "traditional" or not. Ticking that option compiles it to run on the Framework. The language it was actually written in is irrelevant. Managed code is "managed" because the CLR "manages" its execution.

--

Danny Smurf

I don't agree - if you are still doing all the memory allocation and other low-level activities yourself, then the CLR does much less and it's not really managed code.

  • 0
I don't agree - if you are still doing all the memory allocation and other low-level activities yourself, then the CLR does much less and it's not really managed code.

But you're not actually doing the memory management yourself any more. When a C++ project is compiled with managed extensions, it's subject to garbage collection just like every other program running on the Framework. The new calls allocate memory from the managed heap, just like new (or equivalent) does in all .NET languages, and the delete calls do the same thing as the Dispose method... everything except the actual memory reclamation.

As for the other "low-level activities," you can do most of them yourself in any .NET language, using Interop. Just because the ability to do low-level things is there does not mean that the app is no longer managed.

--

Danny Smurf

  • 0

From MSDN:

Compiling with the /clr option does not alter the semantics of an existing C++ program. For example, C++ classes do not become garbage collected or seamlessly interoperate with Visual Basic unless they are modified. Such features are only provided for Managed Extensions classes
  • 0

Not unless they've changed its classes to __gc classes or wrapped them in __gc classes, and made other modifications. I would think it would probably be easier and a better idea just to rewrite explorer and other shell features from scratch. It would more than likely eliminate some unknown security problems with the legacy code.

Edited by weenur
  • 0
Not unless they've changed its classes to __gc classes or wrapped them in __gc classes, and made other modifications. I would think it would probably be easier and a better idea just to rewrite explorer and other shell features from scratch. It would more than likely eliminate some unknown security problems with the legacy code.

*THWAPS his forehead* Of course, you're right. My bad. I forgot about switching the classes to __gc. Been spending a bit too much time in C# for the last year.

Which, unless I am mistaken, means that Explorer isn't managed code yet!

Well, we still don't know that, do we? I haven't seen the source code, and I'm willing to bet no one else outside of Microsoft has either. Maybe Microsoft has made all of the appropriate changes already, and Explorer is managed.

As for rewriting the shell from scratch... probably a good idea. Unlikely to happen. The shell isn't just explorer.exe. There are a lot of DLLs that go with the shell, which would also need to be rewritten. And since a good portion of the Windows API resides in those DLLs, changing or rewriting them breaks every app that depends on them (including any app that adds something to recent docs, any app which calls the Browse For Folder dialog, and any app that calls a SHGet function)... which is something I don't THINK Microsoft is going to do. They're including legacy graphics code for older apps in Longhorn, which means other legacy code (shell included) is probably staying as well, which probably means it's going to be impossible to completely scrap and rewrite any system-level components (shell included).

That is, unless Microsoft's got something huge up their sleeve that's going to fix the legacy problem.

--

Danny Smurf

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Got it. Seem like a good improvement. Thanks. But, before we "Add the source to Trusted Sites," how would know if it is trusted or not? Could get messy for not first Knowing" it is clean. See what I mean?
    • AB Download Manager 1.9.0 by Razvan Serea AB Download Manager is an open-source, feature-rich download manager designed to accelerate downloads, organize files efficiently, and provide seamless control over downloads. With support for multiple connections, resume capability, and an intuitive interface, it enhances the downloading experience for users seeking speed and reliability. The software integrates with various browsers, enabling quick link grabbing and batch downloading. It supports HTTP, HTTPS, and FTP protocols, ensuring broad compatibility with different file sources. Users can schedule downloads, set speed limits, and categorize files automatically for better organization. AB Download Manager is lightweight yet powerful, making it a great alternative to proprietary download managers. Its open-source nature allows developers to contribute, customize, and improve the software as needed. Whether you're downloading large files, managing multiple downloads at once, or seeking an ad-free experience, this tool offers a practical and efficient solution. Key features of AB Download Manager: Multi-Connection Support – Accelerates downloads by splitting files into multiple segments. Resume Capability – Allows paused or interrupted downloads to be resumed without starting over. Batch Downloading – Supports downloading multiple files at once for improved efficiency. Browser Integration – Captures download links directly from browsers for seamless operation. HTTP, HTTPS, and FTP Support – Ensures compatibility with a wide range of file sources. Download Scheduling – Enables users to automate downloads at specific times. Speed Limiting – Lets users control bandwidth usage for optimized performance. File Categorization – Automatically organizes downloaded files into designated folders. User-Friendly Interface – Simple and intuitive design for easy navigation. Cross-Platform Compatibility – Works on multiple operating systems. Ad-Free Experience – No intrusive ads or tracking for a clean user experience. AB Download Manager 1.9.0 changelog: Added Czech language support User-friendly error messages for download errors (#1252) An option to remember the last selected queue and quickly add downloads to it by long-clicking the Add button ( #1246) An option to export/import downloads using JSON format A Download button on the multi-download page for cases where users do not want to start downloads without queue processing (#1247) The app now includes a logger that can be enabled using a command-line flag (#1226) Startup errors are now logged automatically to help diagnose initialization issues Changed The default unqueued "Max Concurrent Downloads" value has been changed from "Unlimited" to 3 (This can be customized in the app settings) Improved Updated translations Added an indicator on the Android main page when resume is not supported (#1248) Extract the file name from the download link as a fallback when no response information is available (#1209) Minor UI/UX improvements Download: AB Download Manager 1.9.0 | Portable | ~80.0 MB (Open Source) Download: ARM64 | Portable ARM64 | Android Links: AB Download Manager Website | Github Page | Screenshot Get alerted to all of our Software updates on Twitter at @NeowinSoftware
    • I just started using Teams (and “New” Oiutlook) at work (instead of Slack) and both are truly abysmal pieces of software.
  • Recent Achievements

    • First Post
      DragonOfMercy earned a badge
      First Post
    • First Post
      bella52 earned a badge
      First Post
    • Reacting Well
      Techinmay earned a badge
      Reacting Well
    • Collaborator
      WndSks went up a rank
      Collaborator
    • One Month Later
      Sopa flores earned a badge
      One Month Later
  • Popular Contributors

    1. 1
      +primortal
      493
    2. 2
      PsYcHoKiLLa
      209
    3. 3
      +Edouard
      154
    4. 4
      Steven P.
      85
    5. 5
      FloatingFatMan
      72
  • Tell a friend

    Love Neowin? Tell a friend!