536 Posted Topics

Member Avatar for avanish_yadav

Edit the image palete. Read/Edit the metadata. Red eye reduction. Allow multiple image formats and control the format specific options E.g. JPEG quality or GIF transparent colour. For other ideas have a look at this image viewer: [URL="http://www.irfanview.com/index.htm"]http://www.irfanview.com/index.htm[/URL]

Member Avatar for sknake
0
118
Member Avatar for xGrimReaperx

Try using a [iCODE]System.Windows.Forms.Timer[/iCODE] This is a timer for windows forms. Toggle a ShowGraphic boolean variable in the timer tick event. Then test the value of ShowGraphic in the form paint event.

Member Avatar for nick.crane
0
1K
Member Avatar for tchiloh

This is probably an issue with the international rules for decimal place being different. Extract from Standard Numeric Format Strings Help [QUOTE]The settings in the Regional and Language Options item in Control Panel influence the result string produced by a formatting operation. Those settings are used to initialize the NumberFormatInfo …

Member Avatar for Ketsuekiame
0
5K
Member Avatar for bruno386

Use this to get an array of [iCODE]FileInfo[/iCODE] objects and then sort the array on [iCODE]FileInfo.CreationTime[/iCODE] [CODE]System.IO.DirectoryInfo di = new System.IO.DirectoryInfo("C:\\jpegs"); System.IO.FileInfo[] files = di.GetFiles(); [/CODE]

Member Avatar for bruno386
0
2K
Member Avatar for reza.adinata
Member Avatar for Duki

Have you look at [iCODE]System.Threading.Thread.CurrentPricipal.IsInRole(role)[/iCODE]?

Member Avatar for Duki
0
263
Member Avatar for Aenonar

Have a look at [COLOR="Green"]Internet time servers[/COLOR]. These are used by Windows (and other OSs) to sync the PC clock. Looks quite complicated but also seems a bit like what you are trying to do.

Member Avatar for bbman
0
113
Member Avatar for dilansankalpa

It is possible that you have a read or write action in the UI thread that is hanging because you have closed the serial port. I recommend that you set a flag before closing the port and pause for a short time to allow other threads to finish whatever they …

Member Avatar for dilansankalpa
0
77
Member Avatar for Captain_Jack
Member Avatar for nick.crane
0
98
Member Avatar for Mikey12345
Member Avatar for Ketsuekiame
0
68
Member Avatar for Feanorith

You need to cast the [iCODE]Figuur[/iCODE] type object o to the actual class type of the parameter in your draw functions. E.G. [CODE]paintLijn((Lijn)o);[/CODE] This is why you are getting the invalid arguments error. I would also recommend passing the graphics object form the PaintEventArgs ([iCODE]e.Graphics[/iCODE]) in to your draw methods. …

Member Avatar for Feanorith
0
149
Member Avatar for powerbox

Simple solution [CODE]int testVal = 1234; byte[] data = System.BitConverter.GetBytes(testVal); byte[] data2 = new byte[3]; data2[0] = data[0]; data2[1] = data[1]; data2[2] = data[2];[/CODE] I am sure you have a reason for not wanting to do this though. How about this then. [CODE]int testVal = 1234; byte[] data = System.BitConverter.GetBytes(testVal); …

Member Avatar for powerbox
0
114
Member Avatar for thuyson

[QUOTE=thuyson;1245467]i have a datagridview with last column is a checkbox.When user check on a row or rows, i will add columns' contents on that row into a new row in sql database. Please help me! Thank you so much![/QUOTE] What have you tried so far?

Member Avatar for nick.crane
0
84
Member Avatar for onlinessp

The SAM file contains the user name and a hash of the password; not the actual password. This is a protected system file and not even an Administrator user has access while the computer is running. That said, there is stuff about this on the internet; just Google "SAM file".

Member Avatar for onlinessp
-1
88
Member Avatar for adobe71

Any changes to UI objects must be done by the UI thread. You need to invoke the function call that changes the text. There are several examples of using delegates and invoking, just do a search and you should find something. If not, just ask.

Member Avatar for PierlucSS
0
105
Member Avatar for dilansankalpa

At line 19 you use [iCODE]Convert.ToString(datafrmf1a4);[/iCODE] and change the data to Unicode, so the data sent to the port is no longer what you want. Remove line 19 and try using [iCODE]comport.Write(datafrmf1a4,0,datafrmf1a4.Length);[/iCODE] (writing bytes not string).

