|
hi
I have 6 datatables with me in my application.These datatables were fetching from a server machine
Now i want to insert these items into a local database
Right now i am using foreach method to search all the rows and inserting each one into the local database.
Is there any method to import this datatable directly to a ms access database?
Please reply soon
|
|
|
|
|
Check out bulk insert[^]. I don't know if MS Access supports it, however.
|
|
|
|
|
Have you thought about migrating to Sql Server 2005 express? Then you could use SMO to create the tables and even the database and then use SQL Bulkcopy to move the data. MS access will greatly limit your ability to perform higher end database functions.
_____________________________________________________________________
Our developers never release
code. Rather, it tends to escape, pillaging the countryside all around.
The Enlightenment Project (paraphrased comment)
Visit Me at GISDevCafe
|
|
|
|
|
But i want to use msaccess,its a small desktop application. The sql server may not be in the end machine.
Can you any other technique?
My small attempt...
|
|
|
|
|
i need the full path of a fille whit the fileupload controle
i use
String filename = FileUpload1.PostedFile.FileName;
but i only get the name and not the path
but i work in internet explorer and not in firefox.
How can i solve this.
|
|
|
|
|
turbster wrote: i need the full path of a fille whit the fileupload controle
Why do you think that you need the full path?
turbster wrote: but i only get the name and not the path
Do you have any antivirus/firewall installed? If so, it might remove the path for security reasons. It's also possible that Firefox does this by itself, for the same reason.
There is no reason that the web browser should send the complete path to the uploaded file anyway. It only exposes more information than neccesary.
---
single minded; short sighted; long gone;
|
|
|
|
|
I need data from an excel file.
The user need to select the sheet where the data is.
In firefox the radiobuttonlist whit the sheet names is empty.
If i control the conectionstring you need the hole path and firefox give only the filename.
That is the reason why i need the full path
|
|
|
|
|
Are you running some client-side script that is processing the Excel sheet?? Sending the full path to the server-side will do you no good because the server cannot get to the filesystem on the client machine.
Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic 2006, 2007
|
|
|
|
|
The upload control is not used for selecting files, it's used for uploading files. The file will be sent to the server, the server doesn't have to fetch the file from the client.
Using an upload control for selecting a file only works as long as you are developing the application on your own computer. When you deploy the application on a server, it won't be able to access the file directly, as the server and the client are separate computers.
---
single minded; short sighted; long gone;
|
|
|
|
|
In my webform i would like to have a text box and a button to search.When i click on the search button with the text box the place to search in the map it has to point to the specified location in the map.How is this done in asp .net using C#
Can anyone help me in finding a solution for this?
Midhun Aravind
Siliconsage
|
|
|
|
|
Use google maps.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi,
i'm building application wich uses processor ID for license purposes. Now i'm rewriting some code from C# to C++ and I was wondering how to get processor serial num in C++ . Now I've found some examples, which return empty 0 serial number in C++ (on my computer), because "the feature is not enabled (on my MB probobly)" . However, when I try to get processor ID in C# using
ManagementObjectSearcher proc_info = new ManagementObjectSearcher("SELECT ProcessorID FROM Win32_Processor");
it does return a value. Does anybody know what is that value representing ?
|
|
|
|
|
Intel used to maintain an application note (# 485) that says it all;
assuming they still do (and not just provide a tool to run on a PC)
you should Google for it.
It refers to some assembly code, so you would probably need to create
a C/C++ dll and P/Invoke it.
|
|
|
|
|
Zilo(svk) wrote: uses processor ID for license purposes
That's not really a good idea. I know in all of my machines around here, the ProcId is turned off. It returns 0 in all cases. Can your licensing scheme handle that possibility?
Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic 2006, 2007
|
|
|
|
|
After some research on this topic, i've changed my mind and instead of processorID , I'm using manufacturer and processor type specifications, which are not unique, but on combination with some other id's create "enough" unique identifier . I hope
thanx for reply
|
|
|
|
|
That's the trick. You have to grab a bunch of data from all over the place and combine it to get a uniqueness that you can use. Each piece, in and of itself, might not be unique for a certain sampling of machines, but bits and pieces from all over a machine can't be the same everywhere, statistically anyway.
You have to look at all kinds of stuff like Processor type, RAM data, hard drive and serial numbers, network card MAC's, volume serial numbers, machine SID's, admin account SID's, ..., the list goes on and one.
But, the problem you run into is that your algorithm must be able to withstand changes in the hardware and still return a valid ID.
Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic 2006, 2007
|
|
|
|
|
Sorry, I as a customer do not like that; my machines evolve, and I want to know
beforehand whether my next change will break some of my programs. And anyhow,
I want to continue to use the software I bought on one machine, whatever
happens to that machine; even after a full replacement. Without hassle.
If you have fixed the roof, then added a room to your house, would you like your front door to suddenly remain shut when you repaint the kitchen ?
The one software protection scheme that seems acceptable to me is a hardware
key (today that would be a USB device, plus a backup) that can hold a large
number of keys, so you pass the device's serial numbers to the SW vendors,
and get personalized keys in return.
|
|
|
|
|
Luc Pattyn wrote: Sorry, I as a customer do not like that; my machines evolve, and I want to know
beforehand whether my next change will break some of my programs. And anyhow,
I want to continue to use the software I bought on one machine, whatever
happens to that machine; even after a full replacement. Without hassle.
You're preaching to the choir here! I can't stand Microsoft's little scheme any more than you, and I did mention the drawbacks in my post. It's up to him to figure out a way to do it without screwing the customer if they make a change to the machine.
I really hate protection schemes to begin with. Granted, we need to protect our income, but it's a blurry line between the cost of protection and the margin of profit.
Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic 2006, 2007
|
|
|
|
|
hello forum, well here i m in problem of generating table of content(which is msword feature to generate indexes).
What i have done till know is i generated 2 styles in c# code and apply to word document generated.
Now whats my problem is i have to add these styles to my table of contents ADD method, which requires parameter "ADDEDSTYLE' if new style is to be applied.
i m attaching the code for addingStyle
Word.TableOfContents sty;
object StyleMain = "Main";
object StyleSubMain = "SubMain";
short lev1 = 1;
short lev2 = 2;
sty.HeadingStyles.Add(ref StyleMain, lev1);
sty.HeadingStyles.Add(ref StyleSubMain, lev2);
object stylee = sty;
myWordDoc.TablesOfContents.Add(myWordApp.Selection.Range, ref missing, ref missing, ref missing, ref missing, ref missing, ref RightAlignPageNumbers, ref missing, ref stylee, ref UseHyperlinks, ref missing, ref UseOutlineLevels);
-- modified at 5:41 Friday 20th April, 2007
Hello Forum
Always be in touch to help about the topic ASP.NET
|
|
|
|
|
Hi all
I have problem, what seems like a bug in C#
I need to bind an property of COM object with enum type to ComboBox.
examp:
<br />
<br />
public class CBItem<br />
{<br />
public CBItem(ComLib.TypeEnum Type, string Name)<br />
{<br />
_type = Type;<br />
_name = Name;<br />
}<br />
<br />
ComLib.TypeEnum _type;<br />
string _name;<br />
<br />
<br />
public ComLib.TypeEnum Type { get { return _type; } }<br />
<br />
public string Name { get { return _name; } }<br />
}<br />
<br />
...............................<br />
<br />
this.comboBox1.DataSource = new List<CBItem>(new CBItem[] {<br />
new CBItem(ComLib.TypeEnum.enOne, "One"), <br />
new CBItem(ComLib.TypeEnum.enTwo, "Two")<br />
});<br />
<br />
this.comboBox1.DisplayedMember = "Name";<br />
this.comboBox1.ValueMember = "Type";<br />
<br />
<br />
this.comboBox1.DataBindings.Add("SelectedValue", myComObject , "Type");<br />
<br />
this.comboBox1.DataBindings.Add("SelectedValue", myComObject , "Name");<br />
<br />
<br />
I have a way to avoid this problem by wrapping of COM object like this:
<br />
<br />
public class ComWrap<br />
{<br />
public ComWrap(ComLib.ComObj ComObj)<br />
{<br />
_comObj = ComObj;<br />
}<br />
<br />
public ComLib.TypeEnum Type { get {return comObj.Type }}<br />
<br />
ComObj _comObj;<br />
<br />
}<br />
<br />
................<br />
<br />
ComWrap cw = new ComWrap(myComObject);<br />
this.comboBox1.DataBindings.Add("SelectedValue", cw, "Type");<br />
<br />
<br />
<br />
There is more elegant way to awoid this pertrub (with out using of auxiliar wrapper)?
and may be someone can point out why this occur.
THANK
|
|
|
|
|
hello all currently iam working on the project robotic arm and iam using hitec servo-422 and atmel 8051 microtroller and max 232 and i want to program it in C# to control the robotic arm to pick one object and put it another iam new in C# and i dont have any idea wht do to do please help any one ..could any one provide with any open source,links ..it will be really great and thnx in advance and also i need help wht design pattern i should use.
|
|
|
|
|
faysie wrote: iam new in C#
Why are you expecting the control of a robot to be an appropriate first project ? If you have experience in another language, you should use that, and if you don't, then you probably don't have much hope.
faysie wrote: also i need help wht design pattern i should use.
I doubt there's a pattern which is going to provide a panacea to your task. It's not typical for a pattern ( unless it's MVC, which is not a GoF pattern ), to define the nature of an entire project.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
hey thnx for the reply but new ..means with hardware.. iam in website development already more doesnt mean i dont knw .. ..well its more like this but have to code in C# http://www.mavrinac.com/projects/robot/[^] regards therz always hope
|
|
|
|
|
Oh, OK. Well, you need to work out how to communicate with your hardware. If the robot uses the serial port. C# 2005 has classes to communicate with that port, so once you work out what you need to send, it shouldn't be too hard.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
yes it does work on a serial port ok ....iam getting it but its all kinda mixed up i mean wht will be to exact proecdure to follow to program microcontroller in c# or to program servo motors ..? iam usin rs232 which i serial..can u help me with the exact steps..
|
|
|
|