|
We have to support SQL Server and MS Access as backend databases. Our app was originally written for MS Access using the VS designer. We are trying to have the same data layer (queries - basic insert, update, delete statements) work for both databases. After testing the queries, we found that if the ` char was removed, then the queries would work on both db's.
|
|
|
|
|
Hi , have a good day ...
I want to make My Own C# Messenger with C# ( Like , Yahoo , Microsoft , Google Talk ) ... but with less features ...
Here is what I am planning to do :
- Create C# Windows Application ( Clients ) All my customers will have it.
Included Me ...
- Connect from my computer to My customer computer and support them.
-------
But the problem is about the Web Site
I didn't have any clue where to start
What do I need , a Web Site ?
a Super Computer as Server ,
a protocol ?
P.S :
Customers Count is "300" or less
thank you so much for any word you say ?
I know nothing , I know nothing ...
|
|
|
|
|
Any computer can be a server. All you need is your messaging server running, and the required port(s) opened in your router/firewall.
Clients will need the WAN IP address (or domain name) of the computer acting as the server (could be hard coded) and the authority/knowledge of how to open the required port(s) on their systems.
The rest is a simple question of Client and Server code, which is reasonably trivial and there are a plethora of examples around.
DaveBTW, in software, hope and pray is not a viable strategy. (Luc Pattyn) Visual Basic is not used by normal people so we're not covering it here. (Uncyclopedia) Why are you using VB6? Do you hate yourself? (Christian Graus)
|
|
|
|
|
thank you so much , your replay give me a good view ...
I know nothing , I know nothing ...
|
|
|
|
|
I'd use TCP; for text, losing a part is generally seen as worse than suffering a slight delay
Just slap your own application level protocol on top
If you let all messages go through the server, you won't even have to worry about opening points on the client side. But you'd be putting more load on the server and the latency would be approximately doubled compared to peer-to-peer chat (where the server would only be used to look up the IP of a client from an ID/name/whatever)
Peer-to-peer is quite hard compared to server/client though.
|
|
|
|
|
Thank you , so much
But I think I can't make P2P because we need Real IP ,
yeah In my country , 70% of Internet Users have dynamic IP address ,
In Other Word , we all have the same IP Address
and I test that , On www.whatismyip.com
Thank you ...
I know nothing , I know nothing ...
|
|
|
|
|
If that means you're behind double NAT (national NAT and NAT at your router) then that is a big problem. Really bad.
Well just do client/server, that should be fine
|
|
|
|
|
you mean like this?
http://www.umbrasystems.com/gcomm.php
|
|
|
|
|
you mean like, advertizing?
|
|
|
|
|
- You basically need a server and client program.
- You can use TCP as a communication protocol.
- When designing server, you have got two choices. Either use WCF or work with raw TCP with sockets. I'd suggest to work with sockets directly rather than a WCF wrapper.
- The system on which server is running should open the port it is using.
- You need to create your own protocol for exchanging messages.
- Since the server has to handle 300+ connections, asynchronous programming style has to be used for more scalability.
Of course you also need a book. TCP/IP Sockets in C#: Practical Guide for Programmers[^] is a good book to start with.
|
|
|
|
|
Thank you so much ,,,
the idea is clear now ...
I will start programing with "TCP with sockets".
The book looks greate
kind regards,
I know nothing , I know nothing ...
|
|
|
|
|
I am writing an app that requires centralizing a number of Access App's data files into one SQL server. Albeit separate databases within it.
I know the Access Upsizing wizard can migrate access tables to SQL. As can the SQL server import wizard. However, I need to be able to schedule this and request it at any time from the server.
Getting the Access mdb files onto the server isn't a problem, that's all handled with WebServices. However, I can't for the life of me find a way to automate the table creation and data insertion for the sql server.
I have come across a number of resources listing how to pull data from a datatable object and create the database on the server using SMO (SQL Managemant Objects, i think) But I can't see any resources on how to actually pull the Access data into a Datatable object in the first place. Either way, this method obviously will incur some speed penalties, also maybe some problems with datatypes etc... So finding a way to automate the sql import is by far the better idea!
If anyone has any ideas I would be so grateful!
Thanks a lot.
Ben
|
|
|
|
|
Hello guy´s
I´ve a problem with the implementation of Sudoku in c#....
i wrote 2 for-loops, one that tests the collums, one that tests the rows if the numbers 1-9 are unique in a row/col... The 2 Loops are working perfect, but only if i use ONE of them.. The 2 loops are not working together , I think it´s a Overflow...
I try to interlace the for-loops, but i´m with stupid.. I have to ask for help in this forum
here is a bit of code
using System;
using System.Collections.Generic;
using System.Text;
namespace sudoku
{
class sudoku
{
private int[] values_right = new int[81];
private int[] squareindex = new int[81] {0, 0, 0, 1, 1, 1, 2, 2, 2,
0, 0, 0, 1, 1, 1, 2, 2, 2,
0, 0, 0, 1, 1, 1, 2, 2, 2,
3, 3, 3, 4, 4, 4, 5, 5, 5,
3, 3, 3, 4, 4, 4, 5, 5, 5,
3, 3, 3, 4, 4, 4, 5, 5, 5,
6, 6, 6, 7, 7, 7, 8, 8, 8,
6, 6, 6, 7, 7, 7, 8, 8, 8,
6, 6, 6, 7, 7, 7, 8, 8, 8};
private int[] posible_values = new int[9] { 1, 2, 3, 4, 5, 6, 7, 8, 9 };
public sudoku()
{
this.generate();
}
public void generate()
{
Random rnd = new Random();
int i;
for (i = 0; i < 81; i++)
{
while (this.values_right[i] == 0)
this.values_right[i] = rnd.Next(1, 90) % 10;
while (check_position(i) == 0)
{
this.values_right[i] = (this.values_right[i] + 1) % 10;
}
}
}
public int[] get_values_right()
{
return values_right;
}
int check_position(int i)
{
if (this.values_right[i] == 0)
return 0;
Random rnd = new Random();
int row = i - (i % 9);
int col = i % 9;
int position;
for (position = row; position < row + 9; position++)
{
if (position == i)
continue;
if (this.values_right[position] == this.values_right[i])
return 0;
}
return 1;
}
}
}
Thanks for help, members of coding...
I´m sure, its only a LITTLE 1-MINUTE problem 4 you..
Thank again..^^
modified on Thursday, August 27, 2009 2:25 AM
|
|
|
|
|
|
You might get lucky and find someone fool enough to visit an unknown site and download goodness knows what, but most won't.
If you have a section of code that doesn't work then post it here, with a full explanation of the problem, any error messages or odd results. Remember to format your code properly by using the 'code block' widget above the text entry box, or surrounding it with <pre></pre> tags.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
ok thanks
I now pastet code into the post
|
|
|
|
|
I have some forms tht load data in grid in background. As its huge data, until it gets loaded I want progress bar form to show the load status... how can I do that?
|
|
|
|
|
try backgroundworker , you can found it in you VS toolbox->Component.
When you start loading data
Call backgroundworker to start
Show your loading Form
When the background worker Finish ...
Close the Loading Form ....
I know nothing , I know nothing ...
|
|
|
|
|
If you look at the example implementation code in my ProgressWorker article that I linked to earlier, you will see that it does exactly what you want. In the DoWork event handler, do your grid loading. If you can provide values along the way to indicate the progress, set the ReportsProgress property to true and call the ReportProgress method when you want to update the progress, otherwise set it to false and you'll get a Marquee style.
If you don't want to use my component, then it's easy to set up a BackgroundWorker and a ProgressBar to do exactly the same thing. I just combined them into one to make life easy!
DaveBTW, in software, hope and pray is not a viable strategy. (Luc Pattyn) Visual Basic is not used by normal people so we're not covering it here. (Uncyclopedia) Why are you using VB6? Do you hate yourself? (Christian Graus)
|
|
|
|
|
I have created a custom configuration section in my config file. I can read from it with out any problem. How ever, When I try to write a new value to the element I get an error: "System.Configuration.ConfigurationErrorsException: The configuration is read only".
This is a desktop application so I wouldn't think it was because of insufient permissions. Any suggestions on how to solve this would be very much appreciated.
// This is what is in the config file
<configuration>
<configsections>
<appsettings>
<add key="QueryStartDate" value="05-07-2009">
<add key="QueryEndDate" value="11-07-2010">
<connectionstrings>
<add name="DB_RS2100" connectionstring="Driver={MySQL ODBC 3.51 Driver};Server=127.0.0.1;DATABASE=DB_RS2100;OPTION=3">
<custom
stringvalue="Veh8900"
="">
// This is the class I am using to access the custom config section.
namespace CSDBControl
{
class CustConfig: ConfigurationSection
{
private static ConfigurationProperty s_propString;
static CustConfig()
{
// Predefine properties here
s_propString = new ConfigurationProperty(
"stringValue",
typeof(string),
null,
ConfigurationPropertyOptions.IsRequired
);
}
// Gets/sets the StringValue setting.
[ConfigurationProperty("stringValue", IsRequired = true)]
public string StringValue
{
get { return (string)base[s_propString]; }
// **** This is where the read only error occurs
set { base[s_propString] = value; }
// Also tried:
// set { this[s_propString] = value; }
// set { this["stringValue"] = value; }
}
}
}
// I am accessing my configuration file like this:
string SelVehicles = "Vehicle1;
CustConfig custConfig = (CustConfig)ConfigurationManager.GetSection("custom");
// This works, I can read the value just fine
string test = custConfig.StringValue;
// This does not work. Not able to write to he config file.
custConfig.StringValue = SelVehicles;
Craig
|
|
|
|
|
Hi All,
I have a need to drop a control onto another control at a precise location. The location can change based on how many controls are currently on the target control. It's sort of like snap-to-grid without the grid.
Thanks,
Jim
|
|
|
|
|
Why dont you use an asp table and on load you build your table and where the control is needed you just load it?
|
|
|
|
|
It is a Winforms project, and the target must be incremented based on the number of objects present.
|
|
|
|
|
Well I wish i could help you but i work with web app not win , best luck there
|
|
|
|
|
Check your email Jim.
Kevin
It got bounced back. Send me an email and I'll reply with the file.
Everything makes sense in someone's mind
|
|
|
|
|