|
|
Oops, sorry Senthil, I didn't see your reply to yourself where you already pointed this out!
Matt Gerrans
|
|
|
|
|
|
i have managed to make designcollection to work but i don't know how to create controls with the collection editor.
I have a Item, ItemCollection, ItemCollectionDesigner
an Item consist of text , int and picture
i want to attach a picturebox to it so that it auto generate on my usercontrol...
|
|
|
|
|
I was wondering if anyone can point me in the right direction to replicate the Internet Explorer-style Menu Bar in C# using Windows Forms?
I can easily create the menu using the toolbar control, but I run into problems trying to size the text correctly without the icon. Either I get too much space on the top (setting the toolbar TextAlign to Underneath), or I get too much space to the left (setting to Right). How do I get rid of the space?
~tekun
|
|
|
|
|
Hi, I have an lisview, when the lisview is filled, if it need draw vertical scroll, but if this happen, the horizontal scroll is drawin too to fit the columns with the vertical scroll width.
I would like to fix this resizing the columns with id the vertical scroll is visble.
How can I detect if vertical scroll is visible?
I have prove to catch the api messages in wnproc but I dont know wich message to detect.
Thank you!
La realidad no es más que impulsos eléctricos del cerebro - Morpheus
|
|
|
|
|
Hi,
We are using built in crystal reports for printing reports in pdf format.
We need to know how many pages of data is present in the pdf. basically we have to show "page # of #" in the report.
The problem is we cannot know how many pages are created once the report is shown inthe pdf.
Is there a way we can find how many pages are there in the final PDf created?
Prompt reply is appeciated.
YatinShah
Yatin Shah
Cell: 1 972 523 6333
|
|
|
|
|
How to prevent exiting application after clicking the OK button on Pocket PC?
I can handle the event but can't stop the application from closing.
thanks
|
|
|
|
|
i am make a login form,include both textbox and one button,one is username,other is password,if you input your correct username and password and click the button,you must close this form,and go into other form(this form is main form)
but i meet a troblue:
the button's click event:
NainForm mainForm = new MainForm();<br />
mainForm.Show();<br />
this.Close();
but the mainForm doesn't display,if replace the "mainForm.Show()" to "mainForm.ShowDialog()",the mainForm display,but the login form still display.
Can you help me?
|
|
|
|
|
Show() will allow the user to continue to use the application and bypass the login. ShowDialog() is a modal function, so the application can't be used until the dialog is dismissed. In your case of trying to obtain login data you would want to use this method.
In the OnLoad event for your main form create an instance of your login dialog and call ShowDialog on it from there. Obviously, you would check the DialogResult and handle it appropariately.
|
|
|
|
|
the first form closes because you call this.close. The first startup form probably has the stathread method which startsup the application. When you close this form it takes all the others forms with it cause it's under the same process. What you can do is move the stathread method to the login form and if login is succesful you can show the main form.
|
|
|
|
|
I've just discovered that C# doesn't support default paramters, is this true?
Why is this done?
tnx!
No hurries, no worries.
|
|
|
|
|
|
hey,
tnx!
No hurries, no worries.
|
|
|
|
|
Those arguments aren't very convincing, though. I think it is mostly a subjective stylistic decision aiming toward simplicity. Whether it is really better is probably more a matter of your personal programming style.
On the plus side, it is not too hard to work around:
string Transmogrify( string text, int cycles, bool superamalgamate )
{
}
string Transmogrify( string text, int cycles )
{
return Transmogrify( text, cycles, false );
}
string Transmogrify( string text )
{
return Transmogrify( text, 1 );
}
Unfortunately, this probably results in a little more maintenance trouble than it would with default parameters.
Matt Gerrans
|
|
|
|
|
i am trying to use a word template(.dot file) and a text file in a windows form using C#.i am aware how to extract data from the text file and open the word template.but what i am unable to do is to use the data from the text file in the word template's form fields.
can u tell me how i can replace the form fields with the value or data that i'm retrieving from the text file.
the template when open looks something like this....
Receipt Number : «ReceiptNo»
Card Number : «CardNo»
Member Name : «MemberName»
now,i've got to replace the fields «ReceiptNo»,«CardNo»
and «MemberName»...
i hope u've got an idea of what reply i'm expecting....
thank u...
|
|
|
|
|
I want to have the RGB bytes of a panel from a form to output what on the panel through the serial port
I can do that if the picture on my harddisk ,but the pic on the panel.
what can I do?
and why when I use these steps to get a screen shot it doesn't work, and give me an error message in debugging?
Surface backbuffer = device2.GetBackBuffer(0, 0, BackBufferType.Mono);
SurfaceLoader.Save("Screenshot.bmp", ImageFileFormat.Bmp, backbuffer);
backbuffer.Dispose();
thx
|
|
|
|
|
|
bitmap.GetPixel() method can get the Color value of the pixel at the specified coordinates, and from there, you can get the RGB bytes from the color structure.
Tech, life, family, faith: Give me a visit.
I'm currently blogging about: Conversation With a Muslim
Judah Himango
|
|
|
|
|
I think GetPixel() is slow
i need it faster.
thx
|
|
|
|
|
|
|
Thanks in advance for any help. I am 1 month new to visual c# so please excuse the probly obvious question. I am working on Visual Studios 2003 ver 7.1. I have created a windows form attached to a sql server db.Every time I "apply" changes to a record on my form, the selected index of my list box (which is binded to my dataset) jumps around and then goes back to the record I had selected before the update. The problem is that every time it moves my selected_indexed_changed event is fired and this is causeing me a great deal of trouble. Does anyone have any suggestions?
Thanks again for the advice.
Trent Jackson
|
|
|
|
|
I created an C++ MFC Dll project and am trying to call a function in the dll from a C# Class Library project using DllImport.
I seem to remember that when using DllImport you have to also add a reference to the dll in the project you're using it in. When I go to add a refernce to my MFC.dll in the C# Class Library references I get this error:
"A reference to '[path to my dll]mfc.dll' could not be added. This is not a valid assembly or COM component. Only assemblies with extension 'dll' and COM components can be referenced. Please make sure that the file is accessible, and that it is a valid assembly or COM component."
I can clearly see that the dll I'm trying to reference is in fact a .dll so I'm wondering - is the problem that it is *not* a valid assembly or COM component? How would you tell if it is or is not? If anyone has any ideas about what may be causing the error, how to fix it i.e. how to add a reference to that dll, or why what I'm trying to do won't work it would be much appreciated.
|
|
|
|
|
Assuming your MFC dll is a straight Win32 dll and not a COM dll then you don't need to add a reference to the dll.
You can only reference COM dlls and .NET assemblies.
Have a read of this MSDN tutorial[^] for better explanation.
Michael
CP Blog [^] Development Blog [^]
|
|
|
|