Jump to content
Xtreme .Net Talk

PlausiblyDamp

Administrators
  • Posts

    7016
  • Joined

  • Last visited

Everything posted by PlausiblyDamp

  1. MyCommand.CommandText = "Select CategoryID, CategoryName, Comments from categories where CategoryID >0 order by CategoryName" daDataAdapter.SelectCommand = MyCommand daDataAdapter.Fill(dsDataSet) MyConnection.Close() Return daDataAdapter assuming you have set the connection up properly and assigned it to the command object the above code should work.
  2. C++ is not my strong point but shouldn't the Dll's header file include the relevant declarations to use it rather than you having to also declare the function prototype. Also have you called the __HrLoadAllImportsForDll function to actually load the DLL?
  3. If it's never needed outside of the control (or class) then a variable is fine. Advantages of properties include - you can provide only a get or set (to make a property read or write only) as well as both. Property gets can include calculations or further processing to return the data in the correct form, property sets can perform validation etc - this removes the need for calling code to always have to provide their own validation logic. If the internal representation of the variable changes (i.e. double to decimal, dates being UTC based to regional based etc) then the property can still function correctly without calling code having to be updated - just the property code will need to be modified.
  4. Have you installed the latest MDAC components? They should be on your Visual Studio CDs (the windows component update one) or you can get them Here
  5. What is the project? What does it do? Is it web based / n - tier / data driven? when you say huge - how huge are we talking? What are the reasons for moving from .Net?
  6. The filies need to be addressable from the client - you are redirecting them to another part of your website. Either move the files to a sub folder of your site or make the folder they are in another virtual directory and use that path.
  7. Can't think why it doesn't work then? Does the text box contain just the e-mail address? You may want to strip white space from the textbox to be on the safe side. public void btnSendEmail_Click(object sender, System.EventArgs e) { Process.Start("mailto:" + editEmail.Text.Trim()); }
  8. Sounds like a problem with Outlook not being properly registered on your PC. If you go to the start button, then run and just type mailto:somebody@somewhere.com what happens after you hit OK?
  9. public void btnSendEmail_Click(object sender, System.EventArgs e) { Process.Start("mailto:" + editEmail.Text); } will do the trick for you.
  10. Could you not make your class implement IDataAdapter instead then?
  11. How about using the IDataAdapter interface? IDataAdapter result = sqlDataReader; //or result = oleDbDataReader;
  12. In C# the assignment operator (=) cannot be overloaded. What are you trying to do? Is your class encapsulating the DataReaders and adding extra functionality?
  13. what error di you get using + instead of &? If you step through the code in the debugger what does "mailto:" + editEmail.Text equal?
  14. http://www.mentalis.org/classlib/index.php?category=Multimedia
  15. What code are you using so save / restore the form size from the registry?
  16. Err, ignore the last post completely. Try the following as an example System.Data.SqlClient.SqlCommand o = new System.Data.SqlClient.SqlCommand(); if (o.GetType() == typeof(System.Data.SqlClient.SqlCommand)) { MessageBox.Show("Fing"); }
  17. if(typeof(o) is System.Int32) { //whatever }
  18. You may be better of displaying the list of files in another control (ListView or Checked ListBox) for example. This will allow selecting files to be a bit easier - if people are using ctrl+click to select files 200+ individual selections could get tedious and error prone.
  19. Do you need to select that many files at once? Are they not organised into folders etc?
  20. Odd, just cut and pasted your code into a new web app and tested it with both IE an mozilla - IE looked fine, mozilla didn't. Saved the HTML source from IE - opened that in mozilla and it looked just like the IE version. If you move the colour, height and width into a CSS file as class and set the buttons up that way they look fine in IE and mozilla but not in the IDE.
  21. It pretty much works as you suggested - if you post a code sample or a tutorial / walkthrough into a regular forum then if it's suitable a moderator / admin will move the post to the correct place for you.
  22. you mean either the Tutor's Corner or the Code Library forums?
  23. Look here for a free .Net dll.
  24. I've never noticed validators not working in mozilla before. If scripting is disabled in mozilla then this will prevent the validators firing client side - on the server side button click you need to check Page.IsValid to ensure there are no problems. What version of mozilla are you using? Would it be possible to post your code to see if anyone can duplicate your problem? Also what OS are you running on?
  25. Not sure what you searched on to fail to find any reference but have a look Here
×
×
  • Create New...