2,245 Posted Topics
Re: What do you mean by image processing? A photo editor or barcode recognition? "[URL="http://www.getpaint.net/"]Paint.NET[/URL]" was written entirely in .NET and I think the source code might be open as well. Check it out. | |
Re: [code=vb.net] Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click Dim drives As System.IO.DriveInfo() = System.IO.DriveInfo.GetDrives() For Each drive In drives Console.WriteLine(drive.RootDirectory.FullName) Next End Sub [/code] | |
Re: [code=vb.net] Dim someStr As String = "Select ""GL Setup"" From [My Table]" [/code] | |
Re: It sounds like your solutions file isn't being saved by the IDE. What you could do for development is something like: [code=csharp] public static string GetFileName() { #if (DEBUG1) return @"C:\blah.txt"; //dont need to use App.Path() #else return System.IO.Path.Combine(System.Windows.Forms.Application.StartupPath, "blah.txt"); #endif } [/code] | |
Re: [code=csharp] private static string BuildSqlNativeConnStr(string server, string database) { return string.Format("Data Source={0};Initial Catalog={1};Integrated Security=True;", server, database); } protected void Button1_Click(object sender, EventArgs e) { byte[] bytes = File.ReadAllBytes(@"C:\picture.bmp"); const string query = @"Insert Into Picture (Picture) Values (@Picture)"; using (SqlConnection conn = new SqlConnection(BuildSqlNativeConnStr("apex2006sql", "Bugs"))) { conn.Open(); using (SqlCommand cmd … | |
Re: Please attach the entire install.log | |
Re: This compares ARGB but you could change it to just use RGB: [code=csharp] using System; using System.Collections.Generic; using System.Drawing; using System.Drawing.Imaging; using System.Windows.Forms; namespace daniweb { public partial class frmScreenShot : Form { public frmScreenShot() { InitializeComponent(); } private void button1_Click(object sender, EventArgs e) { Point[] points = FindColor(button1.BackColor); System.Diagnostics.Debugger.Break(); … | |
Re: This question was covered extensively on an older thread: [url]http://www.daniweb.com/forums/thread209172.html[/url] | |
Re: Think of the encoding as how a character is stored. This article should help clear things up: [url]http://en.wikipedia.org/wiki/Comparison_of_Unicode_encodings[/url] | |
Re: Can you post the code that is not working properly? It is probably a good idea to post [b]all relevant[/b] code for the entire class. | |
Select One. I just spent about 3 hours deploying an ASP.NET application and it made me wonder what others think. | |
Re: [code=csharp] for (int i1 = 1; i1 <= 7; i1++) { MaskedTextBox[] tbList = (MaskedTextBox[])this.Controls.Find("textBox" + i1.ToString(), true); if (tbList.Length == 1) { MaskedTextBox textBox = tbList[0]; textBox.Text = i1.ToString(); } } [/code] | |
Re: What are you talking about? >>this open source thing I am using uses typical contains formsof inflections Open source ... database? Is this even MSSQL? >>However, it does not do partial word search. How do I incorporate wild-card search with contains formsof inflections? If what contains it? A file, a … | |
Re: [code=vb.net] Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click Dim strDir As String = "C:\testdir\" If (System.IO.Directory.Exists(strDir)) Then Dim dir As New System.IO.DirectoryInfo("C:\testdir") Dim files As System.IO.FileInfo() = dir.GetFiles() For Each file As System.IO.FileInfo In files System.IO.File.Delete(file.FullName) Next End If End Sub [/code] | |
Re: Try: [code=csharp] query = "Insert into testing values('" + txtEmpId.Text + "','" + txtEmpName.Text + "')"; query = "Insert into testing values('" + txtEmpId.Text + "','" + txtEmpName.Text + "')"; [/code] In C# you use [icode]+[/icode] to concatenate strings, not the VB [icode]&[/icode] operator. | |
Re: [QUOTE=thaldent;962467]My files were really mixed up, though I followed advice in "Using Windows XP" and put these in My Documents. I'm not sure all is now correct, but will follow along with that arrangement. Anyone that can advise on this?[/QUOTE] Who cares? Its your computer... put them wherever you can … | |
Re: Upload a sample project demonstrating this behavior | |
Re: Well there is a little bit of difference. First: [code=csharp] private void button1_Click(object sender, EventArgs e) { System.Diagnostics.Debugger.Break(); //Hit "step into" Ctors ct = new Ctors(); Console.WriteLine( "Instance: " + ct.aMemberField.ToString()); } } internal class Ctors { private int _aMemberField = 41; //set a breakpoint public int aMemberField { get … | |
Re: Try to boot off of a linux live CD like [URL="http://www.knoppix.net/"]knoppix[/URL] to eliminate the CD drive as a possible error. If you do boot off of the CD it should have some menu items that let you explore the drive partitioning -- or drive filesystem if it has been partitioned. … | |
Re: >>I want to find all the words in the text. (which seprate from each other with space). You changed the rules But to answer your question you can use RegEx: [code=csharp] private void button15_Click(object sender, EventArgs e) { const string sentence = @"This is Daniweb Forums.Good Luck"; string[] regex = … | |
Re: The fading is a system option for windows. The user enables/disables that for the entire system. Obviously having the fade decreases performance. Why are you trying to alter the default behavior of a form? Start -- Settings -- Control Panel -- System Select "Advanced" tab, then hit the "Settings" button … | |
Re: There is an article you can read on adding a spell checker in a rich edit: [url]http://www.c-sharpcorner.com/UploadFile/scottlysle/SpellCheckCC05152007084528AM/SpellCheckCC.aspx[/url] Read it and see if you have new insight on how you could move that over to a [icode]textBox[/icode] as well :P | |
Re: That requires full trust for your assembly in IIS on the hosting provider --- and for the very reason you're describing I don't know of many providers that allow it. I'm not sure you can get that to work. | |
Re: After you insert the record you can get the auto incremented record number by using: [icode]SCOPE_IDENTITY()[/icode] in MSSQL. Second this is a design change from what you have, but how it should work: Create a table in the MSSQL Database: [code=sql] Create Table YourTableName ( RecordId int, CustName varchar(50), Emailed … | |
Re: You have to use a trigger for this and not a constraint -- constraints can't check other column values. I tried the constraint approach and it did not work with referencing another column: [code=sql] IF OBJECT_ID('TempTable', 'U') IS NOT NULL DROP TABLE TempTable Create Table TempTable ( RecordId int identity(1000, … | |
Re: Shut the service down, grab your .mdf and .ldf files, and reinstall the service properly if you can't figure out the surface area configuration: [code] setup.exe /qb ADDLOCAL=SQL_Engine,SQL_Data_Files,SQL_Replication,Client_Components,Connectivity,SQL_SSMSEE INSTANCENAME=[COLOR="red"]@@InstanceName@@[/COLOR] SAVESYSDB=1 SQLBROWSERAUTOSTART=1 SQLAUTOSTART=1 AGTAUTOSTART=1 SECURITYMODE=SQL SAPWD=[COLOR="Red"]@@Password@@[/COLOR] DISABLENETWORKPROTOCOLS=0 ERRORREPORTING=1 SQMREPORTING=0 ADDUSERASADMIN=1 INSTALLSQLDIR="%ProgramFiles%\Microsoft SQL Server\" [/code] | |
Re: You need to set the data member's name. By default when you first fill a table it is named "Table" but this is unreliable. Try using this method: [code=csharp] private void Bind() { Query = "SELECT * FROM madExcept"; cmd = new SqlCommand(Query, conn); SqlDataAdapter da = new SqlDataAdapter(cmd); DataSet … | |
Re: Regarding your question about images please see this thread: [url]http://www.daniweb.com/forums/thread209172.html[/url] There are also a few other threads in the forum with the same question. I guess you guys are all in the same class? :P Regarding the large text you should use a [icode]varchar(max)[/icode] column to store the data. It … | |
Re: Can you upload a project demonstrating the difficulties you're having? I don't follow where you are going. If the DataTable contains all of the data and you want to show all of the data -- then problem solved, right? | |
Re: Why not make the "Options" a shared property that are updated application wide and create another class descending from the standard [icode]Form[/icode]? This is how I do form 'skinning' | |
Re: You should UrlEncode all data sent as part of the URL structure with [icode]HttpUtility.UrlEncode()[/icode]. This can be found in the [icode]System.Web[/icode] namespace. | |
Re: Are you wanting a default value based on the data in another table? If so use a trigger. If not then please clarify what you are asking | |
Re: Why don't you just install it properly to begin with? [code] setup.exe /qb ADDLOCAL=SQL_Engine,SQL_Data_Files,SQL_Replication,Client_Components,Connectivity,SQL_SSMSEE INSTANCENAME=[COLOR="red"]@@InstanceName@@[/COLOR] SAVESYSDB=1 SQLBROWSERAUTOSTART=1 SQLAUTOSTART=1 AGTAUTOSTART=1 SECURITYMODE=SQL SAPWD=[COLOR="Red"]@@Password@@[/COLOR] DISABLENETWORKPROTOCOLS=0 ERRORREPORTING=1 SQMREPORTING=0 ADDUSERASADMIN=1 INSTALLSQLDIR="%ProgramFiles%\Microsoft SQL Server\" [/code] | |
Re: [QUOTE=ryuslash;961039]There seems to be a Process.Exited event and also a Process.WaitForExit() function, maybe they could be of use?[/QUOTE] Yes, you hit the nail on the head. Call [icode]Process.WaitForExit();[/icode] after you have started the installer. It will block the thread until the PID dies so you will probably want to run … | |
Re: Can you post the create table statements with insert data? | |
Re: Please use code tags when posting on daniweb: [noparse] [code=c#] ...code here... [/code] [/noparse] Lastly this is a highly talked about topic called "scraping". If you google "C# Scraping" or "c# scrapers" you will find a lot of example projects that do exactly this. | |
Re: Welcome to daniweb! Please use code tags when posting code: [noparse] [code=csharp] ...code here... [/code] [/noparse] What event is the code you posted firing off in? You probably want to access the underlying datarow and not try to access the cell's repository editor. | |
Re: It looks like your project is set up using the .NET framework 1.1 and not the 3.5 framework. If you convert your project to a 3.5 application it should work | |
Re: Is this a separate process on your local machine, or a process on the remote machine? I'm not even sure if you're talking about two processes or a running process with multiple app domains or classes.... | |
Re: Yes you can use SQL Server 2005. Be sure to enable remote connections when installing it however. He is a good start on configuring all of the installation options: [code] setup.exe /qb ADDLOCAL=SQL_Engine,SQL_Data_Files,SQL_Replication,Client_Components,Connectivity,SQL_SSMSEE INSTANCENAME=[COLOR="red"]@@YourInstanceName@@[/COLOR] SAVESYSDB=1 SQLBROWSERAUTOSTART=1 SQLAUTOSTART=1 AGTAUTOSTART=1 SECURITYMODE=SQL SAPWD=[COLOR="Red"]@@PASSWORD@@ [/COLOR]DISABLENETWORKPROTOCOLS=0 ERRORREPORTING=1 SQMREPORTING=0 ADDUSERASADMIN=1 INSTALLSQLDIR="%ProgramFiles%\Microsoft SQL Server\" [/code] The fields … | |
Re: This should get you started: [code=vb.net] Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim txtString As String() = System.IO.File.ReadAllLines("C:\file.txt") Dim studentList As New System.Collections.Generic.Dictionary(Of Integer, Decimal()) For Each line As String In txtString If (String.IsNullOrEmpty(line)) Then Continue For End If Dim data As String() = … | |
Re: Are you using URL rewriting or forms authentication in your site? Please paste the _full_ exception message in code tags. | |
Re: I like the MSDN help files. They provide code snippets for just about everything you want to do. | |
Re: Please use code tags when posting on daniweb: [noparse] [code=language] ...code here [/code] [/noparse] Next -- Why are you accessing the MDF file directly? You should probably be accessing the SQL Server via Named Pipes which is a form of network communication. Unless you know why you want to access … | |
Re: Neither -- the background worker is destroyed when the form is disposed (assuming you have dropped a background worker from your toolbox on to the form). If you have declare the background worker as a member then you need to pop in to your designer file and add it to … | |
Re: What are you trying to do exactly? I think this is probably beyond the capabilities of the command prompt but can be done in C/C++. | |
Re: That sounds like a good idea. Did you have a question or just wanted another opinion on it? I haven't tried to use a trigger like that before and I don't know if the trigger will fire if the SQL Server detects that it is about to violate a UNIQUE … | |
Re: You will need to create a Service like the AntiVirus applications do and hook on to the outbound port you want to proxy. That is the only way to get *true* control of the applications. | |
Re: Are you browsing the site [url]www.imf.org[/url] when the error happens? Go to your command line and run an nslookup to see if your DNS is resolving properly on the machine. It should look like this: [code=dos] C:\Documents and Settings\scott.SCOTT>nslookup www.imf.org Server: dns.apexsoftware.com Address: 10.2.1.4 Non-authoritative answer: Name: www.imf.org Address: 204.180.229.21 … |
The End.