Hi all, I have a combo-box consisting of 30 elements. I want the elements from 1-12 enabled , and the rest(13-30) disabled and also once the user selects the disbaled items , the combo box should take care of not selecting the options How could I do this .. Regards, Veeresh
Veeresh Hiremath
Posts
-
Disabling some items in CCombobox -
Disbaling context-menu option on dialog elementsI have dialog box which has some 11 edit-box and 3 combo-box. Now for all these i have to disable the context-menu option, when the right click is clicked on these elements. How can i do this?
-
Bringing child window on top of model-less dialog box in a MDI applicationHow can I bring a child window on top of model-less dialog box in a MDI application.Plz let me know the solution/alternatives to overcome this.
-
closing the opened dialog from cchildframe::OnClose()Hi all, My application is an MDI application I have an "open" button in one dialog box , which upon click, opens up a child window . But one i close the child window , i need to close the dialog also . I know that i should handle within the CChildFrame::OnClose() function,but i dont't know how to get the dialog handle and close it. I have tried creating CMydialog *dlg in the CChildFrame class and invoking dlg->ShowWindow(SW_CLOSE), but the dialog is not closing Could you please tell me how to overcome this problem
-
bitmap in buttonfirst go to button properties and change the properties at the styles tab to icon. Then create a CButton variable for the IDC_BUTTON name and then just use seticon()
-
closing the splash-screen when any keyboard key is pressedIn my start-up i have a splash-screen which waits for 30 seconds and then the main application starts up. Now i have to do this :-- Within this interval if any keyboard key is pressed i want to hide/close the splash-screeen and move to the application directly I have implemented the splash-screen as : BOOL CSplashWnd::ShowSplashScreen(UINT uTimeOut, UINT uBitmapID, CWnd* pParentWnd /*= NULL*/) { ASSERT(uTimeOut && uBitmapID); if (!m_bShowSplashWnd || m_pSplashWnd != NULL) { return FALSE; } // Allocate a new splash screen, and create the window. m_pSplashWnd = new CSplashWnd; if (!m_pSplashWnd->m_bitmap.LoadBitmap(uBitmapID)) { return FALSE; } BITMAP bm; m_pSplashWnd->m_bitmap.GetBitmap(&bm); CString strWndClass = AfxRegisterWndClass(0, AfxGetApp()->LoadStandardCursor(IDC_ARROW)); if (!m_pSplashWnd->CreateEx(0, strWndClass, NULL, WS_POPUP | WS_VISIBLE, 0, 0, bm.bmWidth, bm.bmHeight, pParentWnd->GetSafeHwnd(), NULL)) { TRACE0("Failed to create splash screen.\n"); delete m_pSplashWnd; return FALSE; } // Center the window. m_pSplashWnd->CenterWindow(); m_pSplashWnd->UpdateWindow(); // Set a timer to destroy the splash screen. m_pSplashWnd->SetTimer(1, uTimeOut, NULL); return TRUE; } where CSplashWnd is derived from CWnd Can any body plz tell me how to do it?
-
Bringing child window foreground and model-less dialog backgroundThanks for the information.
-
Bringing child window foreground and model-less dialog backgroundI have a dialog box on start-up of the application . when a button is clicked on the dailog box , it pops up an MDI child window which is displayed at the background.
-
Bringing child window foreground and model-less dialog backgroundI have an MDI application. In these , i have a model-less dialog box with a button which when clicked opens up a child window in the background of the dialog box How can i make the child window to appear foreground and dialog box to appear background when the button is clicked
-
How to get the keyboard inputsHi all, My application uses a spalsh screen for about 30 seconds and then the main window appears. During these if the user types any keyboard key ,the main window should appear immediately. My code looks like this: // *************** SPLASH SCREEN *********************** // create a temp. invisible wnd. as parent of splash screen if(m_wndOwner.m_hWnd == NULL) { LPCTSTR pstrOwnerClass = AfxRegisterWndClass(0); if ( !m_wndOwner.CreateEx(0, pstrOwnerClass, _T(""), WS_POPUP, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, NULL, 0) ) return FALSE; } int nDelay = 30000; // Create and show the splash screen. CSplashWnd::ShowSplashScreen(nDelay, BMP_MICATECH_BIG, &m_wndOwner); Sleep(nDelay) ; Can any one tell me how to overcome these problem? Regards, Veeresh
-
Updating text from another class_AnShUmAn_ I am newbie to vc++/mfc. Can u please send me a skeleton code
-
Updating text from another classHi all, Can u please tell me how to update an edit-box field present in a model-dialog from another class I have used CUsatDlg *dlg= new CUsatDlg; HWND hdlg =dlg->m_hWnd; SetDlgItemText(hdlg,IDC_SERIALNO,"Serial"); UpdateWindow(hdlg); Where CUsatDlg is mu dialog box class ,and IDC_SERIALNO is my edit box field But the edit-box is not displaying the text
-
A single dialog box to show all the data from the device using serial port RS-232Hi friends, My application consists of an interaction b/w the GUI and a RS-232 serial port communication with a embedded device. Initially we had a GUI menu based, where depending upon the user click on the GUI , we used to send and receive the messages from the device. Now, we have a requirement where we need to have a single start-up dialog box instead of a menu for each selection.These means now we have to show all the data from the device initially to the user. For example say , when the user clicks View->ConfigDialog menu option i have to pop-up a dialog box showing all the data from the device Could you please help me regarding this. Regards, Veeresh
-
USB-Serial adpater and normal serial communicationHi friends, I have an application built using VC++ 6.0 . In these we incorporate serial communication using rs-232 serial port and also thru USB-Serial adapater Now ny requirement is to put a small delay only when the application runs thru USB-Serial not when normal serial communication is used to run the application. These delay is have to do since the data transfer thru USB-Serial is faster as compared to normal serial Now can u please tell me how to find whether the application is running thru USB-Serial or Normal Serial port.
-
How to save the toolbar settings and selectionHi all, I have an mdi application ,and here i have about 11 toolbars .All these toolbar are created a variable of CToolBar and then using the CreateEx() in the mainframe.cpp file,loaded all the toolbar . Now i have a menu called "Toolbar" in my application which selects/checks the toolbar WS_VISIBLE and checks/unchecks the toolbar .So when i check ,say any one toolbar,it shows at first instance,and if i uncheck ,it hides. Now i want to save these settings, so that once i close the application and opens it again,i get only the toolbar shown which are selected initially before the application closes. "In short,I want to display next time,only the toolbar which are checked . Please get me out of these problem(;
-
child windows are not being updated + mdithanks:)
-
child windows are not being updated + mdi:(I have an MDI application and once i open two or more child windows/views at a time, then the data are not updated and are not affecting on the child windows. Could any one help me out? -- modified at 7:55 Friday 14th April, 2006