Jump to content
Xtreme .Net Talk

PlausiblyDamp

Administrators
  • Posts

    7016
  • Joined

  • Last visited

Everything posted by PlausiblyDamp

  1. Did you try the code from post 11? If so what failed - the sample you have posted differs from my sample.
  2. Could you post the relevant code (and maybe a sample of the generated html).
  3. Nullable types are of primary benefit when dealing with data bases - they will prevent you having to check every field in a datareader for null before assigning to a variable. Essential - probably not, convenient definitely. Generics give the ability to do strongly typed collections without having to inherit from one of the existing collection classes - this also removes the implicit use of object internally and the associated casting / boxing overheads. Although splitting designer generated code into another file is one use of partial classes it is not the only use. In a large development team it may be common for more than a single developer to be working on a single class - the current one class = one file model makes this tricky to deal with. Partial classes allow this split to be done with very little fuss or effort.
  4. How did you install the DLL to the server? IIRC you need to use either an installer package or use the installutil.exe to properly register the eventlog parts.
  5. Serials for what setup app?
  6. If you are running in a networked environment then SQL only needs to be installed on a server - not on each client PC. At the end of the day it has to be a trade of - if you need the extra features and power offered by a DB like SQL or Oracle then you have to accommodate the extra requirements and overheads. If you are after an easy deployment scenario then MS Access is a lot easier. What features do you specifically require that rule out Access?
  7. IIRC XML element names are not allowed to begin with a number - the framework is using the unicode escape sequence for the digit.
  8. Try Server.Transfer("WebForm2.aspx?T1=" & TextBox1.Text & "&T2=" & TextBox1.Text)
  9. Scrappy as hell ;) put seemed to work Color.Red.ToArgb().ToString("X").Substring(2); I really, really hope there is a better and cleaner way than that though ;)
  10. When you say what code are you using? What errors occur? It is a lot easier for people to help if you give code samples etc.
  11. What code are you using to add this? If you are implementing a text editor then you will probably find the TextBox / RichTextBox controls will start to get a bit cumbersome as a way to do both store and edit the text. You may want to look at some alternate storage ideas (arrays, lists etc) and only use the controls to display / edit the string. Clicky is probably worth a read as it does give some good explanations of various possible approaches.
  12. When you create the stream reader you can specify then character encoding to use rather than letting it figure it out by itself. Just look at the overloads for it's constructor.
  13. You could always hide the caption bar, remove the border and set the form's transparency colour to whateve colour you are using for the areas of the skin's bitmap that you do not want to display.
  14. You don't. Hashing is a one way thing - this aids security because nobody can get a password back from a hash. If someone enters a password you need to hash that and then compared the new hash against the stored hash.
  15. If you look at the generated script (or the interface to create it) you will see that it will script everything including the creation of the DB itself. Easiest way to run the script would be to just run the command line osql.exe tool and pass the script in as a parameter.
  16. You will need to use something other than a module, modules are designed to be shared / global. The methods I suggested before should cover your needs, if you have a problem with a specific piece of code not working then you might be better off posting that here to see if anyone can help.
  17. In enterprise Manager right click on the DB in question and go to the 'All Tasks' sub menu, click 'Generate SQL Script'.
  18. StreamWriter streamWriter = new StreamWriter(Response.OutputStream); streamWriter.WriteLine("Date : "); streamWriter.WriteLine("From : " ); streamWriter.WriteLine("To : "); streamWriter.WriteLine("Subject : "); streamWriter.Close( ); Response.AddHeader( "Content-Disposition", "attachment; Filename = test.txt"); Response.ContentType = "application/octet-stream"; Response.End();
  19. Check the return value of cmd.ExecuteNonQuery - it returns the number of rows modified, if 0 then no inserts took place.
  20. If you have access to Enterprise Manager it can generate a full script to recreate the database. Otherwise I would plump for the backup / restore option. From any valid SQL tool (e.g. Query Analyzer) you could always do a backup with something as simple as BACKUP DATABASE Northwind TO DISK = 'c:\nwind.bak' and restore with RESTORE DATABASE Northwind FROM DISK = 'c:\nwind.bak'
  21. Once you have the full path you coul just use the Path class to break it down. Dim FullPath As String Dim FileNameOnly As String If OpenFileDialog1.ShowDialog = DialogResult.OK Then FullPath = OpenFileDialog1.FileName FileNameOnly = System.IO.Path.GetFileName(FullPath) End If
  22. If the target computer has the .Net framework then the resultant .exe can be run on it, just the same as how VB6 applications required the VB6 runtimes to be installed.
  23. You may want to consider using Session variables or something similar Clicky may be worth a read
  24. If you step through in the debugger what is the value of txtReqDate?
  25. Which line is giving the error?
×
×
  • Create New...