Member Avatar for Phil2:3
0
139
Member Avatar for onlinessp

For the new text to show on your label you may need to invalidate the label and will need to give the ui time to refresh.

Member Avatar for pabloh007
1
220
Member Avatar for wlalth

[iCODE]Form1.ActiveForm.Controls[/iCODE] is a collection of all controls on the active form. These could be any control type - TextBox, Label, Panel, not just ComboBox. Try this.[CODE]foreach (Control a in Form1.ActiveForm.Controls) //<-- loop object is Control type. { if (a is ComboBox) //<-- test if loop object is a ComboBox { …

Member Avatar for nick.crane
0
3K
Member Avatar for cgoasduff

I have not used ASP.Net but I do a lot with databases. Your select statement retrieves data from both tables. Try spliting in to two queries and put the returned data in to seperate DataLists. Edit: Sorry, this will not work. I just realised what you are trying to do.

Member Avatar for cgoasduff
0
114
Member Avatar for onlinessp

I tried your code and it seems to work fine. When stepped thru in debug it errored at line 64 [iCODE]Form.ActiveForm.Refresh();[/iCODE] as you said. This is because you use [COLOR="Green"]ActiveForm[/COLOR] and when viewing the code in the DevEnv there is no active form so [COLOR="Green"]ActiveForm[/COLOR] is [COLOR="Red"]null[/COLOR]. Try changing it …

Member Avatar for nick.crane
1
385
Member Avatar for zismad

If the level of your user is up to it you could use also use Hexadecimal input. It is often easier to conceptualise the bit paterns in Hex.

Member Avatar for zismad
0
183
Member Avatar for SimonSellick

Define your common interface / API in a seperate dll and reference this in all processes. This seperates all libraries from the interface library and allows the task manager to still strongly reference all classes. Also, if you later update the task manager it will not break the processor dlls.

Member Avatar for SimonSellick
0
169
Member Avatar for mahdi68

Try this [CODE]protected override void OnLoad(EventArgs e) { base.OnLoad(e); this.Opacity = 0; } protected override void OnShown(EventArgs e) { base.OnShown(e); this.Visible = false; this.Opacity = 100; }[/CODE] Or this if you're not happy with overrides. [CODE]private void Form1_Load(object sender, EventArgs e) { this.Opacity = 0; } private void Form1_Shown(object sender, …

Member Avatar for nick.crane
0
75
Member Avatar for Redhaze46

Set the [iCODE]TransparencyKey[/iCODE] property and [iCODE]BackColor[/iCODE] property to the same color. Then draw your line on the form as normal.

Member Avatar for nick.crane
0
40
Member Avatar for sdhawan

Best guest is that you are updating the row in the textbox TextChanged event and this causes the datagrid to refresh and loose its row selection. Post some code so we can see what you are doing when you select the row and what you do on the textbox TextChanged …

Member Avatar for nick.crane
0
103
Member Avatar for sdhawan

Your SELECT statement only requests the word field. This code [iCODE]if (rdr[0] == (dateTimePicker1))[/iCODE] compares the returned word field value with a DataTimePicker object (not even its value). You need to review your code. I would also recommend changing the code that sets the parameter value to use the date …

Member Avatar for nick.crane
0
128
Member Avatar for ereruh

Use System.IO.Path to join two paths together. In your case the selected folder and the hardcoded filename. E.g. [CODE]string filename = Path.Combine(this.folderBrowserDialog1.SelectedPath, "test.txt"); ... sw = File.CreateText(filename); [/CODE]

Member Avatar for ereruh
0
243
Member Avatar for guiman

The form resx file is used by the form to store things like background image and form size, etc. Any change to the form will rebuild the form.resx file. To localize the form you need to create a separate set of resx files and when ever the form is loaded …

Member Avatar for PierlucSS
0
231
Member Avatar for Nivass

You can get better control of how text is placed if you use the [iCODE]DrawString[/iCODE] that has [iCODE]StringFormat[/iCODE] as a parameter.

Member Avatar for Nivass
0
2K
Member Avatar for judithSampathwa

One click to select the cell. Then one click to begin edit (if not on the arrow). Then one click to show the drop-down. If you click on the drop-down arrow then it takes two clicks.

Member Avatar for finito
0
102
Member Avatar for tom3.14
Member Avatar for JOSheaIV

SelectedRows is a collection. If you debug you will find that loc == "System.Windows.Forms.DataGridViewSelectedRowCollection"

Member Avatar for JOSheaIV
0
96
Member Avatar for judithSampathwa

Posibly because you are comiting the changes and thus changing the CellDirty state. Test the datagrid [iCODE]IsCurrentCellDirty[/iCODE] before executing the commit.

Member Avatar for judithSampathwa
0
2K
Member Avatar for sdhawan

Hello again, [CODE]myCmd.ExecuteNonQuery(); //<-- this executes the query but you do not get any data back cn.Close(); if (myCmd == row["word"]) //<-- this is always false and probably generates a type mismatch at compile/run time { MessageBox.Show(row["word"] + " already exist in your personal dictionary"); }[/CODE] Try changing the command …

Member Avatar for nick.crane
0
138
Member Avatar for zachattack05

The first thing you need to do is clearly define the interface for you plug-in. What functions will the plug-in have access to? What functions must the plug-in provide? This is then best 'set in stone' in an interface dll allowing your main app and the plug-in projects to reference …

Member Avatar for zachattack05
0
109
Member Avatar for sandeepani

Yes, just add a reference to the project containing the DataSet. In the Add Reference dialog select the Projects tab and choose the project containing the DataSet.

Member Avatar for nick.crane
0
94
Member Avatar for lewashby

File is a static class in the System.IO namespace. It has static methods that are used to manage files. StreamWriter is also in the System.IO namespace.

Member Avatar for nick.crane
0
86
Member Avatar for lsy

I have also found this happens on the hidden pages of a TabControl. The objects are still on the Form but are not properly placed on the Form surface. Use the dropdown at the top of the properties window to select each object and then move or resize the object. …

Member Avatar for finito
0
153
Member Avatar for Ap0ca1ypse
Member Avatar for Ap0ca1ypse
0
177
Member Avatar for sdhawan

When the use clicks on a cell in the DataGridView this causes several events to fire. [iCODE]CellClick[/iCODE] or [iCODE]SelectionChanged[/iCODE] are most likely what you need.

Member Avatar for nick.crane
0
102
Member Avatar for zachattack05
Member Avatar for Peacer

The problem is two VEarth instances. The Collision class has its own instance of VEarth. [CODE] class Collision { VEarth ve; //<-- VEarth used by Collision Player p1;[/CODE] The one initialised in Form1 is not the same instance. [CODE]public partial class Form1 : Form { Gps gps = new Gps(); …

Member Avatar for nick.crane
0
186
Member Avatar for MrBlack

The first example is unboxed use of i; with a value type of int. The second example is boxing i (int) in to obj; a referece type of object.

Member Avatar for MrBlack
0
149
Member Avatar for sdhawan
Member Avatar for sdhawan
Member Avatar for SBA-CDeCinko

Use the String.Trim method E.g. [CODE]string x = " test "; x.Trim(); //<- removes spaces from start and end System.Diagnostics.Debug.WriteLine(x); // x it now "test" [/CODE]

Member Avatar for SBA-CDeCinko
0
171
Member Avatar for sodevrom

When comparing times it is best to use <= or >= as it is unlikely that the current time will exactly match the time from your input file. If you are not happy using a seperate thread then using a [iCODE]System.Timers.Timer[/iCODE] is the only other way I can think of. …

Member Avatar for sodevrom
0
508
Member Avatar for Jinspire

You can not programatically grant a user higher access rights than they have. For a basic user to have access to a folder during execution of your program they must already have access to the folder before the program starts. However, it is possible to write an Installer class that …

Member Avatar for sknake
0
142
Member Avatar for PierlucSS

Code in Resources.Designer.cs is automatically generated. Any code you put in there will be overwritten each time any change is made to the Resources file. You could try making Resources partial and put your function in a seperate file. This way only the partial key word is removed; you will …

Member Avatar for nick.crane
0
154
Member Avatar for DaveTran

You can call a protected overridded method from the base class. See below: [CODE]public abstract class Foo { private int a; private float b; protected abstract void DoInit(); public void Init() { a = 1; b = 2.5f; this.DoInit(); } } public class Bar : Foo { public float c; …

Member Avatar for DaveTran
0
127

The End.