2,245 Posted Topics

Member Avatar for Alba Ra

Can you upload your project? You can .ZIP it and attach it to the thread by clicking the "Go Advanced" button.

Member Avatar for Alba Ra
0
425
Member Avatar for Learning78

Try this: [code] Public Class frmRandom Dim lst As List(Of Integer) Private Sub ResetQuestions() If (lst Is Nothing) Then lst = New List(Of Integer) End If lst.Clear() Dim i1 As Integer For i1 = 1 To 100 lst.Add(i1) Next End Sub Private Function GetNextQuestion() As Integer If (lst.Count = 0) …

Member Avatar for Learning78
0
164
Member Avatar for Geekitygeek

No, that is a perfectly acceptable (and good) way to go about it. Its the easiest way to do a strongly-type mapping like you require in this case.

Member Avatar for Geekitygeek
0
194
Member Avatar for frankycool

You need a robot. They would need to open the door, walk in, wait for a table, sit down, eat an appetizer... etc. I don't know how you're going to do this with a shell script.

Member Avatar for sknake
-1
127
Member Avatar for Mongz

Do you receive an error or does it just say failed login? Also have you ran the SQL Server Profiler to see if the query is being executed? This sounds more like an ASP.NET question than an SQL question.

Member Avatar for Nomadz
0
99
Member Avatar for Link82

Are you open to suggestions for another design or does it have to be this way? That is going to be a mess to maintain....

Member Avatar for Link82
0
143
Member Avatar for MxDev

It helps organize or flag members of a class. If you're serializing a class you may want to mark the members you want to include in serialization with an attribute, or maybe your logic serializes all public members and you only want to ignore certain members with the [icode]XmlIgnore[/icode] attribute. …

Member Avatar for sknake
0
107
Member Avatar for A.Najafi

Also take a look at: [url]http://www.daniweb.com/forums/thread209516.html[/url] [url]https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=481906[/url] There are some bugs when using Right-To-Left forms that Microsoft has acknowledged but does not plan on fixing.

Member Avatar for sknake
0
124
Member Avatar for MxDev

Why not just show it modally? [code] private void button1_Click(object sender, EventArgs e) { using (frm1 frm = new frm1()) { frm.ShowDialog(); } } [/code]

Member Avatar for sknake
0
110
Member Avatar for ritu verma

1) Yes. You can store it in a library if it is versatile enough where it is reasonable to assume that you could benefit from using it in 2+ projects. 2) What do you mean? Cookies maintain a session ID on the client end so it remembers the ID but …

Member Avatar for sknake
0
74
Member Avatar for jaadu

[code] private void button6_Click(object sender, EventArgs e) { int i1; int i2; if (int.TryParse(textBox1.Text, out i1) && int.TryParse(textBox2.Text, out i2)) { int sum = i1+i2; textBox3.Text = "The sum is " + sum.ToString(); } } [/code]

Member Avatar for sknake
0
59
Member Avatar for sakhi kul

Here is an example: [code] private void button6_Click(object sender, EventArgs e) { int i1; int i2; if (int.TryParse(textBox1.Text, out i1) && int.TryParse(textBox2.Text, out i2)) { int sum = i1+i2; textBox3.Text = "The sum is " + sum.ToString(); } } [/code]

Member Avatar for sknake
0
95
Member Avatar for megha.jain08

[code] cmd = new SqlCommand("update toys set type=@type,item=@item,quan=@quan,price=@price,tid=@tid [COLOR="Red"]where s_no=@s_no[/COLOR]", con); [/code]

Member Avatar for sknake
0
95
Member Avatar for lil_Is

I think you mean 'extract' the numbers? If so: [code] Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim i1 As Integer For i1 = 0 To TextBox1.Text.Length - 1 If (Char.IsNumber(TextBox1.Text(i1))) Then TextBox2.Text += TextBox1.Text(i1) End If Next End Sub [/code]

Member Avatar for sknake
0
98
Member Avatar for Ichibang

Make sure you call .BeginEdit() when you start to edit data and call .EndEdit() before you update the table adapter. Sometimes that will cause values to be lost.

Member Avatar for sknake
0
2K
Member Avatar for sonial8

What happens if the date is '2009-08-01', does it go back to 7/30 or does it go to 8/30?

Member Avatar for sknake
0
119
Member Avatar for cavpollo

