Jump to content
Xtreme .Net Talk

PlausiblyDamp

Administrators
  • Posts

    7016
  • Joined

  • Last visited

Everything posted by PlausiblyDamp

  1. ALT+E would work - if you want CTRL+E you will need to set ashortcut key under the menu item's propoerties
  2. You could try something like sQueues.Initialize() and see if that helps...
  3. It's a known problem with the BlueVelvet theme, just change to a different theme in you user options. I personally quite like the lite with blue
  4. What kind of experience do you have in programing DirectX, DirectShow, VB / VB.Net / C#.
  5. What error does it give when it crashes the client?
  6. Could you not use the WebClient class and an XMLDocument instead of going through COM interop?
  7. Following may give you a pointer or two 'To retrieve text from clipboard Dim dobj As DataObject dobj = Clipboard.GetDataObject() Dim formats() As String = dobj.GetFormats(True) 'will get a list of supported formats 'if Text is supported then Dim s As String s = dobj.GetData("Text") 'To put text on clipboard dobj.SetData("Text", s)
  8. http://sourceforge.net/projects/nunit/ http://sourceforge.net/projects/nunitaddin/
  9. You really don't need to open and read the file twice - see my above post (1st sample) on how to do it opening the file only once. you could also use the split command to split the line you read in into it's seperate columns. dim vals() as string vals = line.split(" " ) 'will split on space 'based on your example earlier of a line being tod 89 64 'vals(0) would = tod 'vals(1) would = 89 'and vals(2) would = 64
  10. firstly names(i) = myreader.ReadToEnd() will read the entire file into the first item of the names array - probably not what you intended. Try something like... Dim myReader As System.IO.StreamReader Dim names() As String Dim i As Integer = 0 Dim line As String myReader = IO.File.OpenText("a:\name.txt") lstBox.Items.Clear() Do ReDim Preserve names(i) line = myReader.ReadLine names(i) = line If Not line Is Nothing Then lstBox.Items.Add(names(i)) i += 1 Loop Until line = Nothing although you may be able to do it easier using string.split Dim myReader As System.IO.StreamReader Dim names() As String Dim line As String myReader = IO.File.OpenText("a:\names.txt") lstBox.Items.Clear() line = myReader.ReadToEnd names = line.Split(Environment.NewLine) lstBox.DataSource = names although you may need to mess with the line.Split(...) bit to get the correct line terminator in.
  11. Could you post your existing code and the errors you are getting?
  12. If they could both be handled in the same class then that could be a cleaner solution. An alternative approach could be to define an interface for the Search method etc and have both the customers and suppliers classes implement it. Each would then have it's own code internal to the class but would expose a common interface for other functions to work with.
  13. Could you not just put the contents of each textbox as a parameter to the proc without worrying about each line? Or is there a problem when passing in multiple lines as a single parameter?
  14. Where is the connection string defined? You would probably be better off making the connection string a property of the class rather than using an override in this way.
  15. The procedure has only three paramters - correct? How many lines will the textbox have?
  16. some of these may help, but I warn you using C / C++ is nowhere near as easy as C# / VB for things like string handling. http://publications.gbdirect.co.uk/c_book/chapter9/string_handling.html http://www.cs.cf.ac.uk/Dave/C/node19.html http://inti.sourceforge.net/tutorial/libinti/stringhandling.html
  17. What does the parameter list for the stored proc look like?
  18. in the line Grades(g1, +g2) could you not just use Grades(g1, g2) also on the lines g1 = Start.Substring(12, 4) g2 = Start.Substring(16, 4) the variable Start doesn't appear to be initialized before you use it. and in strStudent(strLetterGrade) = varAverage strLetterGrade doesn't appear to be initalize either - as well as it being a string not an integer (as pointed out by IcePlug earlier) also not sure what If Grades(g1, +g2) \ 2 = varAverage Then varEveryonesGrade += varAverage varEveryonesGrade = Math.Round(varEveryonesGrade / sum) txtDsplyClsAvr.Text = "The class average is " & CStr(varEveryonesGrade) End If is doing at all and which line are you getting the Index out of bounds error? the variable sum only seems to be being used as a loop counter but is declared as a double - any reason why?
  19. How is it being stored in the database? Seperate fields per line? You can get at each line in the textbox through the lines property, each item in the collection is a seperate line from the textbox.
  20. When you are getting the error what is the value of varAverage?
  21. If you have Visual Studio installed there is a sample application under the name of 'WinForms-Threads-TCPListener' it is probably worth having a look at it's code.
  22. which line are you getting the error on? It looks like you need to split the line from the file into sperate parts before parsing into a double.
  23. Insttead of InStr and instrRev you could (in fact should) use string.IndexOf or string.LastIndexOf
  24. try declaring the method as shared. If that doesn't work could you post the code just before the error?
  25. http://www.xtremedotnettalk.com/showthread.php?s=&threadid=75448&highlight=control+array http://www.xtremedotnettalk.com/showthread.php?s=&threadid=75012&highlight=control+array http://www.xtremedotnettalk.com/showthread.php?s=&threadid=73387&highlight=control+array
×
×
  • Create New...