Jump to content
Xtreme .Net Talk

divil

*Gurus*
  • Posts

    3026
  • Joined

  • Last visited

Everything posted by divil

  1. Check out the SystemEvents class.
  2. I would guess this is something to do with daylight savings time. Although the forum claims to be on GMT (to me) we're actually on BST (British Summer Time) at the moment with is +1 hour.
  3. I didn't notice you were in the UK. The best webhost (in terms of bandwidth, support and reliability) in the UK is Fasthosts. Their new shared hosting architecture is based on Windows Server 2003 and they now support the .NET framework too. If you're looking for something cheap though, look elsewhere.
  4. A content management system.
  5. Anti-ms propaganda kind of loses any impact it might have had when it's posted on a forum devoted to developing with a platform MS invented ;)
  6. Protected means you can only call it from _within_ a derived class. So you'll have to derive from Panel yourself and use SetStyle in the constructor, ideally. It's also a good idea to wrap your existing drawing functionality in the class too, it promotes encapsulation of code.
  7. di = new System.IO.DirectoryInfo(path); if ((di.Attributes & System.IO.FileAttributes.System) != System.IO.FileAttributes.System) System.Diagnostics.Debug.WriteLine(path);
  8. You need to modify your sub main (or create one if you don't already have one) and use Application.Run() (note no parameters) to start an application-wide message loop that isn't dependant on any one form. The default behaviour is to have your message loop based on a main form, and therefore it shuts down when that form does. This will solve your problem, but introduce a new one - when you have a message loop that doesn't depend on one form, you must then manually call Application.Exit() when you really do want your application to close.
  9. You have to create one from scratch.
  10. Strict's solution does the same thing, only far more elegantly (no focus issues) :)
  11. Am I missing something? I don't remember VB6 listviews being able to show icons in subitems either. ListViews in .NET can have custom sorters associated with them to compare two values, as I recall. Take a peek at the ListViewItemSorter property.
  12. One thing to note is that wouldn't quite work if you had Option Strict on (which you should ;)), instead it's good practice to explicitly cast to the frmMain type when you need to: frmParentForm = DirectCast(Me.MdiParent, frmMain)
  13. That's really weird. I get that behaviour too, even using StringBuilder to concatenate text. I was half thinking I wouldn't be able to reproduce it because I'm using VS.NET 2003, but I am. If I try and concatenate the string using the command window however, it works. It would be worth a post in the newsgroups to see what MS says about it.
  14. I'm afraid DX9 video is beyond the scope of my knowledge, but if you can catch the form's LocationChanged event and force a refresh of the video location somehow that ought to do the trick.
  15. Yes, constants defined as 0xvalue in C are equivalent to &Hvalue in VB. | is a bitwise OR operator in C, used to combine values. The VB equivalent is Or. || is a logical operator, the VB equivalent is also Or (behaviour depends on context) && is logical And in both.
  16. If you are creating instances on the fly like this you have to store them somewhere before you'll be able to go back and use them again. There are a multitude of collection classes in the framework, take a peek at the System.Collections namespace. ArrayList would probably suit you fine. With Option Strict on you will have to explicitly cast when you get objects out of the collection, to avoid this you can inherit from CollectionBase and make you own strongly-typed collection, but it's not essential. Remembed that objects created at runtime don't have names.
  17. I wouldn't have thought so but then, anything is possible. When I installed .NET 1.1 I lost all the documentation support in VS.NET 2002 and the .NET 1.0 SDK. These things happen. I'd give reinstalling it a shot.
  18. I intend to join Bill and his crew as soon as they contact me with an offer :P
  19. 1) You populate your treeview with the drives, not the folders within them. You should only attempt to get the list of folders within when the user actually clicks on them, like explorer does. 2) You need to examine the attributes of each folder as you process it, and simply don't show ones with the System or Hidden attributes.
  20. Well yes, it does help. There isn't likely to be any vb.net sample code that does it so you might have to put in the effort and port it.
  21. Presumably the images already _are_ in an Image class, I don't understand what you're saying you had to do.
  22. Actually come to think of it, that is what I had to do. I was thinking of testing a control in a form in the same project as the control. I did have to add the control to the toolbox in the test project, from the compiled version. The problem you're having may be because the build order of your projects isn't right. You need to right-click your solution node and choose Project Dependancies. You have to indicate that your test application is dependant on your control library so the control library gets built first.
  23. Textboxes are meant to display textual data, not binary. There is a hex viewing control in the framework that would probably be more suited to this task. Try using a different encoding to read the data, ASCII I believe doesn't understand characters over 127.
×
×
  • Create New...