Please use code tags when posting code on daniweb: [noparse] [code=c#] ...code here... [/code] [/noparse] Also please direct ASP.NET questions to the [URL="http://www.daniweb.com/forums/forum18.html"]ASP.NET Forum[/URL] Post the contents for the master page and the content form for the master page. That is a rather odd error because the content place holder …

Member Avatar for sknake
0
105
Member Avatar for serkan sendur
Member Avatar for Twyce

Ryshad: I don't agree with that approach, you should always go to the source to check for values. If not you leave an opportunity for the values to become desynched and it will load to a bug. It will probably work 99.9% of the time but that other 0.1 bothers …

Member Avatar for Geekitygeek
0
143
Member Avatar for wil0022

You can use LINQ too! [code] using System; using System.Collections.Generic; using System.Text; using System.Linq; namespace daniweb.console { public static class Main5 { public static void Main() { List<int> lst = new List<int>(); Console.WriteLine("Enter 10 numbers"); while (lst.Count < 10) { Console.Write("Enter number #[{0:F0}]: ", lst.Count + 1); int i; if …

Member Avatar for Geekitygeek
0
113
Member Avatar for xtremebeauty

[QUOTE=ddanbe;997922]Hi, working all summer on your project? [/QUOTE] Haha.. you're killing me today. Thats your second post in the last hour that made me laugh and irritated my cough :P It seems he has been working on it a while: [url]http://www.daniweb.com/forums/thread226118.html[/url] [url]http://www.daniweb.com/forums/thread198070.html[/url] [url]http://www.daniweb.com/forums/thread198064.html[/url] [url]http://www.daniweb.com/forums/thread197560.html[/url] [url]http://www.daniweb.com/forums/thread196576.html[/url] [url]http://www.daniweb.com/forums/thread196575.html[/url]

Member Avatar for Geekitygeek
-2
258
Member Avatar for NT.

This is an odd task. As danny pointed out the generic list is definetly the way to go! You could do something like this: [code] using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.IO; namespace daniweb { public partial class frmWeirdHomework …

Member Avatar for Antenka
0
216
Member Avatar for mansi sharma

>> 1)What are different types of Cursors? [url]http://www.databasejournal.com/features/mssql/article.php/1439731/Using-SQL-Server-Cursors.htm[/url] >> 2)What are diff types of locks? [quote] <table_hint> ::= [ NOEXPAND ] { INDEX ( index_value [ ,...n ] ) | INDEX = ( index_value ) | FASTFIRSTROW | FORCESEEK | HOLDLOCK | NOLOCK | NOWAIT | PAGLOCK | READCOMMITTED | …

Member Avatar for sknake
0
153
Member Avatar for Geekitygeek

Can you post your code? This probably depends on the implementation of scrollbars in the panel

Member Avatar for Geekitygeek
0
722
Member Avatar for kneiel

Use -i for in-place replacement and do this: [code] sk@sk:/tmp$ cat >> file << _EOF_ > line1 > line2 > line3 > line4 > line5 > _EOF_ sk@sk:/tmp$ sed -i '3 s/.*/Your Replacement Here/g' file sk@sk:/tmp$ cat file line1 line2 Your Replacement Here line4 line5 sk@sk:/tmp$ [/code] Notice the [icode]sed …

Member Avatar for cfajohnson
-1
88
Member Avatar for ddanbe

Yeah I submitted a bug report to Microsoft and they confirmed it was a bug, but not important enough to fix. :(

Member Avatar for ddanbe
0
232
Member Avatar for Ancient Dragon

[QUOTE=Ancient Dragon;980879]IMO code snippets should be code that requires mod approval to get posted. I saw nothing wrong with it they way it was before -- at least everyone knew where to find them.[/QUOTE] I liked it the way they were where they had their own section. I don't know …

Member Avatar for Dave Sinkula
0
352
Member Avatar for samehsenosi

[URL="http://support.microsoft.com/kb/914277"]How to configure SQL Server 2005 to allow remote connections[/URL] [URL="http://www.linglom.com/2009/03/28/enable-remote-connection-on-sql-server-2008-express/"]Enable Remote Connection on SQL Server 2008 Express[/URL]

Member Avatar for samehsenosi
0
145
Member Avatar for globalizard

Make a copy of your access database, truncate the tables, add a test row in each table, and upload the database.

Member Avatar for sknake
0
207
Member Avatar for MxDev

Why don't you call [icode]Process.Start()[/icode] and create a new instance? I don't know why you would _want_ to implement what you are describing but it is a neat idea ;) It probably has something to do with that visual studio hosting process. It always mucks my projects up so I …

Member Avatar for DdoubleD
0
107
Member Avatar for tmc01

Please use code tags when posting code on daniweb: [noparse] [code] ....code here.... [/code] [/noparse] That code uses an unitialized value and it won't compile so that can't be the code you are using. Please post your full unit in code tags so we can review. Even so calling time2.ToString() …

Member Avatar for tmc01
0
158
Member Avatar for chingkoysilog

It looks like you need to be root in order to do that. Try using [icode]sudos -s[/icode] and entering your password, or [icode]su -[/icode] and entering the root password. As root you can [icode]make install[/icode]

Member Avatar for sknake
0
125
Member Avatar for Cool Guy

Daniweb!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! That is all you need for entertainment :)

Member Avatar for red_gal_2005
0
156
Member Avatar for webwired

You don't get it with a table adapter :) If you use a typed dataset it will: Insert the record (using your insert query) Get the scope identity Select your record where id = scope_id() (using your select query) I find it rather harder to use the built in datasets …

Member Avatar for TomW
0
294
Member Avatar for virtualmisc

I had to do that to open a quickbooks cash drawer once. Here is how I went about it: [code] using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Diagnostics; using System.IO; using System.Management; using System.Net; using System.Reflection; using System.Runtime.InteropServices; using System.Windows.Forms; ... [DllImport("kernel32.dll", SetLastError = true)] public static extern …

Member Avatar for sknake
0
465
Member Avatar for LED555

How are you trying to insert the data? Typically binary inserts are done with applications and not directly from TSQL, and inside of the applications you use ADO.NET/Native SQL parameters. You set the parameter to a byte[] array and execute the query. This all depends on the language you are …

Member Avatar for LED555
0
536
Member Avatar for axeeffect2002

Is this a solaris machine? You can try using GNU's awk which won't throw this error. The name for it is "gawk". You should be able to get solaris package files for GNU utils. I think [url]www.ibiblio.org[/url] has them on their FTP site.

Member Avatar for axeeffect2002
-1
414
Member Avatar for kranny
Member Avatar for kranny
-1
173
Member Avatar for ShailaMohite

You could also override the tab behavior of your form. In my case this DataGridView is databound to "dt" which is a datatable. You'll have to handle the adding of a new row depending on how you implemented the grid: [code] protected override bool ProcessTabKey(bool forward) { if (forward && …

Member Avatar for sknake
0
1K
Member Avatar for ddanbe

You declared the Enum inside of a class. You can declare enums directly in the namespace like you're accustomed to: [code] using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; namespace daniweb { public partial class frmEnums : Form { public frmEnums() { …

Member Avatar for ddanbe
0
93
Member Avatar for cheapterp

If you have a good database design and properly indexed tables then you're good to go. You can safely have millions of records in a single table and it will barely make MSSQL break a sweat ;) The total length of the table row could be a problem but you …

Member Avatar for sknake
0
156
Member Avatar for DeOiD

You can also use a [icode]HashTable[/icode] to access the columns by names. I think that is along the lines of what you may want if the other (better!) solutions don't pan out :) DdoubleD/Antenka showed great ways to go about it.

Member Avatar for DeOiD
0
287
Member Avatar for josh_keren

First off your example is incorrect. The "TableA" structure has jmlMuat in your table data, but in your query it has jmlBongkar. It looks like you swapped the tables ;) Try this: [code=sql] IF OBJECT_ID('tempdb..#TableA', 'U') IS NOT NULL DROP TABLE #TableA IF OBJECT_ID('tempdb..#TableB', 'U') IS NOT NULL DROP TABLE …

Member Avatar for sknake
0
101
Member Avatar for DdoubleD

I figured serkan would be all over this thread :P I hate installers As far as I know you can't set a break point but what you can do is make a call to [icode]Debugger.Break()[/icode] [code] namespace daniweb.installerex { [RunInstaller(true)] public partial class Installer1 : Installer { public Installer1() { …

Member Avatar for DdoubleD
0
581
Member Avatar for dave starkey
Member Avatar for serkan sendur
0
114
Member Avatar for stoymigo

stoymigo: Also [URL="http://www.daniweb.com/forums/private.php?do=newpm&u=267883"]send a private message to serkan sendur[/URL]. He is our local installer guru and he would be more than happy to assist you!

Member Avatar for serkan sendur
0
145
Member Avatar for chathuD

There is no download finished process that I know of. What are you trying to do? This sounds more like a browser plugin than a separate application. You can probably get the firefox "Download" window by its caption but that won't indicate if the download has finished

Member Avatar for sknake
-1
246
Member Avatar for RehabReda

Don't you get an external IP address when you connect with your modem, thus you don't need to port forward unless you're sharing the modem connection with other PCs on your network? Is the game server on the machine that is dialing the connection?

Member Avatar for sknake
0
138
Member Avatar for serkan sendur

Use [icode]reset[/icode] to reset your shell. You can use [icode]cat /dev/urandom[/icode] to get random junk data which should screw your terminal up, then issuing a reset should fix it. No -- This will not reboot your computer :)

Member Avatar for serkan sendur
-1
179
Member Avatar for SQL_n00b

By default normal users do not have execute rights on newly created sprocs. Here is how you would grant execute rights on a sproc called "LockRow" to "DOMAIN USERS": [code=sql] GRANT EXECUTE ON dbo.LockRow To [DOMAIN USERS] [/code]

Member Avatar for SQL_n00b
0
445

The End.