Visual C++ :: Clicking On Radio Button Crashing Dialog

Mar 3, 2014

I have an existing dialog, having activex control, list control, tree control checkbox, button etc.... I added one radio button and executed the program. whenever i am clicking on the radio button, the dialog hang/crash. Even simply dragging one radio button from toolbox and executing also behaving in the same way.

View 2 Replies


ADVERTISEMENT

C# :: Clicking A Button In WebBrowser Control?

Jul 8, 2014

I'm getting this strange problem with the webBrowser control that google can't find an answer for. When I click a button I get redirected to a page with just the letters 'e4' makes no sense to me?? is this a site problem or something to do with the webBrowser control?

View 9 Replies View Related

Visual C++ :: Left Button Click On Edit Control In Dialog Box?

Apr 13, 2015

I have a dialog box with several edit control boxes and I want to identify the edit control when I click the left mouse button on it. Any button action (up or down) doesn;t register when the mouse is clicked on any of the edit controls. There has got to be a simple way to do this.

View 1 Replies View Related

C# :: Sharepoint Radio Button Value

Oct 28, 2014

I am working on a website so you can order online for a restaurant. I currently figured out how to get values of all checkboxes and dropdownlists but i still cannot seem to figure out radio buttons.

Right now i am just making a super string with all of the selected values but eventually i am going to want to make a receipt with a checkout page.

