Jump to content
Xtreme .Net Talk

azae

Members
  • Posts

    18
  • Joined

  • Last visited

Everything posted by azae

  1. ok here is the code /// protected override void Dispose( bool disposing ) { if( disposing ) { if (components != null) { components.Dispose(); } } base.Dispose( disposing ); }
  2. Can anyone tell me what does it mean? It come out on Build Error Message.. after I press F5... C:\Project\FileCopier\Form1.cs(245): 'FileCopier.Form1.Dispose()' : cannot override inherited member 'System.ComponentModel.Component.Dispose()' because it is not marked virtual, abstract, or override How do I overcome it? So program can run smoothly
  3. Hello, I am actually want to do validation on combobox. It is like u make user must make choose one of the item from combo box before they procedd to do any other action like UPDATE, SAVE or DELETE. In textbox, we always use IF statement like if (textBox1.text == "") { //promt MsgBox ask user to input return; } So, how we do if it is comboBox. I also welcome anything similar, a least I can figure out an idea thanks
  4. thank for the help.. but combobox.SelectedItem do not have method called "Value" However, I managed get my things done while waiting for reply. Maybe I am still beginer, my coding is so messy. If possible in the future I might not want to use combobox anymore
  5. thanks for reply, but the problem is not on the combo_CaseNo.DataSet.......... the problem is on the query itself I tried the hard code the statement, the statement show SELECT ....... WHERE InvoiceNo="" which mean the invoice combo_CaseNo.Text or combo_CaseNo.Items have no value. This cause the query is not successful.
  6. try { string query1 = "SELECT DISTINCT CaseNo FROM ReceivingImport WHERE InvoiceNo='"+combo_Invoice.Items+"'"; SqlCeDataAdapter adapter = new SqlCeDataAdapter(query1,conn); DataSet dtSet = new DataSet(); adapter.Fill(dtSet,"ReceivingImport"); combo_CaseNo.DataSource=dtSet.Tables["ReceivingImport"]; combo_CaseNo.DisplayMember="CaseNo"; this code is C#. I am using combobox to do the selection. I tried all possible methods for object combo_Invoice. But none of them give the value of the string display on the selection. I even tried on text too. How can it be solve
  7. try { string query1 = "SELECT DISTINCT CaseNo FROM ReceivingImport WHERE InvoiceNo='"+combo_Invoice.Items+"'"; SqlCeDataAdapter adapter = new SqlCeDataAdapter(query1,conn); DataSet dtSet = new DataSet(); adapter.Fill(dtSet,"ReceivingImport"); combo_CaseNo.DataSource=dtSet.Tables["ReceivingImport"]; combo_CaseNo.DisplayMember="CaseNo"; this code is C#. I am using combobox to do the selection. I tried all possible methods for object combo_Invoice. But none of them give the value of the string display on the selection. I even tried on text too. How can it be solve
  8. Hi, I already read on Deploying .NET FAQ and leart how to do installation setup for normal windows application. The article is so detail and straight to the point. Now I wonder how to do for Smart Devices (non PC base) instead. I understand that I need to build .CAB files. There are 6 files altogether.... WHich 1? I am stuck here... helpp me!!!!
  9. hi all, I already know how to do the search function.. But I need to do a perfect one. here is my code which is working SqlCeCommand cmd = conn.CreateCommand(); cmd.CommandText = querySQL; SqlCeDataReader rdr = cmd.ExecuteReader(); while (rdr.Read()) { TXT_Description.Text = rdr.GetString(1); TXT_Something.Text = rdr.GetString(2); } cmd = null; rdr.Close(); so it will return TXT....Text whatever I want to know.. But how should I do if the data not found in the database? I want to place a message "Data Not Found" How to code?
  10. Ok I got it the temp is not NULL now. but statement temp.Replace("some",""); does not replace the string. suppose the file look like this ....... abc some thing sometimes ....... these some is not change at all. I tried it myself
  11. Thank for the reply Winston, I know what happen. In VS.NET we actually can see the value of the variable flow. Refer to dynamic sysop reply to me, the statement StreamReader sread = new StreamReader(FILE); string temp = sread.ReadToEnd(); variable temp is null. thats why the program do not run properly. Can this problem be treated? By right the temp variable should hold value which extract from the file in FILE value.
  12. Oops!...IOException occur Hi, I try to study both the code snippet and samples frm MSDN... After that, I try to do. But on the statement StreamWriter swrite = new StreamWriter(FILE, false, System.Text.Encoding.Default); swrite.Write(temp); swrite.Close(); it cause IOException error... How I deal with it? Is it solve using try...catch...finally? If it is, what should I put int try? catch? and finally?
  13. How u declare the fs instance? As far as I know, both write and read instance do not have method seek. All I want to do is actually delete the content of the file. Sorry for being so week in English, but I will improve soon. Thanks
  14. Hi All, I have manage to do the read file and write to file. But in C#.NEt, do we have delete specific string in the file? To be frank, I only done file delete in other language like C. I never done anything in delete string within file. I would be appreciated if someone could tell me how to do it C#,C and perhaps VB. Thanks :)>-
  15. Dear Forum, After I play around the .NET's pocket PC emulator. Now I am curious about creating a setup file to the device itself, not to the PC. How do u all do that? I look through MSDN and tried too. Now I really confuse on CAB files and .NET Framework 1.1... In the Add New Project Dialog as well, I not sean any thing mention 'Smart Device Application Setup' under Setup and Deployment Projects folder in Project Type menu. Thank you.
  16. Sorry its misconverzation there... Sorry Wile.. what I really mean in string manipulation is actually string modifier.... I programming c.. we write printf("%6d, 123"); so the output will be indent for 6 space to fit 123 I want to know how do we do that in C#. Books I have here does not mention about this... And the second thing is, is it the file system for pocket pc is the same as desktop pc? I tried to run on emulator which include in VS.NET. The program cause run time error.
  17. hi all, the last posting have solved by myself.. Now I am advancing to build program on smart device (pocket PC). Function I want to do now is write to text file again. Can I really declare my text file like this? string fileName = "c:\\delivery.txt"; System.IO.StreamWriter writer = new System.IO.StreamWriter(fileName,True); OK.. I been trying to find out the String manipulation too... Such in VB 6 there is Mid(0,hhh) to limit the string size. But How to do in C#?
  18. Hi, I am new in C#. I need to write my data to text file through my developed system. In VB 6, we have INPUT, OUTPUT and APPEND mode. How bout in C#? I need to write to new line each time the event in invoke without delete the original file or altered the existing file Please help me on APPEND mode... Someone in vb forum introduce me to come here....
×
×
  • Create New...