Jump to content
Xtreme .Net Talk

Squirm

Leaders
  • Posts

    186
  • Joined

  • Last visited

Everything posted by Squirm

  1. There are a few ways I am sure. One is DirectSound. The DX SDK has samples: http://msdn.microsoft.com/library/default.asp?url=/downloads/list/directx.asp
  2. http://www.xtremedotnettalk.com/showthread.php?s=&threadid=49500
  3. Show what you would do in C or Java because I really don't understand. You can add to loop counters - they are still regular variables.
  4. I use the MSDN library, the one which came with Visual Studio 6.0 and which is also available online : http://msdn.microsoft.com Also the API lists and guide from http://www.allapi.net and the API Viewer which comes with VB6.
  5. The reason people will recommend against a timer is it will usually cause the splash screen to be displayed for either too long or not long enough, both of which we want to avoid. The general procedure you should be using would be: Show splash form Load program objects Hide splash form To add a progressbar, you would update it after each individual program item has been successfully initialised.
  6. You can use the Win32 API function [api]PlaySound[/api].
  7. Private Sub btnCompute_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCompute.Click Dim number As Single Dim cost As Single number = Val(InputBox("Number of copies:")) If number <= 100 Then cost = 0.05 * number ElseIf number > 100 Then cost = 5.00 + (0.03 * (number - 100)) '<-- change End If txtTotcopies.Text = "The cost is " & FormatCurrency(cost) & "." End Sub
  8. System.Threading.Thread.Sleep(milliseconds)
  9. BT provide tutorials for setting up your webspace. Check my post further up this thread. For HTML/CSS/JS tips, I find http://www.htmlgoodies.com an excellent resource. I think you should worry about getting a site up and running before thinking about buying a domain name.
  10. http://www.btopenworld.com/create/webpage/
  11. This is a possible new feature already being discussed and debated by the staff. We will be implementing something to link threads to the poster's desired language. The Network forum is the correct one for your post. The Language Specific forums are really only for syntax questions and major differences between the languages.
  12. An in-depth description of the SystemParametersInfo function can be found here: http://www.mentalis.org/apilist/SystemParametersInfo.shtml
  13. This is not a jobs forum. Try somewhere like http://www.rentacoder.com
  14. Yes of course, you will need to use modulo arithmetic: Perhaps this then? Minutes = (Milliseconds \ 60000) Mod 60 Hours = (Milliseconds \ 3600000) Mod 24 Days = Milliseconds \ 86400000
  15. Squirm

    C# forum

    In most of the main forums, VB.Net, C#, and Managed C++ questions are asked interchangeably. For communications, whether in VB.Net or C#, use the Network Forum.
  16. Perhaps this then? Minutes = Milliseconds \ 60000 Hours = Milliseconds \ 3600000 Days = Milliseconds \ 86400000
  17. Something like this: For i = 0 To udtGradeScale.Length - 2 MsgBox(udtGradeScale(i).strGrades & " = " & udtGradeScale(i).intPoints.toString & " to " & udtGradeScale(i + 1).intPoints.toString) Next i i = udtGradeScale.Length - 1 MsgBox(udtGradeScale(i).strGrades & " = " & udtGradeScale(i).intPoints.toString & " and above")
  18. The sndPlaySound function is only for .wav files. You can use the mciSendString Win32 API function, or DirectSound, although this is overkill in many cases. Here is a good site for using MCI. The samples are VB6 but can easily be converted: http://www.geocities.com/smigman.geo/mci/mid.html
  19. Try this: lstPlaylist.Items.Add(i.ToString & ". " & txtArtist.Text & " - " & txtTitle.Text)
  20. For easier portability to C# I would think.
  21. That makes sense for a DELETE operation, and of course UPDATE and INSERT too. However, the DataReader is for reading data (SELECT operations), so RecordsAffected is useless here. :-\
  22. It's taken a bit of reworking, but it's going to make things a lot easier in the long run. Thankyou very much. :)
  23. After creating an OleDbDataReader by executing an OleDbCommand, how does one find out how many rows have been returned by the command? Failing that, is it possible to have the OleDbDataReader return to the first row after reading all the data? Obviously I can run the command again, but I'm hoping there is an easier way, as there was in ADO. Dim Reader As OleDbDataReader Dim RunCmd As New OleDbCommand(sCommand, Con) Dim i As Int32 Con.Open() Reader = RunCmd.ExecuteReader(CommandBehavior.Default) Do While Reader.Read i += 1 Loop 'Now have recordcount in i, but have to requery to get back to the first row! I did try the .RecordsAffected property, but that always returns 0, and according to the help, returns how many records were affected by an UPDATE INSERT or DELETE operation. This leaves me wondering why it is a property of the OleDbDataReader which is for reading data, not updating it (as far as I can tell). :confused:
  24. You have a recursive method which never stops! There is no need for recursion here. Sub CheckForFile() Do Until System.IO.File.Exists(strLookoutPath) Application.DoEvents() Loop PictureIsPresent() End Sub
  25. Winamp still has to rebuild the file when it wants to insert or remove data from the middle of a file. All applications do, it is the nature of our file system. There is no way to get around it.
×
×
  • Create New...