472 Posted Topics

Member Avatar for crazyboy

As pointed out, I believe you are looking for the [icode]OpenFileDialog[/icode] given the VB name you specified. Here is the basic setup and call for dialog: [code=csharp] string fileName; using (OpenFileDialog ofd = new OpenFileDialog()) { ofd.Title = "Select File"; ofd.InitialDirectory = "c:"; ofd.FileName = ""; ofd.Filter = "All Files …

Member Avatar for sanch01r
0
155
Member Avatar for coollife

First of all, I have noticed that you later reposted this problem you are having, which is not proper to do. I provided you with a reply in that repost about what I saw as a problem. Secondly, see my comments regarding your posts below: > actually storing the byte …

Member Avatar for DdoubleD
0
490
Member Avatar for coollife

In building your command ([icode]OleDbCommand cmd = new OleDbCommand("INSERT INTO song VALUES('1','" + buff + "')", mycon);[/icode]), you are implicitly converting "buff" (a byte array) to a string, which is not how you handle binary data and even if the cast was able to convert your entire byte array to …

Member Avatar for DdoubleD
0
246
Member Avatar for mimi8469

That's interesting, yesterday when I looked at this post the code was broken up into several blocks, but now it's all together?--weird. Anyway, I was wondering if you made any headway on this? Having never worked with the MP API and plugin, I hacked around a little and noticed that …

Member Avatar for mimi8469
0
129
Member Avatar for meaf

[QUOTE=meaf;1044501]i managed to add the node and move around one to another, now i am suppose to update the node but really don't have clue how to do that with GUI[/QUOTE] How is your "node" defined? We cannot really tell you how to interface it with the GUI without knowing …

Member Avatar for DdoubleD
0
95
Member Avatar for blur_guava

As you have already learned by now, naming conventions are completely voluntary unless you are constrained to adhering to a standard. IMO, and until you find yourself confined to such constraints, continue learning and adopting naming techniques as you go along. I would like to point out that consistency can …

Member Avatar for DdoubleD
0
149
Member Avatar for mkamioner

I saw on this calculation on the web, but I don't have a .dss file to test it with... [code=csharp] public static long GetDSSDuration(string fileName) { FileInfo fi = new FileInfo(fileName); long size = fi.Length; long length = (long)(((size * 1.1869) - ((size / 1054) * 210)) / 1054); if …

Member Avatar for DdoubleD
0
4K
Member Avatar for CyberPirate1

This will loop through all of the form's controls searching for the name of the control.... [code=csharp] private void button2_Click(object sender, EventArgs e) { for (int i = 1; i <= 3; i++) foreach (Control c in this.Controls) if (c.Name == "label" + i) c.Visible = true; } [/code]

Member Avatar for Geekitygeek
0
150
Member Avatar for cgyrob

[QUOTE=cgyrob;1031743]I am removing the orignal event handler before adding a new event handler so there shouldn;t be multiple handlers for each instance. [code=C#] else if (ControlType == "DropDown") { ... field_dropbox.SelectedIndexChanged -= new EventHandler(field_dropbox_SelectedIndexChanged); field_dropbox.SelectedIndexChanged += new EventHandler(field_dropbox_SelectedIndexChanged); ... [/code][/quote] In the above, I don't understand why you are removing …

Member Avatar for cgyrob
0
129
Member Avatar for SAINTJAB

Example of create table and ALTER table using the MySqlClient already mentioned: [code=csharp] public static void AlterTableExample() { string connStr = DbWrapper.TestDbWrapper.BuildConnectionString(DbWrapperType.MySql); string createStatement = "CREATE TABLE Test (Field1 VarChar(50), Field2 Integer)"; string alterStatement = "ALTER TABLE Test ADD Field3 Boolean"; using (MySqlConnection conn = new MySqlConnection(connStr)) { conn.Open(); // …

Member Avatar for Geekitygeek
0
514
Member Avatar for DdoubleD

Hello friends! I have some database tables that store Image/Bitmap as part of each record as a Byte[]. I also have method that loads all the tables records into a DataTable and I would like some suggestions on how I can get this Byte[] column in my DataTable to be …

Member Avatar for DdoubleD
0
266
Member Avatar for moorcroft

Just depends on how you want to handle it. If transferring information to caller as node's text, you can do a search of all nodes to find it: [code=csharp] TreeNode FindTreeNodeText(TreeNodeCollection nodes, string findText) { TreeNode foundNode = null; for (int i = 0; i < nodes.Count && foundNode == …

Member Avatar for DdoubleD
0
627
Member Avatar for TobbeK

If I have understood correctly, you are wanting to perform a paragraph split when it exceeds the page length? I don't have a direct answer for you and these pdf libraries/utilities generally have a learning curve associated with their lack of documentation, etc. However, you might want to consider alternatives …

Member Avatar for TobbeK
0
2K
Member Avatar for Natsu29

Not sure what you are looking for. Are you wanting to load a table from your database containing the names and their availability (all of info already in table) and then randomly select two names from the table data having records marked/flagged as available?

Member Avatar for Natsu29
0
136
Member Avatar for Moselekm

If the form's [icode]AcceptButton[/icode] property is set to other than "none", then the form will intercept the <RETURN> key and transfer control to the specified event... Check that the Form's property is not set: (eg. [icode]this.AcceptButton = this.button1;[/icode])--be sure to look in the form's designer.cs file...

Member Avatar for Geekitygeek
0
328
Member Avatar for dhana3
Member Avatar for sknake
0
117
Member Avatar for gretty

I don't know how this compiler compares, but I've heard about it and you can check it out if you desire: [URL="http://www.mono-project.com/CSharp_Compiler"]Mono C# compiler...[/URL]

Member Avatar for thines01
0
153
Member Avatar for briantrumpet

Setting the form's property [icode]this.MaximizeBox = false;[/icode] prevents the form from being maximized as far as I can tell. Are you saying this is not so in your case? Setting the form's property [icode]this.FormBorderStyle[/icode] to one of the fixed border styles will prevent it from being sizeable (eg. [icode]this.FormBorderStyle = …

Member Avatar for DdoubleD
0
1K
Member Avatar for venkates.99

This is a little confusing to me... What happened to venkates.99, who started the thread? I see vksingh.24 saying the problem is solved--are the two of you working as a team or something? If there is still a problem, let us know what it is because there is no uploaded …

Member Avatar for Geekitygeek
0
1K
Member Avatar for kool.net

Take a look at this link: [URL="http://jachman.wordpress.com/2006/09/11/how-to-access-ini-files-in-c-net/"]Sometimes you’ll find your self in a situation where you need to use outdated techniques in order to support outdated applications … That time you’ll recognize that .NET does not support INI Files anymore. ...[/URL]

Member Avatar for milosz
0
1K
Member Avatar for lukeser

[QUOTE] ...I went into SQL Server Management Studio Express and granted all privileges to the root user but still no luck.[/QUOTE] I think you might be mixing apples and oranges because you indicate you checked your permissions with "SQL Server Management Studio", but you are programmatically trying to create a …

Member Avatar for lukeser
0
6K
Member Avatar for benkyma

[QUOTE=benkyma;1036753]Ok, I figured out that the error was actually triggered further down the code. It seems none of my parameters are being added into the query. I'm going to post the rest in case anyone can see what is wrong with it... [CODE]OdbcCommand myCommand = myConnection.getCommand("INSERT INTO entries(text, name, screen_name, …

Member Avatar for benkyma
0
408
Member Avatar for bk_bhupendra

You can handle the close event on the form using the following event handler: [code=csharp] private void Form1_FormClosing(object sender, FormClosingEventArgs e) { if (DialogResult.No == MessageBox.Show("Exit without saving changes?", "Data Not Saved", MessageBoxButtons.YesNo)) e.Cancel = true; } [/code] The above event will be called whenever the [icode]Close()[/icode] method is executed. …

Member Avatar for Diamonddrake
0
3K
Member Avatar for yodito

If not required to use Array or ArrayList, I wouldn't use either. Use a typed list instead: [icode]List<>[/icode]. I would put the method outside of your Team class, but it really depends on where you intend to store your Team list or array. The best way to return an array …

Member Avatar for yodito
0
124
Member Avatar for DdoubleD

A few days ago I decided to install MySql v1.2.17 and I downloaded a client class library: MySql.Data.dll v5.0.9.0 (by MySQL AB). I included the client classes inside my wrapper class and had it creating, dropping, inserting, and deleting tables..., or so I thought. I guess I never actually looked …

Member Avatar for sknake
0
237
Member Avatar for ShailaMohite

Here is an example that uses a DataGrid, but it should give you a basis for starting or asking a more specific question: [URL="http://www.csharphelp.com/archives/archive236.html"]C# DataGrid with DataSet[/URL] Cheers!

Member Avatar for DdoubleD
0
76
Member Avatar for happygeek

Old fashion alarm clock for me. Pull out mechanism on the back to engage, placed across the room so I have to get out of bed to turn it off, and definitely no snooze. Using a snooze could be a subject for a whole new blog! However, if I had …

Member Avatar for iphone develop
1
324
Member Avatar for avirag

avirag, I don't know how to get the control to display exactly how you want. The view set to detail gives you the single column list (what you have now), but I don't know how to cause it to draw left instead of center. The largeicon view will give you …

Member Avatar for sknake
0
134
Member Avatar for qldrobbo

Have never tried doing that, but here are some interesting links I found while reading up on the subject: [URL="http://www.microsoft.com/Sqlserver/2005/en/us/notification-services.aspx#obtain"]Notification Services...[/URL] [URL="http://www.sqlservercentral.com/scripts/Miscellaneous/31899/"]Send SMS from a Trigger...[/URL] [URL="http://msdn.microsoft.com/en-us/library/aa260689(SQL.80).aspx"]xp_cmdshell...[/URL]

Member Avatar for qldrobbo
0
117
Member Avatar for nccsbim071

[QUOTE=nccsbim071;1032929]how can we solve the problem of 32/64 bit platform and if they if have different cpu as X86 or x64,[/QUOTE] As I understand it, unless you target specifically for the x64 processor, you really don't need to worry about whether your app will be running on x86 or x64 …

Member Avatar for nccsbim071
0
417
Member Avatar for beginerC#
Member Avatar for AnkitKumar

You cannot directly call a trigger from C#. What you might be able to do is: 1) Separate your trigger code into a stored procedure that can be called by the trigger, and also by the application (c#). 2) Do something from the application that would cause the DB to …

Member Avatar for AnkitKumar
0
4K
Member Avatar for help-me-please

[QUOTE=help-me-please;1033568]Hi Guys I was wondering if anyone could assist me by telling me / correcting my code as to where I am going wrong. I'm trying to simply excute flvmeta.exe, and pass the parameters: "flvmeta input.flv output.flv" when I do this manually it works fine, however when I build and …

Member Avatar for mikiurban
0
127
Member Avatar for jejannah
Re: hi..

Are you sure you mean GroupBox? Other than serving to group other controls (encompass, contain), and especially RadioButtons as ddanbe pointed out, I don't know how you would use a GroupBox the way you describe. Changing the GroupBox.Text is easy though: [icode]groupBox1.Text = "My GroupBox Text...";[/icode] As far as the …

Member Avatar for DdoubleD
0
148
Member Avatar for LennieKuah

Please use code tags: &#91;code=csharp&#93; ...code here.... &#91;/code&#93; I don't think your code will compile. [icode]DataGrid.CurrentCell[/icode] is a property, not a method... Did you just copy and paste that event handler (DataGrid_Click), or did you use the designer to create it? You can access those text values using the object …

Member Avatar for LennieKuah
0
167
Member Avatar for LucerinRed

The jpg I looked at seems like it would be more suited for a DataGridView with a DataTable as its DataSource. Why have you chosen to use a ListView?

Member Avatar for DdoubleD
0
153
Member Avatar for styles_p

See MSDN documentation for more details: [URL="http://msdn.microsoft.com/en-us/library/system.windows.forms.datagridview.cellcontentclick.aspx"]CellContentClick[/URL] EDIT: Removed code that didn't work!!!--sorry, I should have ran it first.

Member Avatar for DdoubleD
0
180
Member Avatar for mcmillan0520

Nothing obvious standing out that I can see. What happens if you comment out that log.wtl("...") statement? Also, if there are other locations in the code where these Settings members or CheckBox.Checked states get modified, I would watch out for that too.

Member Avatar for DdoubleD
0
176
Member Avatar for avirag

Not sure if this is what you are looking for and I didn't test this, but it should work OK: [code=csharp] void ReorderItemToTop(string name) { // Locate item beginning with name's text... ListViewItem item = listView1.FindItemWithText(name); // If exact match, move it to the top of the List... if (item …

Member Avatar for abc16
0
244
Member Avatar for basma.lm

Here are a couple of SQL reference sites you may want to bookmark: [URL="http://www.1keydata.com/sql/sql.html"]1keydata.com[/URL] [URL="http://www.w3schools.com/SQl/default.asp"]w3schools.com[/URL]

Member Avatar for DdoubleD
0
86
Member Avatar for Voulnet

To clarify, are you wanting to change these keys for the system, or just within/for your running application?

Member Avatar for Voulnet
0
160
Member Avatar for kool.net

Here is an example of capturing the KeyDown and KeyPress events for a textbox to limit numeric input. You could also modify this logic to accept only the characters you want: [URL="http://msdn.microsoft.com/en-us/library/system.windows.forms.control.keydown.aspx"]Limiting input in control...[/URL] In addition to the examples sknake gave you, you might want to read up on …

Member Avatar for avirag
0
143
Member Avatar for saj_amo

Is this what you are looking for: [icode] dateTimePicker.Value.AddDays(2.0);[/icode]

Member Avatar for saj_amo
0
93
Member Avatar for crazyboy

Why do you care what method/step the user uses to close your application? I see this type of question a lot, and it's generally due to overlooking the behavior of the [URL="http://msdn.microsoft.com/en-us/library/system.windows.forms.form.closing.aspx"]Form.Closing event...[/URL], which is a cleaner approach in my opinion. If the user needs to save data or something, …

Member Avatar for crazyboy
0
154
Member Avatar for Geekitygeek

Or even a dropdown TreeView connected to a TabControl that drives the tab page selection based on the level of drill-down...

Member Avatar for Geekitygeek
0
197
Member Avatar for suncity

Have you tried googling "midi c#"? There is a lot of stuff out there--not sure if there is anything specific you are looking for...

Member Avatar for suncity
0
71
Member Avatar for samehsenosi

It sounds like you need to set the report's connection info for each of the tables. Try passing in the ReportDocument to this after you have set the table parameters, but before attempting to run/view the report: [code=csharp] public static void ReportSourceSetup(ReportDocument crDoc, ConnectionInfo crConnectionInfo) { // Each table in …

Member Avatar for DdoubleD
0
145
Member Avatar for Mitja Bonca

If you set the [ICODE]comboBox1.SelectedIndex[/ICODE] to a value, it will call the event handler automagically...

Member Avatar for DdoubleD
0
90
Member Avatar for zzbottom

Please use code tags: &#91;code&#93; ...code here.... &#91;/code&#93; Your logic flow is a little weird to me. Shouldn't you just ask all the questions up front, then use their input in the if statements, verses checking this and asking that, etc.?

Member Avatar for Geekitygeek
0
98
Member Avatar for Mitja Bonca

Check the value of your [icode]comboBox1.SelectedItem.ToString()[/icode]. My guess it isn't what you think: "*.doc". Have you defaulted the selection before using (eg. SelectedIndex = 0)? Also, you can just use the ComboBox.Text Property to access the selected item's text as displayed in the combobox.

Member Avatar for Mitja Bonca
0
122

The End.