Forum: C# 3 Days Ago |
| Replies: 3 Views: 207 You have to show us what you got before we can help you |
Forum: C# 3 Days Ago |
| Replies: 3 Views: 171 you need to have an open connection, just as it says, right before you call execute reader call this
if (conn1.State != ConnectionState.Open)
{
conn1.Open();
}
... |
Forum: MySQL Jun 16th, 2009 |
| Replies: 5 Views: 744 ahhh, so for every record that exists in acts you are needing an update
my advice would be to use a sql 'for each' loop, you can use a cursor and iterate through each row and execute the update... |
Forum: MySQL Jun 15th, 2009 |
| Replies: 5 Views: 744 are you sure you are needing to do 34 updates, 9 records only need 9 updates
if the update isn't working properly, can you give us a little more of the schema and also what the distinct column is? |
Forum: C# Apr 9th, 2009 |
| Replies: 4 Views: 883 whether it is buttons or textboxes, still the same concept
//form 1
frmKeypad frmKey = new frmKeypad();
frmKey.ShowDialog();
this.btnQuestion.Text = frmKey.SelectedKey;
//form 2 |
Forum: C# Apr 9th, 2009 |
| Replies: 4 Views: 883 here's a link on a small little sample i did for that
http://alleratech.com/blog/post/Sharing-data-between-forms-with-C.aspx |
Forum: ASP.NET Apr 9th, 2009 |
| Replies: 28 Views: 1,708 could be done without it, i think you would have to parse and eliminate the extra escape characters then convert it to a byte array using encoding getbytes
i might be wrong, but just a shot |
Forum: ASP.NET Apr 9th, 2009 |
| Replies: 28 Views: 1,708 here's another tidbit i found
http://www.postgresql.org/docs/8.3/interactive/datatype-binary.html |
Forum: ASP.NET Apr 8th, 2009 |
| Replies: 28 Views: 1,708 think this is what postgre calls bytea
check out this
http://docs.huihoo.com/enterprisedb/8.1/dotnet-usingbytea.html
25.15.1. Retrieving the BYTEA Column Using .NET Code
hopefully that can... |
Forum: C# Apr 8th, 2009 |
| Replies: 3 Views: 284 pretty much the same thing
the important piece being this line
Application.ThreadException += new System.Threading.ThreadExceptionEventHandler (Application_ThreadException);
unless you... |
Forum: C# Apr 8th, 2009 |
| Replies: 3 Views: 284 Not really
Its good practice to handle the exceptions as they occur and decide if you can move on or pass back a specific error message
Here is an example of what you might be looking for... |
Forum: Java Apr 8th, 2009 |
| Replies: 8 Views: 2,244 you are trying to run the jar file
do you have this in there?
public static void main(String [] args)
i'm assuming you don't, but for a jar file to be run, just like any other code, it... |
Forum: C# Apr 8th, 2009 |
| Replies: 10 Views: 1,013 i should add to this, both really have their place
normally you would use these instance methods when they pertain to particular class, lets says a single point of reference for a connection... |
Forum: C# Apr 8th, 2009 |
| Replies: 10 Views: 1,013 when using this
public static int Result4, Result6 = 0;
public static Assembly DMUAssembly;
there is no need for a singleton, they are static variables |
Forum: C# Apr 8th, 2009 |
| Replies: 10 Views: 1,013 The problem with that would be is that its not a singleton and can exist in multiple classes
private static readonly GlobalVariables TheSingleGlobalVariableInstance = new GlobalVariables();
... |
Forum: ASP.NET Apr 8th, 2009 |
| Replies: 28 Views: 1,708 i only saw part of the output, what format is this output in? |
Forum: C# Apr 8th, 2009 |
| Replies: 10 Views: 1,013 you are mixing static with singleton here
try this way
public class GlobalVariables
{
private static readonly GlobalVariables TheSingleGlobalVariableInstance = new... |
Forum: ASP.NET Apr 8th, 2009 |
| Replies: 28 Views: 1,708 are you meaning all your double backslashes?
just run a replace on your escaped characters
Dim fileAsString As String = myString.Replace("\\", "\")
i think this is how with vb, more... |
Forum: C# Apr 8th, 2009 |
| Replies: 1 Views: 355 try this
its unclear why you are using string text as a parameter if its not being passed on, but here it is
void delegate textCallback(string text);
public void ThreadProcSafe2(String text)... |
Forum: ASP.NET Apr 8th, 2009 |
| Replies: 28 Views: 1,708 the management tool you need for the import is just sql management studio or even run it through code
did you try the bulk insert?
escape format meaning? |
Forum: ASP.NET Apr 7th, 2009 |
| Replies: 28 Views: 1,708 opening it up wouldn't do anything, as long as you don't save it
have you tried to import inside management studio specifying the pipe, or doing something like this?
BULK INSERT MyTableName
... |
Forum: C# Apr 7th, 2009 |
| Replies: 2 Views: 535 add an extra variable called shown
private bool shown = false;
private void button1_Click(object sender, EventArgs e)
{
firstName = "Tom";
lastName = "Lee"; ... |
Forum: ASP.NET Apr 7th, 2009 |
| Replies: 28 Views: 1,708 why can't you just do an import into sql server without going code side?
also are you sure you mean a psv or csv? |
Forum: C# Apr 7th, 2009 |
| Replies: 8 Views: 541 its because you are using an untyped list for one, but you didn't have an else statement
if (yourValue == "b")
{
break;
}
else
{
numbers.Add(Convert.ToInt32(yourValue)); |
Forum: C# Apr 7th, 2009 |
| Replies: 13 Views: 1,608 Prices.Add(2.0);
This only appends to your list, this does not so called 'add' or sum them together
for the sum you need to use a foreach or enumerator as you had before, and increment sumValue |
Forum: MS SQL Apr 7th, 2009 |
| Replies: 2 Views: 1,244 there are other ways you could do this, but here's one
select
CAST(Reference AS INT) as REFERENCE
from tablename |
Forum: ASP.NET Apr 7th, 2009 |
| Replies: 28 Views: 1,708 i'm not sure what you are meaning
the actual value? of what?
and what are you wanting to use for testing? |
Forum: C# Apr 7th, 2009 |
| Replies: 1 Views: 566 you can compile c from command line, just use the same from c#
the redirectstandardoutput will allow you to get the output that would be displayed as well
Process proc = new Process();... |
Forum: C# Apr 7th, 2009 |
| Replies: 8 Views: 541 you don't always have to use that way, but you can
you could also do something like this
foreach(int num in numbers)
{
Console.WriteLine(" " + num);
} |
Forum: ASP.NET Apr 7th, 2009 |
| Replies: 28 Views: 1,708 this here in your file, shows that it is supposed to be a jpeg
\\377\\330\\377\\340
here's a c# sample to check a stream
http://stackoverflow.com/questions/210650/validate-image-from-file-in-c |
Forum: C# Apr 7th, 2009 |
| Replies: 8 Views: 541 this will loop through all the values in your array
IEnumerator basically means you can use it to iterate your data
lets say you have 1, 5, 3, 8 in your array
this will print out
1 5 3 8 |
Forum: ASP.NET Apr 7th, 2009 |
| Replies: 28 Views: 1,708 try to save the byte array to a file rather than image first, and see if you can open that file up properly
'Get our byte array
obj = StringToByteArray(ImageString)
'Save to a file
Dim... |
Forum: MySQL Apr 7th, 2009 |
| Replies: 5 Views: 730 What is the result of the show full columns statement i sent you, if its latin1_bin thats why |
Forum: ASP.NET Apr 7th, 2009 |
| Replies: 28 Views: 1,708 try this then, c# but i'm sure you can convert it to vb
ImageConverter imageConverter = new System.Drawing.ImageConverter();
Image image = imageConverter.ConvertFrom(obj) as Image;
if... |
Forum: ASP.NET Apr 7th, 2009 |
| Replies: 28 Views: 1,708 try specifying the size of the memory stream, are you also sure stringtobytearray is doing what it should?
Dim ms As New MemoryStream(obj, 0, obj.Length) |
Forum: Database Design Apr 7th, 2009 |
| Replies: 1 Views: 461 I would suggest you to take a shot at it and say what tables and columns you have for now, as far as normalization goes
I have done a similar design recently for basketball, here is the basic... |
Forum: MS SQL Apr 7th, 2009 |
| Replies: 3 Views: 915 you could also use varchar(max)
here's a link that will explain it
http://www.teratrax.com/articles/varchar_max.html
and also a reference for it (check out #2)... |
Forum: MySQL Apr 7th, 2009 |
| Replies: 5 Views: 730 also try this statement also
select * FROM assign2 WHERE UPPER(CONVERT(keyword1 USING latin1)) LIKE '%MICROSOFT%'; |
Forum: MS SQL Apr 7th, 2009 |
| Replies: 3 Views: 915 you should be able to use a nvarchar(max) |
Forum: MySQL Apr 7th, 2009 |
| Replies: 5 Views: 730 What type of collation is this?
run this
SHOW FULL COLUMNS FROM assign2; |