Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
C

Chintan Desai

@Chintan Desai
About
Posts
85
Topics
27
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Issue with opening multiple form using delegate.BeginInvoke()...new form get hanged...Plz help
    C Chintan Desai

    Hi Ian, Thanks for your great advice. I tried BackGroundWorker component also. However, I am getting same result - Form2 get hanged. Thereafter, I tried some stupid stuff and it worked. I only copied form2_load code in public method (BuzyOperation) and called BuzyOperation() replacing it with frm2.show()

        Form2 frm2;
        private void backgroundWorker1\_DoWork(object sender, DoWorkEventArgs e)
        {
            frm2 = new Form2();
            frm2.BuzyOperation(); //Earlier it was frm2.Show().
        }
    

    After completing BuzyOperation(), below code will execute which will only show form2 with Job Done msg.

        private void backgroundWorker1\_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            frm2.Show();//this will call frm2\_load event, which is now empty. I copied all code to BuzyOperation()
            MessageBox.Show("Job done!");
        }
    

    I found the result as success, Now form2 is not getting hanged :thumbsup:. I don't know what is going inside frm2.Show() (in our earlier scenerio), but i would like to know from you. :confused: Pls. let me know.

    Thanks in advance, Chintan.

    C# help

  • Issue with opening multiple form using delegate.BeginInvoke()...new form get hanged...Plz help
    C Chintan Desai

    Hi All, I am bogged down with some weird issue. I have one login form having login button. At the click of login button, I need to show one form (say form2). This form2 do some buzy operation (5 second) in form2_load event. I need to show one progress bar also (at click of login button - before showing form2) telling user that something is running - so pls wait... Coding stuffs: I am using delegate's BeginInvoke code. Below is login button click event:

                BuzyOperationDelegate del = new BuzyOperationDelegate(BuzyOperation);
                IAsyncResult result = del.BeginInvoke(null,null);
                while (result.IsCompleted == false)
                {
                   //progress bar shown here...
                }
    

    In BuzyOperation(), I am opening new form (i.e. form2) as shown below:

       private int BuzyOperation()
        {
                Form2 frm2 = new Form2(); 
                frm2.Show();//this will take 5sec.
                return 1;
        }
    

    Here is my issue. form2 get hanged. :zzz: Progress bar is running absolutely correct asynchronously :thumbsup:. I am also using Application.DoEvents(). But still form2 gets hanged. :zzz: Plz help... Chintan

    Thanks in advance, Chintan.

    C# help

  • RadioBoutton as a group
    C Chintan Desai

    use RadioButton class as array and use ".Checked" accordingly with every radionbutton instance in a loop. e.g after creating array instance if(radioButton[i].Checked) _select=0;

    Thanks, Chintan(India)

    C# help

  • How to add custom event log type in windows event log via C# [modified]
    C Chintan Desai

    Hi all, I look 5 event log type in window event log. They are as under. error. information. warning. success audit. failure audit. While, my requirement is to add 2 more custom event log type, along with it...such as FATAL. DEBUG. Can any one advice me, how to do it...(PROGRAMATICALLY) thax in advance.

    Thanks, Chintan(India)

    modified on Wednesday, December 10, 2008 3:53 AM

    C# csharp debugging help tutorial

  • Cant see output to Event log with log4net EventLogAppender.
    C Chintan Desai

    Hi Giorgi, Yes, I have full admin permission. I try the same with .NET EventLog class which was working fine...

    Thanks, Chintan(India)

    C#

  • Event Log Madness - Changing the log associated with a log
    C Chintan Desai

    Restart your machine...Hope it will work.

    Thanks, Chintan(India)

    C# visual-studio com windows-admin question

  • Cant see output to Event log with log4net EventLogAppender.
    C Chintan Desai

    Hi Guys, I want to write to event log with log4net eventlogappender, but could not get the output in event log. Below is my code snippets

    Creating root
    

    I use to get IsErrorEnabled as true, but cant see the output. I think I am missing Source, but there is no property to set the source. Pls let me know, if I miss any properties. thanx in advance.

    Thanks, Chintan(India)

    C#

  • Event Log from a remote computer?
    C Chintan Desai

    But, you didn't wrote, how you achieve your work...

    Thanks, Chintan(India)

    C# csharp asp-net dotnet windows-admin question

  • How to log msg in Remote machine event log...
    C Chintan Desai

    Hi Guys, I can log msg in event log in my local computer. I want to do the same remotely... I find MachineName property in EventLog class, but didn't work... Your help could be useful. Following is my code snippet:

    EventLog sysLog=new EventLog();
    sysLog.MachineName="00C0D0C10F4A";
    if(!EventLog.SourceExists("Application-1"))
    EventLog.CreateEventSource("Application-1","SystemLog");

    EventLog.WriteEntry("Application-1","Hi",EventLogEntryType.Warning,235);

    thax

    Thanks, Chintan(India)

    C# help tutorial

  • How to convert .Net class files to html
    C Chintan Desai

    HI Guys, I need to convert all *.cs files in one solution to html format. The exe will convert all code to html format. Is there any third party tool which can do the same. thx in advance.

    Thanks, Chintan(India)

    C# csharp html tutorial

  • How to log statement in MS SqlServer by ADONetAppender using Log4Net.
    C Chintan Desai

    Hi Guys, I am very new to Log4Net. I need to log some logging statement in SQL Server DB. How to add the logging stmt programmatically? I google it out for few sample, but didn't find, wht I want. Plz help out.

    Thanks, Chintan(India)

    C# database sql-server sysadmin help tutorial

  • How to save changes back to database using 'Link over Dataset'
    C Chintan Desai

    Hi Guys, I am a fresher in LINQ. I want to change UnitPrice (one of the column in table table1) of product name="Alice mutton" and reflect back the changed UnitPrice back to database using data set. I got the result, but with Update() method, in ADO.NET 2.0. How to do the same in LINQ? I think there must be another method. such as SubmitChanges() in Linq to Sql...

    Thanks, Chintan(India)

    LINQ csharp database linq tutorial question

  • Optimizing LINQ query
    C Chintan Desai

    Plz done post such code which irritates.

    Regards Chintan HCL Technologies...India (Carefully) listen->(Deeply)Think->(Clearly)Understand->(Patiently) reply...

    LINQ database csharp linq question learning

  • Difference between ADO.NET Dataset and LINQ to Dataset (after filling dataset).
    C Chintan Desai

    I am very new to LINQ and reading it since a week. Its very interesting and good work by the author. I am working on Linq over Dataset and little bite confuss it with our earlier Dataset (Ado.Net).:confused: Could you please reply with the difference. I couldn't found on internet. Thnx in advance. :rose:

    Regards Chintan HCL Technologies...India (Carefully) listen->(Deeply)Think->(Clearly)Understand->(Patiently) reply...

    LINQ csharp linq

  • How to set batch file argument in "Execute Process Task" (SSIS Packages)
    C Chintan Desai

    Thx for the reply :) Log file is showing the following:

    Microsoft (R) SQL Server Execute Package Utility
    Version 9.00.1399.06 for 32-bit
    Copyright (C) Microsoft Corp 1984-2005. All rights reserved.

    Started: 12:19:02 PM
    DTExec: Stopping the package execution.
    Started: 12:19:02 PM
    Finished: 12:19:10 PM
    Elapsed: 7.938 seconds

    I couldn't see the rows affected in my DB by packages which are executed by this bat file...In short, this batch file is not executing the argument.

    Regards Chintan

    modified on Tuesday, July 15, 2008 5:18 AM

    C# help sql-server tutorial

  • How to set batch file argument in "Execute Process Task" (SSIS Packages)
    C Chintan Desai

    Hi Guys, I have one batch file. I set argument in it and when I double click the bat file,it work perfectly :). Argument only suggest to execute other SSIS packages on a given path. Argument is:

    FOR %%V IN (*.dtsx) DO dtexec /f "%%V" /Config "cfg%%~nV.dtsConfig" >> log_PkgExecution.txt
    pause

    Now, I want to set the same argument in SSIS Package called "Execute Process Task" in Execute Process Task editor -> Argument property. I did it, but getting problem during execution. On executing the package, DOS prompt is coming blank... I think, it is not getting the argument... Please help, if I am doing something wrong. Thanks in advance. Chintan

    C# help sql-server tutorial

  • How to upload file onto server with credentials
    C Chintan Desai

    Hi all, Please let me know about any class avail in .NET 2.0 to transmit single file with Credentials(username and password) on to server. I have tried with HttpWebRequest class, but getting some problem. Do .NET have any classes to transmit file on Server. Thanks,

    Regards Chintan HCL Technologies...India (Carefully) listen->(Deeply)Think->(Clearly)Understand->(Patiently) reply...

    C# csharp sysadmin help tutorial

  • Problem in uploading file with HttpWebRequest
    C Chintan Desai

    Hi all, I am getting problem in uploading file with ASP.NET (C#). I have set almost all property of HttpWebRequest instance. I have too set properties in my Virtual directory. I am getting error as "Cannot connect to the configuration database". I dont know what is configuration database in these case. My application takes 10 second when it execute the below code: HttpWebResponse httpResponse =httpWebResponse)httpRequest.GetResponse(); I have used Stream to write uploaded file content. It seems to be working fine. Even I am getting my Stream object by GetRequestStream(). ======================================================================== here is my code. string URI = "http://" + txtServerIP.Text + "/" + "VDir" + "/" + fUpload.FileName; HttpWebRequest httpRequest = (HttpWebRequest)WebRequest.Create(new Uri(URI)); FileInfo fileInfo = new FileInfo(fUpload.PostedFile.FileName); httpRequest.Method = WebRequestMethods.Http.Put; httpRequest.AllowWriteStreamBuffering = true; httpRequest.Credentials = new NetworkCredential(txtUserName.Text, txtPassword.Text); httpRequest.ContentLength = fileInfo.Length; httpRequest.ContentType ="text/html"; FileStream fs = new FileStream(fUpload.PostedFile.FileName,FileMode.Open); Stream stream = httpRequest.GetRequestStream(); contentLength = fs.Read(buff, 0, buffLen); while (contentLength != 0) { stream.Write(buff, 0, contentLength); contentLength = fs.Read(buff, 0, buffLen); } stream.Close(); fs.Close(); //Here it takes 10 seconds.:mad: HttpWebResponse response = (HttpWebResponse)httpRequest.GetResponse(); Could you pls help me. Thanks,

    Regards Chintan HCL Technologies...India (Carefully) listen->(Deeply)Think->(Clearly)Understand->(Patiently) reply...

    C# help csharp html asp-net database

  • How to Copy my C# project from one machine to another??
    C Chintan Desai

    Hope you are dealing with windows desktop application.If yes then hope below items are matched with items in ur another maching. .NET Framework Visual studio XXX sql server xxx If u r dealing with Web application then chk out its ISI path as well as virtual directory path. nJoy .NET

    Regards Chintan www.visharadsoft.com (I am thinking to change humans to computer, but unfortunately GOD will not give me the source code)

    C# csharp help tutorial question announcement

  • How to move scroll bar thumb on click of button.
    C Chintan Desai

    Hi guys, I have one panel and one picturebox in panel.Here picturebox exceed panel height.Now, I wanna to move scroll thumb downward on click of button to let user see the other areas of picturebox. I have written one code in button_click event panel1.VerticallScroll.Value+=5;//5 indicate moving thumb by 5 pixel. I am getting some awkward output.In first click I can move picturebox top by 5,in second click verticall scroll bar get incremented by 5,in 3rd I can move picturebox top by 5,in 4th click verticall scroll bar get incremented by 5. can any one tell me why it so...I want both to be done in one click. pls reply thanks in advance.

    Regards Chintan www.visharadsoft.com (I am thinking to change humans to computer, but unfortunately GOD will not give me the source code)

    C# com tutorial
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups