-
- Conditional Compilation and the Windows Form Designer
by Malcolm Johnston
- 7 Replies
- Last post
by Malcolm Johnston
- Hi,
I have a program with a number of main controls. These controls are each held in a panel and have a corresponding PictureTab related to them. Each of these controls is a self contained piece of functionality within the program. What I want to be able to do is tailor the designer at compile time so that any number of these main controls can be built depending on a bunch of conditional at
-
- Iterating an enumeration with a timer control
by C McQuade
- 1 Replies
- Last post
by Peter Ritchie
- Experts,
I'm attempting to create a windows form with a picturebox (circlebox) that is redrawn every 5 seconds with the next value from the Graphics.SmoothingMode enumeration (example: First it is drawn with SmoothingMode.HighQuality, then SmoothingMode.HighSpeed, then SmoothingMode.None, etc.).
To perform the drawing I created the drawCircle() function like this:
private Image draw
-
- Problem with DataSource and ListBoxes
by Eric Fritzinger
- 5 Replies
- Last post
by Eric Fritzinger
- I currently have a ListBox with a DataSource of type DataSet and a DisplayMember with a correct reference to a table's column. I am having difficulty in my "SelectedIndexChanged" event handler from the ListBox. So, before I do anything, I open an XML file and have the DataSet variable read it in (the XML file was generated by a DataSet, so there's no issue with improper formatting). This
-
- Form1.ShowDialog()
by Mik
- 3 Replies
- Last post
by Mik
- I am opening a form as a dialog window.
A form has some texboxes and two buttons: OK (DialogResult = OK) and Cancel (DialogResult = Cancel).
When user click OK I want to do some validation and if the validation fails I want to display a message box and keep the window opened. In other case I want to perform some operation in the parent form code.
But since it's a dialog window it always c
-
- openFileDialog problem
by StefanQuy
- 11 Replies
- Last post
by jdawson2
- hello
i'm building an xml based client managment system for a customer and came upon a problem wich i can't figure out...
when i open the app i read the xml file into specific List objects and while using the app i change the objects within the List. when the app is closed i write the List objects into the xml.
everything worked fine until i put in a openFileDialog component,
-
- unable to create Typed-Dataset
by IMBack
- 1 Replies
- Last post
by Rong-Chun Zhang - MSFT
- HI,
I went to create a new item (Dataset) and after I enter dataset name and click 'add'. I get an error:
'Object reference not set to an instance of an object' and after I click Ok, Add New Item window opens again.
Not sure why I can't create a dataset file.
Please advice.
Thank you,
-
- Deployment using Setup and msi - no shortcut on desktop
by Glasseye45
- 7 Replies
- Last post
by TilakGopi
- Anyone had problems where the setup, it installs the application, it can be seen in the Add or Remove Programs dialog box, yet I dont get a application listed in Programs or a desk top short cut for that matter. I can run the installed program if I go to its folder and run the executable, but still no app listed in Program menu. Any ideas Users Programs Menu and Users Desktop are set to AlwaysCre
-
- Running program on a website
by baypae
- 0 Replies
- Last post
by baypae
- I had programmed up a game with C#, I am wondering if I could let it run on my website other than let people download it and then run on their computers. This is important because this is a card game and it is possible in the future I could make it a multi-player game. ty in advance
-
- Saving form state.
by The Geek for God!&
- 13 Replies
- Last post
by The Geek for God!!!
- Hello, I have a form, and a list of check boxes. I want it so that when the user closes the program, and at a later date reopens, all the check boxes that the user unchecked is still unchecked, What is the best way of going about this
Thanks!!!
God bless!!!
-
- DatagridView Column Type
by itzAmit
- 1 Replies
- Last post
by Zhi-Xin Ye - MSFT
- Hi, I'm a newbie to C#. I need to set the Column type of the DatagridView to a particular DataType. It would be something like first column would be a label ( Non-editable), Second Column would be a Number and third column would be of type Currency. It is an unbounded datagrid. Please help me in this. Thanks in Advance. Amit
-
- Alpha channel in bitmap erased after unlock/lock
by Sjoerd
- 2 Replies
- Last post
by Sjoerd
- Hi, I'm facing the follwing problem: ---------------------------------------------------------------------------- Bitmap Image = new Bitmap("C:\\TEMP\TEST.JPG"); Image.MakeTransparent(); // creates alpha channel BitmapData b = Image.LockBits(new Rectangle(0, 0, Image.Width, Image.Height),ImageLockMode.ReadWrite, PixelFormat.Format32bppRgb); /* filling Alpha channel with Intel IPP fu
-
- Progressbar makes elements disappear
by andriscs
- 13 Replies
- Last post
by nobugz
- Hi,
I have a form that contains a listbox and a progressbar and some other controls. Because of special conditions I need to update the progressbar manually via its value property, I don't use backgroundworker. There is some item in the listbox as well. When my program starts running and the progressbar gets updated, the elements of the listbox disappear, and they appear again when the progress
-
- how to make valdation to my input data
by adorer
- 5 Replies
- Last post
by frederikm
- my application should have full validation on data...
but I do not know how to make validations ...
for example ... the name should be no more than 50 chars ..
date should be yyyymmdd
gender should be 4 chars or 6 chars ( male or female )
and so on ...
hot o make validation on text numbers dates
help me or give me a source to learn
but before that I hope to write me exaples
-
- Losing updates in datagridview
by jerrykur
- 3 Replies
- Last post
by Zhi-Xin Ye - MSFT
- Hi,
I have a DVG in which I create all of the columns because I want to control how the data is presented. However, the columns are bound to a table via the DataPropertyName property. I have two columns that are integers in the database that represent true and false codes. I display these columns as checkboxes using the following code:
Dim colSampleRejected As New DataGridViewC
-
- how to initialise with array[counter];what is missing in my code
by Wintersu
- 1 Replies
- Last post
by Andreas Johansson
- string [] m_strSalaryRanges = new String {
"$200 - $299" , "$300 - $399" , "$400 - $499" ,
"$500 - $599" , "$600 - $699" , "$700 - $799" ,
"$800 - $899" , "$900 - $999" , "$1000 + " };
// number of employees in each salary range
int [] m_intSalaries;
m_intSalaries = ne
-
- On-screen Keyboard: Active Window Loses Focus for External Apps
by jmcilhinney
- 2 Replies
- Last post
by jmcilhinney
- I'm trying to create an on-screen keyboard in VB 2005. I've read some patchy literature about preventing a form receiving focus. I've not been able to find anything definitive though. I've read in a lot of places that you need to trap the WM_MOUSEACTIVATE message and send the MA_NOACTIVATE reply. That's cool. I override the WndProc method like so:
Code Snippet Protected Overrides Sub
-
- Signing Key
by obrienkev
- 1 Replies
- Last post
by Gavin Jin - MSFT
- Hi,
How do I delete the signing key on the solution
I uncheck the "Sign the Clickonce manifests" in the signing Tab in the properties but when I publish the application it includes the signing key.
Any ideas how to remove this
Thanks.
-
- TextBox Scrolling
by Griffonbait
- 3 Replies
- Last post
by Jay Vora
- I am trying to figure out how to force a multi-line, word-wrapping textBox control to auto-scroll to the start (top) of the text rather than the bottom after it receives more text than is displayable in its visible text area (I am using C#).
The only way I know how to handle this situation is using the following two lines of code, however, I feel there must be a better way to set the scroll pos
-
- Bindable User Control always causes HasChanges
by SiN!
- 6 Replies
- Last post
by Kiavash
- Hi,
I'm experimenting with a user control(Numeric Only Textbox) that is set bindable. I've created a public property "Text2" that is bindable and which in turn formats the data and passes it to "Text" for the user to view.
I got pretty far before realising that when it is bound to a database field, it will cause a "HasChanges" after EndEdit. Even if there is no
-
- Add Form Control Button
by boban.s
- 7 Replies
- Last post
by boban.s
- How to create additional button on Form title like Minimize, Restore and Close button. My target is to detach and attach Form to MDI form using swichable button like Restore. Other ideas or solution for this task are welcomed.
-
- save streamed text to file??
by Helixpoint
- 1 Replies
- Last post
by Bob zhu - MSFT
- Can you save that to a virtual directory
So if they install the program . d:/programs/myprogram
if I have a directory in myprogram/files...How do I save that file to that dir
Dave
-
- Display Records with Null Value in Gridview
by TRU927
- 3 Replies
- Last post
by Bob zhu - MSFT
- I have a gridview with some records with null values. These records will not display in gridview. How do I get them to display
Thanks,
TRU
-
- Preventing text wrap for FlatStyle.System buttons
by WineNCheese
- 2 Replies
- Last post
by Wei Zhou - MSFT
- Hi all,
Is there an easy way to prevent the button text from wrapping for buttons with the FlatStyle set to System I need the ellipsis feature to work but I also need the System style.
Thanx!
-
- Binding, Filtering and ConstraintException
by Romeu Faria
- 0 Replies
- Last post
by Romeu Faria
- Hi, I have a form with 3 elements: 2 combobox and 1 datagridview. The combo's are for filtering the information in the datagridview, using bindingsource component and the Filter option. At first I load all the data unfiltered, but the problem is that when I filter information, a ConstraintException is thown in a database column that's not constrainted and the correct data displayed in datagridview
-
- changing array size depending on lines?
by Anonymousaaaaaaaaaaaaaaaahhhh
- 9 Replies
- Last post
by Anonymousaaaaaaaaaaaaaaaahhhh
- hi,
ok so in vb6 when i have an array i can state a varible to it so it can be sizable e.g.
int canChange = int.parse(textbox1.text);
myarray[canChange];
but in c# i can put varibles into an array it only whants numbers> what way can i get around that
many thanx
this is my code for those ppl who want to know more
//this is my original declaratio