//this seems to work alright
XPathNodeIterator toppingIterator = myNavigator.Select("//my:ToppersGroup", NamespaceManager);
s +=+ "";
while (toppingIterator.MoveNext()) {
XPathNavigator node = toppingIterator.Current;
XPathNodeIterator children = node.SelectChildren(XPathNodeType.All);
while (children.MoveNext())

[Code] .....

View 5 Replies View Related

C# :: Selected Radio Button With Database In It?

Feb 24, 2014

I am developing a project that generates questions from a database, the questions are generated with multiple choice answers. On this form I have got a textbox that reds the question from the database and 4 radio buttons that reads the possible answers from the database. The radio buttons text names are updated with records from a database table each time the "next button" is clicked.

What I want this program to do is that when the user selects one of the radio buttons, I want the system to check if the selected radio button textname equals the right answer in the database table. for example in the table there are 5 columns namely: option1, option2, option3, option4 and rightAnswer. So whenever a user selects a radio button, I would like the system to check if the selected radio button's textname equals the record in the "RightAnswer" column and if so I would a messagebox to show "correct" and if not the messgaebox to show "wrong"

This is the the way I am updating the radio button text names from the database This method is called when the form is loaded

void LoadingPossibleAnswers() {
Query = "SELECT * FROM AnswersTbl";
theReader = conn.ExecuteStatement(Query);
while (theReader.Read()) {
radioButton1.Text = theReader["Option1"].ToString();

[code]....

This method is called when the button is clicked

void CorrectAnswer( RadioButton rdb) {
string correct = rdb.Text;
Query = "SELECT * FROM FROM AnswersTbl;"
theReader = conn.ExecuteStatement(Query);
while (theReader.Read())

[code]....

When ever I run my code above, else condition executes even if the correct radio button is selected.

View 3 Replies View Related

C# :: How To Show MessageBox In 2 Radio Button

Oct 21, 2014

I'm trying to do this :

when user chick first radio button a message1 will show with OK button
when user chick second radio button an another message2 will show with OK button

But its didn't work like this. its work like:

1- user chick first radio button
2- message1 will show with OK button
3- user click OK
4- user chick second radio button
5- message1 will show again with OK button
6- user click OK
7- then message2 will show again with OK button

so when user click in second time its show the 2 message the message1 then the message2

this is my code

private void radioButton2_CheckedChanged(object sender, EventArgs e) {
MessageBox.Show("Amount is ... " + money, "Amount" , MessageBoxButtons.OK , MessageBoxIcon.Information);
}
private void radioButton1_CheckedChanged(object sender, EventArgs e) {
MessageBox.Show("Item name : " + arr[0].name ,
"Availability", MessageBoxButtons.OK, MessageBoxIcon.Information);
}

View 3 Replies View Related

C# :: How To Use List Box Based On Radio Button Selection

Jun 2, 2014

How to put together this assignment. Here is the assignment:

The ABC Shipping Company charges the Rates listed in the following table:

Weight of the package (in kilograms) Shipping rate per mile in California Shipping rate per mile other states

2 kg or less $2.0 $2.5

Over2 kg but not more than 6 kg $3.0 $3.5

Over 6 Kg but not more than 10 kg $3.5 $4.0

Over 10 Kg but not more than 30 Kg $4.0 $4.5

Over 30 kg $5.0 $5.5

Create an application that contains two radio buttons to select California or other states, a listbox for the user to select the package’s weight class, a textbox to enter the distance it is to be shipped, and a button to calculate and display the charges on a label control when it is clicked.

Input validation: Do not accept distances of less than 5 miles or more than 3000 miles

This is what I have so far. I don't know how to set up the listbox option for non california or how to set up a formula.

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

[Code] ....

View 3 Replies View Related

C Sharp :: Show Results From Values In Text Boxes On Clicking Or Pressing Tab Button

Feb 21, 2013

I am developing application software.entering two textbox value,while click or pressing tab button in third textbox, the result needs to show in third textbox.

View 1 Replies View Related

C Sharp :: How To Bind WPF Datagrid Radio-button Column To Entities Class

May 7, 2012

In my WPF application I created a LINQ to SQL entities class. Then I created a partial class and there add code to my entity class. Below is the code of it:

namespace Mynamespace {
    partial class rts_index {
        #region Fields  
        /// <summary>
        /// Status:
        /// "Selected" - true, "Unselected" - false.
        /// </summary>
        private bool _is_selected;

[code]....

Then I executed LINQ to SQL. Works perfectly well. Then I bound WPF Datagrid radiobutton column to is_selected property of the partial class. Below is XAML code:

.
.
.
<Window.Resources>
<CollectionViewSource x:Key="rts_indexViewSource" d:DesignSource="{d:DesignInstance my:rts_index, CreateList=True}" />
</Window.Resources>

[code]....

And here I have the problem. When I'm changing the radiobutton status from Unchecked to Checked it doesn't change the value of is_selected property from false to true in the partial class. I don't know why.

View 1 Replies View Related

Visual C++ :: Lag When Clicking MFC File Menu

Jan 9, 2014

I am developing a CFormView MFC app. When I go to click something on the menu, it takes awhile before the event happens. The project is build optimized in release mode. I have 3 additional threads and I thought they might be blocking the internal MFC framework stuff, but I use the Sleep() call in each thread to yield to the MFC main app.

View 7 Replies View Related

Visual C++ :: Crashing On Fstream Open File

Jan 20, 2013

other posts talk about the fopen function and don't really give any solutions to this the var that has the file path is a char* and has been converted from a system::string^ it is completely valid when I paste it in windows bar.

Code:
private: System::Void button3_Click(System::Object^ sender, System::EventArgs^ e) {
if(textBox1->Text[0] == (char)'' || textBox2->Text[0] == (char)''){
MessageBox::Show("Please select a valid m3u and path", "Problem",
MessageBoxButtons::OK, MessageBoxIcon::Exclamation);

[Code]....

it crashes right at the pile.open() function call when I put breakpoints in it says , debug assertion failed and shows me the fclose.c file location and Expression: (stream != NULL)

View 5 Replies View Related

Visual C++ :: How To Set The Parent Dialog

Apr 17, 2013

I've created a modeless dialog from my main dialog as follows:

Code:
m_pContainerDlg = new CDlgContainer(NULL, this);
m_pContainerDlg->Create(CDlgContainer::IDD, GetDesktopWindow());
m_pContainerDlg ->ShowWindow(SW_SHOW);

This container dialog creates a child dialog which I show inside the container

Code:
BOOL CDlgContainer::OnInitDialog(){
// Create the child dialog and show it
m_pChildDlg = new CChildDlg(this);
m_pChildDlg->Create(IDD_DIRECTORY_DIALOG, this);
return FALSE;
}

From my child dialog I then create a modal dialog when a user clicks on a button

Code:
CChildDlg:: CChildDlg (CWnd* pParent /*=NULL*/) :
m_pParent((CDlgContainer*)pParent), {
} void CChildDlg::OnBnClickedBtn() {
CMyDlg MyDlg;
INT_PTR iResult = MyDlg.DoModal(pParent);
}

My problem is that the CMyDlg is modal but to the main dialog and not to the container or the child dialog.

View 3 Replies View Related

Visual C++ :: Catching A Dialog Box?

Dec 9, 2013

What I want is simple: I want to catch a dialog box!

The dialog box pops very frequently in a website. We have to put a username and password and press OK. I checked with spy++. It doesn't have any child windows. So catching the dialog box with windows API is ruled out. It must be a HTML dialog. I have to get DOM COM interfaces of the dialog.

Another option may be to make an add-on to get the interface to IWebBrowser2 and get the events fired. The title of the dialog box is "Authentication Required". If the events will be fired for that dialog box, I can check the title using IHTMLDocument2::get_Title.But will the events be fired for HTML dialog box? How to catch that desturbing dialog box.

View 2 Replies View Related

Visual C++ :: How To Create A Dialog As DLL

Feb 13, 2014

How can I create a dialog as a DLL ? I have a SDI MFC app (CView is based on CFormView) and from a button I want to load a modal dialog, but that dialog must be developed as DLL ... I didn't find something that fit my needs on internet ... P.S. I have only VC6 !

View 14 Replies View Related

Visual C++ :: FTP With Progress Dialog

Nov 13, 2012

For a project I'm working on, I need to be able to download a file from an FTP server and store it to a predetermined location with a predetermined name. No user interaction should be needed. Because the file is rather large, and I need the main program to remain responsive, this is going to need a progress dialog.

I could write all this myself and use the MFC wininet wrappers (CInternetSession et al) to do the downloading, but... Explorer already has this, and IE has such a dialog also. It doesn't seem unreasonable to assume those dialogs are available via some API.

Is a "FTP download with dialog" available as a windows API, or do I really need to write all this myself ?

View 2 Replies View Related

Visual C++ :: How Many Items Exist In A Dialog Box

Sep 11, 2013

I was wondering how can we know how many items exist in a dialogbox? If there any way that i can get the items ID in a dialogbox by having just the dialogbox's object or handler? Or any way that we can get a dialogbox content by coding.

View 6 Replies View Related

Visual C++ :: MFC Dialog Clipping Off In Low Resolution

Mar 25, 2013

I have an mfc dialog of size 1280 X 1024 and when i change the resolution to 800 X 600, after adding scroll bar, it don't show the entire dialog contents, Seems like it clips the 800 X 600 portion.

I have handled VScroll and HScroll. It works fine for higher resolutions!

View 1 Replies View Related

Visual C++ :: How To Reposition Menu Bar For Dialog Box

Dec 23, 2013

Normally, menu bar resides below the title bar. See attachment MenuBarOriginal.JPG

Is there a way that we can position the menu bar? For example,place it on the side or anywhere on the dialog box?

MenuBarModified.JPG is some sample of menu bar positions that I want to place.

I want to do this on a dialog box.

View 6 Replies View Related

Visual C++ :: Pass Parameter In Dialog Box

Feb 12, 2014

I need to pass a variable to a dialog box.

Code:
Doc* pDoc;
Dialog dlg;
int input = dlg.DoModal();

When I call dlg.DoModal() I need to somehow pass the pDoc into the dialog box. Everything I need the variable for is taking place inside the oninitdialog function. Is there anyway to pass the variable to that function?

View 2 Replies View Related

Visual C++ :: How To Know When Mouse Over A Control In A Dialog

Jul 10, 2013

I forget how to know when mouse is over controls in dialog.. I want to show a message in status bar when mouse over each control...

View 1 Replies View Related

Visual C++ :: CListCtrl On Dialog - Row Selection?

Aug 22, 2014

I have a ListCtrl on my dailog. It has a report view. In my case I have selected first row with left click of mouse and entire row is displayed in blue color as selection (as per expected) and when I right click the second row of the listctrl it displays the menu which I have added to it and the selection remains with the first row.(as expected). I have already overridden the ListCtrl class.

I want that on the right click of second row the selection should remain with the first row but this second row also should be displayed with dotted line border.

View 1 Replies View Related

Visual C++ :: Child Dialog Shadow Remains?

Oct 5, 2012

i open child dialog from a dialog( which is launched from a toolbar of a window) after editing i close the child dialog, after closing child dialog shadow is retained on window but not on the parent dialog. Later when i close the parent dialog the child dialog shadow disappears. (issue exist only when i edit in child dialog)

View 14 Replies View Related

Visual C++ :: How To Pass A Struct To A Dialog (WinAPI)

Feb 28, 2013

I want to pass some parameters to a dialog. I am trying to pass a struct as LPARAM in CreateDialogParam. How to access this structure from ONOK for example?

Code:
struct DlgParam{
std::wstring IEDllPath;
CString folderName;
};

[Code] .....

View 7 Replies View Related

Visual C++ :: Slider Not Working Properly In A Dialog MFC?

Jul 3, 2013

I have a slider control on a dialog box. I am playing a video file and slider moves according to the video elapsed. Suppose I have set the slider range to 100. Now till some point say 90, the slider moves to the point wherever I click the mouse. but at the last point in between some range say 90 - 100 (to the end of the slider), if I click the mouse button anywhere, slider jumps to the end.

I am using a TimeLine control where user can add more than 1 video (1, 2, 4, 8, 10 , 50 etc......), If I use only one video, slider moves as per the video progression.....Issue arises when I add more than 1 video and click on the start button, slider starts moving....Now when I drag the slider to any position or I click the mouse button anywhere on the slider control, slider thumb moves to that position and immediately jumps back to some other position. This is the Issue, I am facing.

share some sample code where slider is moving with the video showing the progress of the video.

I want to implement a functionality similar to VLC player. Wherever user clicks the mouse, slider moves to that point.

View 13 Replies View Related

Visual C++ :: Intercept Messages Sent To Controls On A Dialog

Apr 8, 2013

If it is possible, I'd like to know how to intercept messages sent to controls on a dialog. I'm working on a large application with a large number of dialogs, each with a number of controls on the dialog. I need to be able to intercept messages sent to these controls so that I can determine if the controls really need to take action on these messages. I could subclass each control and override the specific event handlers but due to the volume of controls in the application this could take a very long time, will introduce risk if controls are missed, and will increase maintenance costs. What I want to do is create a class which is derived from CDialog and each of the dialogs in the application would then be derived from this new dialog class. The new dialog class would intercept messages sent to any control on the dialog and if the dialog decides that the control should do something then the dialog will pass the message on to the control.

example:
CExistingDialog is derived from CNewDialog is derived from CDialog

CExistingDialog has a number of controls. When the code in CExistingDialog calls CWnd::EnableWindow on one of these controls I want CNewDialog to intercept the message, determine what should be done with the message, and then pass it on to the control.

I'm not very familiar with the messaging framework. I've tried overriding a few of the methods of CNewDialog but none of them ever receive the message to enable the window. I assume this is because the message is sent directly to the child window (the control).

Is there any way to intercept these messages? I don't know much about hooks either but is this a possible option?

View 8 Replies View Related

Visual C++ :: Property Sheets On Main Dialog

Jul 17, 2014

I have been playing around with property sheets/property pages and have been successful in getting them to work in a secondary dialog by calling the property sheet using DoModal().

How to get the property sheet to display on the main dialog of a dialog application.

I am using VS2008 and CMFCPropertySheet and CMFCPropertyPage.

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved