|
OK, I have been developing an interface for editing records in our database.
I want to set it up as a control that I can use in other applications I
build. I am using databinding to tie the fields to my controls, such as
labels and textboxes.
I can create a solution for a stand alone application that runs like I want,
but whenever I create a solution for a control, then none of my data shows
up. I have tried making C++ controls (the language I am familiar with) and
VB and even C#. I get the same result: The interface compiles and displays
as designed, but no data.
When I add the control to the toolbox, I get the control plus a dataset and
adapter, but no databinding control.
|
|
|
|
|
Can anyone point me to any articles regarding creating user controls in managed C++? I am interested in reading about how to "subclass" the controls in C++ .NET so they have custom appearance/behavior. I've tried googling but either there is very little out there or I am googling the wrong keywords.
Thanks
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
|
|
|
|
|
dear all,
I have a code in c++. I need to convert the whole project to c. Is it possibe to convert give me the tips for conversion. I will be pleased if there are any tools available for conversion.
regards,
krushna kumar.v
|
|
|
|
|
|
look for the CFRONT compiler. It is the "original" C++ compiler which first converted C++ to C. Google for CFRONT
|
|
|
|
|
Hi, In the description of SetWindowText(), it states that "it cannot change the text of a control in another application." Anyone know what will do this, given the handle of the window has been enumerated ?
Doug
|
|
|
|
|
DougButtimer wrote: Anyone know what will do this, given the handle of the window has been enumerated ?
WM_SETTEXT message
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
Accidently double posted !! Thanks - all sorted !
Doug
|
|
|
|
|
Suppose I have a:
char txt[80];
which holds '1','2','3',' ','4','5','6',' ','7','8';
now I declare 3 ints:
int 1st, 2nd, 3rd;
I want to put into them as follows: 1st==123, 2nd==456, 3rd==78, but the length of each number can be different, eg. txt may also hold: '1',' ','3',' ','5','5','5'
Could you please help me?
thank you in advance
|
|
|
|
|
This is an old-fashioned solution, but try this:
char txt[80];
int first,second,third;
sscanf(txt,"%d %d %d",&first,&second,&third);
Software Zen: delete this; // <a href="http://www.codeproject.com/script/profile/whos_who.asp?msg=1307432&id=10338#xx1307432xx" rel="nofollow">Fold With Us!</a>[<a href="http://www.codeproject.com/script/profile/whos_who.asp?msg=1307432&id=10338#xx1307432xx" target="_blank" rel="nofollow" title="New Window">^</a>]
|
|
|
|
|
hi,
i am writing an application where i want to authenticate the password.
I wan that when user type his password , nothing should be echoed on the screen.
plz help me out
|
|
|
|
|
Did you intend this:-
when the user types something, the characters shouldn't appear?
If yes, then ES_PASSWORD style with the edit control is what you are after.
Vipin - MVP
|
|
|
|
|
hi friend ,
A small program for u.
if u try following program it will display strick when u type password and after passsword press Enter and u can see the password there ....... i think u got an idea to program about passsword if than plz mail so that i can understant that u got it ...
bye
Sudip Lama
//Program about the Password ///
#include<iostream.h>
#include<stdio.h>
#include<conio.h>
void main()
{
clrscr();char name[20];
cout<<"Enter the password"<
|
|
|
|
|
Hi my problem is that i have an VB.NET application and i call an opengl dll MFC application which creates a grafic window and i want when i click on the VB.NET window my opengl window being always on top and not to go in the background, does anyone have any idea?....
Thanks for ur time??
giotis
|
|
|
|
|
Try this
SetWindowPos(&this->wndTopMost,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE);
|
|
|
|
|
Thanks u for ur reply,i put it in the class where this window created,but it show me errors like there r few arguments and it can't recognize "this", one more question:how can i get the hwnd of my window? In msdn i look for the setwindowpos and and i realise that i need this...
if u have time please answer me.....!!!!
Thanks
giotis
|
|
|
|
|
I have recently installed fresh windows and curently i can't check if it is correct, but i think it is GetActiveWindows or FindWindow
|
|
|
|
|
Thanks one more time, maybe i m wrong but i create my opengl window with glutCreateWindow and everything was created with glut expresions, it creates an int type window and i can't convert it to HWND, is there any other way to make it topmost or to make an notopmost my vb.net window?...
giotis
|
|
|
|
|
Hello.
I thing the HWND is a LONG INT, but hwnd is used in c++ not in VB. "this" is a pointer used in C++ and in C#.
|
|
|
|
|
|
The code I gave you was MFC, and you need to convert that to the VB.NET equivalent. I don't know VB.NET so you'll have to ask a VB.NET guy to convert it for you.
|
|
|
|
|
In MFC(dll) i want to put that code because i want to call it from the VB.NET. Here is my code where i create my opengl window and all the values was given by the VB.NET. Any idea guys?
I try to find an expression in glut,glu libraries i didn't find anything!!
I want this window being in front of the VB form!!!!
void
create(int _posx,int _posy,int _sizex,int _sizey)
{posx=_posx; posy=_posy;sizex=_sizex;sizey=_sizey;
glutInitDisplayMode(GLUT_RGB | GLUT_DEPTH | GLUT_DOUBLE | GLUT_MULTISAMPLE);
glutInitWindowPosition(posx, posy);
glutInitWindowSize(sizex, sizey);
//SetWindowPos(hwnd,HWND_TOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE);
main_window = glutCreateWindow( "GLUI Example 5" );
CWnd::wndTopMost;
glui2 = GLUI_Master.create_glui_subwindow( main_window,
GLUI_SUBWINDOW_BOTTOM );
glui2->set_main_gfx_window( main_window );
GLUI_Rotation *cubform_rot = glui2->add_rotation( "CubiForm", CubiForm_rotate );
cubform_rot->set_spin( .98 );
glui2->add_column( false );
GLUI_Translation *trans_xy =
glui2->add_translation( "Objects XY", GLUI_TRANSLATION_XY, obj_pos );
trans_xy->set_speed( .005 );
glui2->add_column( false );
GLUI_Translation *trans_z =
glui2->add_translation( "Objects Z", GLUI_TRANSLATION_Z, &obj_pos[2] );
trans_z->set_speed( .05 );
glui2->add_column( false );
GLUI_Rollout *options = glui2->add_rollout( "Ortho", true );
glui2->add_checkbox_to_panel( options, "Draw Ortho", &show_ortho );
glui2->add_checkbox_to_panel( options, "Reset", &reset,0,(GLUI_Update_CB)mouse);
glui2->add_button( "Quit", 0,(GLUI_Update_CB)exit);
init();
}
giotis
|
|
|
|
|
I am writing a small applet which will read/write data in a binary file. BinaryReader/BinaryWriter is not quite compatible. I figured a mixed assembly of C++/CLI and native code would work perfectly and be educational as well. Unfortunately, all my attempts at doing this have failed. (I might add that if MS wants anyone to use C++/CLI, they need to make the IDE much more friendly to it.)
My preferred way of learning is by examining and stepping through working code. So, can anyone guide me to some a sample project doing something comparable that I can look at and step through?
Anyone who thinks he has a better idea of what's good for people than people do is a swine.
- P.J. O'Rourke
|
|
|
|
|
Hello Joe
Why are the BinaryReader/BinaryWriter classes not suitable?
Also, why don't you just use CreateFile or one of the C or C++ file functions in your code?
|
|
|
|
|
Due to some low level data manipulation that needs to take place before the high level managed classes take over, indicatios are that I will get a huge performance boost by keeping that low level in unmanaged code.
As for CreateFile, that's what I intended to use in the unmanaged portion of the code. The problem is that for all the talk about C++/CLI, I have had a difficult time finding actual working mixed code I can use to learn this stuff. My only solution is to write straight C/C++ based native DLLs and P/Invoke into them from the .NET assemblies.
Anyone who thinks he has a better idea of what's good for people than people do is a swine.
- P.J. O'Rourke
|
|
|
|
|