|
Hello,
Can anyone recomend my on a good book that explains how to program user controls ?
I found some book that explains how to use the microsoft controls, but i need to program my own.
Thanks
|
|
|
|
|
o,I'm looking for it also,if you find it,can you tell me also?much thanx
|
|
|
|
|
I've found Professional Windows GUI Programming with c#, from the wrox publication.
|
|
|
|
|
Hi all,
I'm using the Tao libraries and the simpleOpenGLControl therein to make a graphing widget. This requires text for the labels of various things, yet getting text in ogl seems to be a nightmare for me. The most suited functions seems to be the glutBitmapCharacter and/or glutBitmapString. I've seen a few example tutorials of these adn they look simple enough. However, when either of these functions are executed, I just get an exit with code 1. Whatever that means. I take it that means 'bad' as the darn thing doesnt work.
I have absolutely no idea what to do next and I've got no information from the compiler about what exactly this error is. It simply refuses to work.
Can someone please help or point me in the right direction or let me find alternatives?
NB: In the NeHe lesson 13 there is some sort of example that does something with text that I cant quite get my head around. This code suffers from the same problem, yet the compiled exe (that comes with the Tao libraries) works fine. Not sure if thats relevant.
EDIT: The problem appears to be with the simpleOpenglControl itself. The gluBitmap functions work correctly on an a standard openGl window.
-- modified at 5:58 Thursday 12th October, 2006
|
|
|
|
|
Have you called glutInit before calling glutbitmapcharacter? that was my problem
|
|
|
|
|
Environment:
vs2003.net
winform,windows application
Form1:
components:
- datetimePicker1
- button1
- toolbar1
- toolbarButton1
events:
button1_onclick(object sender,EventAgs e)
{
MessageBox.Show(datetimePicker1.Value.ToString("yyyy-MM-dd"));
}
toolbar_onclick(...)
{
if(e.Button == toolbarButton1)
MessageBox.Show(datetimePicker1.Value.ToString("yyyy-MM-dd"));
}
test:
suppose the original value of the datetimepicker is:2006-10-12
and now enter a number 11 into the month-part of the datetimepicker,then click button1,a messagebox shows:2006-11-12,not 2006-10-12.
and follow the step,enter another number:9 into the month-part of the datetimepicker,and click toolbarButton1,a messagebox shows a value also,however it's not 2006-09-12(normally it should be this),it's 2006-11-12.
for this,I conclude that datetimepicker's value is not synchronous with the mannual input from keyboard,after it's not out of focus,then value will be updated.after input,for button1,when I click it,it will occur that datetimepicker will be out of focus,however toolbarbutton1 not.so this is the difference between button and toolbarbutton,and the difference leads to a wrong value when getting datetimepicker's value in both events.
and who can tell me how to resove the problem?
much thanx~
|
|
|
|
|
Maybe the following helps you out. At least it gets rid of duplicate code.
toolbar_onclick(...)
{
if(e.Button == toolbarButton1)
button1.PerformClick();
}
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
adding some buttons can resove the problem,but it seems awkward and duplicate.
thank you very much anyway.
|
|
|
|
|
Hello,
I would like to a create a user control which composed of two basic controls, control1 and control2.
I was wondering, if i can program the user control in a way that when I use the control in an another project, I could, IN DESIGN TIME, disapear one of the inner controls. i.e. there would be a proprety of the control that would control the visiblty of the controls (e.g. a pull down that would say control1, control2, both, none).
Thanks.
|
|
|
|
|
I think you can add a property:ViewType(enum) for it.
control1 and control2's visiblity can be based on the property,and you can also re-draw the width and border for it.
|
|
|
|
|
How can we check if a control has event handler assigned for that perticular event?
e.g. Suppose I want to whether the a browser control has DocumentComplete event assigned or not.
if I check as
if(webbrowser1.DocumentComplete == null)
it gives error as
The event 'DWebBrowserEvents2_Event.DocumentComplete' can only appear on the left hand side of += or -=
Mandar.
|
|
|
|
|
You need to subscribe a delegate method to this event handler.
First, define a method like
public delegate void WebBrowserDocumentCompletedEventHandler (
Object sender,
WebBrowserDocumentCompletedEventArgs e
)
and then subscribe by
webbrowser1.DocumentComplete += WebBrowserDocumentCompletedEventHandler;
Regards,
Dirk
|
|
|
|
|
Fine, Dirk.
But In my application, I am invoking a seperate thread to dispose all the web controls that have been utilized. I need to somehow check in that thread whether the browser is having an event handler assigned. and if so first detach the same and then make the object null.
If you could tell, it would be better.
|
|
|
|
|
Fine, Dirk.
But In my application, I am invoking a seperate thread to dispose all the web controls that have been utilized. I need to somehow check in that thread whether the browser is having an event handler assigned. and if so first detach the same and then make the object null.
How to go about it?
|
|
|
|
|
Sorry, Mandaar. I read your post too hurrily.
Yours, Dirk
|
|
|
|
|
Hi,
Working in c# .NET 1.1 Windows Forms.
I'm getting "Overflow or underflow in the arithmetic operation" error when changing font color/size after calling a class from a .dll file. My research suggests that the unmanaged code has changing the Floating-Point Control Register. Does anyone have C# code to reset Floating-Point for all Form controls?
Thanks,
Ron
|
|
|
|
|
I've load an assembly with Reflection , I have a class named Agent which is in assembly , and I've create an instance of it with CreateInstance() , but I can't cast it to its interface(IAgent ) , do you have any idea about this dynamic casting in C#(.net 2)?.
Thanks
Mazy
"One who dives deep gets the pearls,the burning desire for realization brings the goal nearer." - Babuji
|
|
|
|
|
Mazdak wrote: I can't cast it to its interface
What exactly does that mean? Are you getting an exception at runtime (what does it tell you) or maybe a compiler error? Furthermore it would be helpful to post a small snippet with the relevant code so we are able to see what exactly you're trying to do.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
hello every one,
i wante some books and cds to learn mor and mor about c#.net and asp.net if it vilable
ashraf hakiem
|
|
|
|
|
.Net complete reference is prefered.
IlangoGandhi
|
|
|
|
|
Here's is what i want!
The windows service has to perform some task automatically and repeatedly.
For example,I want to have some code in the Windows service that will read all xml
files from the location "c:\Xmldata" and update those xml files to some
Sql server database and delete those files.After this process is
complete(or after some time) again check the location if new files have
been written and then perform read-update and delete.
I am not sure whether I can do this with Windows Service.
If I can,
My main query is where(and optionally,how) in the Windows service should i write the code to have my task done.
Thanks for your time and Consideration.
and thanks for suggestions/Comments, if any.
|
|
|
|
|
hi,
try this link
http://www.codeproject.com/dotnet/simplewindowsservice.asp
Thanks & Regards...
Amit
|
|
|
|
|
Hi!!
The link you provided is just a walkthrough of creating a simple windows service that practically does nothing other then lending itself to be controlled through Windows Service Manager.
What I had envisioned was to perform my tasks in a continuous loop within the OnStart() method.But I have come to know that "the OnStart method must return to the operating system once the service's operation has begun. It must not loop forever or block."
So, I am in confusion where in the windows service skeleton should i put the code to perform my task repeatedly.
Thanks, as always
Rabindra Gh.
|
|
|
|
|
Hi
Is there any code available for sending polish characters in email in .net
|
|
|
|
|
Hi
Is there any code available for sending polish characters in email in .net
examples of few polish characters is this
Jabra BT5010: More voice - Less noise
Drodzy Państwo,
Szybka i klarowna komunikacja jest niezbędna w biznesie, dlatego włąśnie stworzyliśmy słuchawkę Jabra BT5010.
Ramię sliding boom poprawia jakość transmitowanego dźwięku. Ustawienie mikrofonu bliżej ust ułatwia przechwytywanie głosu i niweluje szum otoczenia
Wpływ podmuchów wiatru na komunikację jest redukowany dzięki aerodynamicznym kształtom
Nowy, modelowany pałąk zauszny pozwala na idealne dopasowanie słuchawki każdemu użytkownikowi – na lewym lub prawym uchu
Programowalne przyciski głośności pozwalają na dostosowanie dźwięku do własnych potrzeb i upodobań
|
|
|
|