Software Development Network Logo
  • Visual Basic
  • VS Team System
  • .NET Development
  • Windows Forms
  • Windows Vista
  • Visual FoxPro
  • SQL Server
  • Visual C#
  • Audio and Video
  • IE Development
  • Visual Studio
  • Smart Devicet
  • Microsoft ISV
  • Game Technologies
  • Visual C++

Software Development Network >> Visual C#

Visual C#

New Question

Best Practice for Handling time
Discover and Pair with Bluetooth GPS Unit
Problem with File.Copy() - Skipping files?
URGENT!! Problem running exe from network
Output one xml file to bin/debug folder after compiling
Get SQL command from datatable ?
Excel Automation Addin Problem
SPI_GETACCESSTIMEOUT Retrieving the values
Data Storage For Distributed Applications
help with the following code

Top Answerers

trekkie25
incendy
Postman001
Lynette2
jcsam
ukalyan
WRBehning
omrivm
Ix-Xerri
JackZhangca
sitemap
Only Title

Answer Questions

  • mehoss Making query in SQL Server - What is the best way?

    Hi i am making a web application using SQL Server 2005. i am trying to make all my query using stored procedure in database and just passing the parameter to the database. I am having some complex task that I can't do in one query. So what is the best way to make the best performance Using complex stored procedure or using more code instead Thanks a lot for your help SQL server service is hosted on server machine and usually it is as heavy machine as it requires. SQL server engine is optimized to work with complex data. Stored procedures are compiled in order to ensure better performance. What you need is data processing engine. You asked about two ways: Use Stored procedures - SPs are compiled and executed on powerf ...Show All

  • AndersBank vjslib and other unwanted assembly references in web.config

    Hi all, I apologize if this is not the proper forum. I have a big solution containing a couple of class libraries and a web site (project type: file system based asp.net web site). Every time I build the web site, the following assemblies are added to the web.config: <add assembly="vjslib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> <add assembly="System.Data.OracleClient, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> <add assembly="System.DirectoryServices, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> <add assembly="System.Messaging, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03 ...Show All

  • carp translation of a little script from VB to C sharp pls

    I want the script bellow in C# pls: "<SCRIPT LANGUAGE=""JScript"">" & vbCrLf & " function fnAdd(){" & vbCrLf & "document.body.insertAdjacentHTML('BeforeEnd','<P>' +document.getElementById('oText') + '</P>');}" & vbCrLf & "</SCRIPT>" I especially have a problem converting both the quotation marks and the VbCrLf when they re in the same string Thanks a lot How do we translate vbCrLf to C# pls as stated: Environment.NewLine or \r\n And you might find this handy :-) http://www.carlosag.net/Tools/CodeTranslator/Default.aspx Good luck! VBCrlf is a carriage return I believe which is Env ...Show All

  • Raf Borrezee Math: Round up number. eg 1234 / 50 = 6

    I have a dataGrid and i wish to produce page buttons for next and back. Therfore i need to know how many pages i will need to for my data Eg, i have 1234 rows of data and each page will contain 50 rows. So 1234 / 50 = 24.68. So I need 25 pages How do i round up a number so 1234 / 50 = 25 . Thanks. Paul When you use the .Round method, you can specify how many decimals to round to - and other things, check out the overloads decimal d = 1234M / 50M; d = decimal .Round(d, 0); MessageBox .Show(d.ToString()); Mike Indeed there are many ways to crack a nut. But what I don't understand is why someone would deliberately choose one of the least efficie ...Show All

  • Mart Tapp Turn off "Are you sure you want to delete all of the bookmarks?"

    This is more of a minor annoyance than a real issue but if anyone has a solution I'd be very appreciative. When you delete all of your bookmarks from a solution in VS2005 (Ctl+B,Ctl+C) you always receive a confirmation dialog asking you if you're sure you would like to do this; does anyone know a way to disable this confirmation I've haven't been able to find anything in the Options (though I may have missed it) and I know that some VS options are really surfaced in the UI but can be controlled by registry keys. Has anyone ever ran across how to turn this off Thanks in advance, Jeremy Unfortunately there is no way to disable this dialog in VS 2005. Anson Horton Visual C# IDE PM Hi Jeremy, well I did check my ...Show All

  • Lawrence Sutton Howto loop through attributes of an custom object for generating SqlParameters

    I have a Save-method in a class. This method gets an object of this class in from codebehind of my webpage, and i want to go through the attributes of the object to generate SqlParameters, and then put the SqlParameters inside an ArrayList and send to the Save-method in the DB-class. The code below works, but i want to do this without my method getParameterSet(Vare v) below the Save-method. I want to get parameter name, type and value from the objectattributes. //////////////////////////////////////////////////////////////////////////////////////////////////////////////// public void Save( Vare v) { string sp = "" ; ArrayList sqlparam = new ArrayList (); ArrayList paramset = getParameterS ...Show All

  • nobitavn94 multithreading

    I need to do multithreading. It is my fist attempt. It failed. This is the setup: There is a form with tabControl and a few pages. There is a progress bar on one of them. It is supposed to measure progress of file downloading. WIthout multhithreading it is dead while the files are downloaded and then in the end it jumps to 100%. This is what I did. Everything compiled but the progress never was activated even after the downloading was over. In other words my code actually made the things worse. In the main form I put in this code at the start of procedure that is handling the download: ThreadStart threadDelegate = new ThreadStart ( Work.DoWork ); Thread newThread = new Thread ( threadDelegate ); newThread.Start ( ); T ...Show All

  • Chris_Pearce How do I rename the administrator on a given machine via c#(System.Management?)

    I've found a few bread crumbs, but i have not as of yet figured this out.. here's what i know. You're supposed to be able to do it using WMI via win32_useraccount.Rename, You can call WMI stuff in c# via System.Management. What I need is how to tie those two pieces of information togther to allow me to make the changes. Can anyone help Give me a few more breadcrumbs to follow Thanks,  Eric-   I figured out how to do this using renuser.exe... it's pretty simple the hardest part is finding a copy of renuser.exe. I found it on the Korean verison of the english site that everyone links to. http://www.ntfaq.co.kr/download/renuser.zip Eric- ...Show All

  • kgs1951 DataTable does not accept field changes

    I am running this test code to find out why I fail to see changes in one of my DOBC (FoxPro) *.dbf tables: private void pushVariousTests_Click ( object sender, System.EventArgs e ) { string sql1 = "SELECT * FROM 'correlates.dbf'"; string inpStr1 = "stoxx"; Class2 class2 = new Class2 ( ); DataTable dt1 = Class2.getData ( sql1, class2.getConnStrings ( ref inpStr1 ) ); foreach ( DataRow row in dt1.Rows ) { if ( (( string )row["named"]).Trim ( ) == "" ) { Console.WriteLine ("empty: {0} ", ( string )row["named"] ); row["named"] = "*"; Console.WriteLine ( "changed : {0} &quo ...Show All

  • No Progress C# Parameter not passed to Web Service

    In a revision of the Distributed Application Walkthrough located here: http://msdn2.microsoft.com/en-us/library/1as0t7ff.aspx , we have changed the WinForms app portion of the walkthrough the use the designer tools in VS2005 instead of a manual placement of the datagridview control and the Load/Save buttons. When we use the VS2005 designer tools to drag and drop from the DataSources window after adding a Web Reference to the project, everything appears to work fine. The Datagridview populates beautifully with the following code in the form class code: public Form1() { InitializeComponent(); localhost. Service ws = new localhost. Service (); ws.Credentials = System.Net. CredentialCache .DefaultCredentials; dataSet1.Customers.Merg ...Show All

  • Noral Trouble with pointers

    Hello, I am currently trying to solve a problem and I'm running into trouble assigning a pointer to a class. To simplify things, my code is setup something like the following: class base_object { public string name; ... } class object_manager { public ArrayList objects = new ArrayList(); unsafe public static void add(string file, ref Hashtable hash) { // do file related stuff here... base_object obj = new base_object(); base_object val = (base_object)hash[key]; base_object* ptr = &val; objects.add(ptr); } } class form { Hashtable my_hashtable = new Hashtable(); void Main () { object_manager.add(the_file, ref my_hashtable); } } The basic premise is that I need to store an arr ...Show All

  • ron nash Writing individual characters to a string

    Hi, I'm very new to C# so I'm getting slightly frustrated with its concept of making things read only when I think they are clearly not. Basically the routine below is part of a simple encryption system that takes a text string and turns it into another string using a mathematical formula on the ascii value of the character and this can then be reversed by another routine. Its just a test routine that I'm converting from delphi. Take the following code: using System; using System.Collections.Generic; using System.Text; namespace TestEncrypt { class Program { static void Main( string [] args) { try { encdec test1 = new encdec (); string test = encdec .EncryptString( & ...Show All

  • Alexey E.Rybakov - CpsLabs Saving to DB after ReadXML - Update requires a valid InsertCommand when passed DataRow collection with new rows.

    1) I read data from a database, then save the data locally using WriteXML, 2) I Shutdown and restart the app ( to mimic real-world user behavior) 3) I Use ReadXML to re-populate my DataSource Now at this point, if I try to save my data back to the database, I get a "Update requires a valid InsertCommand when passed DataRow collection with new rows." It appears that all the rows that have been "ReadXML'd In" are considered "New". If I ReadXML and then AcceptChanges, I can make changes and save them back to the database. But I run into a problem if I save changes locally - in other words, make a change, WriteXML, then later ReadXML. If I accept changes, then those changes that got saved locally ...Show All

  • emepvsd how to Get all of SelectedValue and put it in On textbox?

    "I've one checkboxlist in a webform, I was tried to retrieve all of SelectedValues from CheckBoxlist"; way 1 : string i = SelectBoxList.SelectedValue; Label1.Text =i; this way is only shows "1" Value in Textbox whatever how many CheckBox I Select. way 2 : (I Use Array) string [] checklist = (string) (CheckBoxList.SelectedValue); Label1.Text= checklist[0,1,2,3,4]; when run Theme way 2 , System throw Error message .... could someone help Me to Resolve this problem thank you very much ! thanks it's work now using string builder.append also I can get values from builder.append by use permission.ToStr ...Show All

  • SunHunter configuration error

    i configure my .net framework to run a program on a local intranet. but this program only run in a one of clients and in others this error raise : the key 'Connectionstring' is not defined in appsettings configuration. what is it for and how can i fix it i run my program from a share folder and all program files is in my server and clients run this program by a shortcut. program needs connectionstring to work properly. i copy files by hand in server. From the limited information you've provided, it sounds like the application probably tries to connect to a database, and that Visual Studio created an App.config file for you containing the connection string information. This will be compiled into a file called Your ...Show All

222324252627282930313233343536373839

©2008 Software Development Network

powered by phorum