C# :: WPF Menu Item Not Clicking?

Nov 10, 2014

I have made a menuitem using the combo box, but when I add items in like in the image below:

[URL]

My problem is that when I move my mouse over the item it displays this darker box around the text:

[URL]

This stops me from clicking it and the code from being executed.

View 2 Replies


ADVERTISEMENT

Visual C++ :: Enable / Disable Menu Item 2 In OnUpdate Handler Of Menu Item 1?

Sep 15, 2014

I have two menu items. When item 1 is disabled, I want item 2 to be disabled as well. In the OnUpdate handler of menu item 1, I have tried to use "t_pMenu = pCmdUI->m_pMenu;", "t_pMenu = pCmdUI->m_pSubMenu;" and "t_pMenu = pCmdUI->m_pParentMenu;" but I always get NULL t_pMenu. How can I achieve this purpose?

Code:
void CDummyView::OnUpdateMenuItem1(CCmdUI* pCmdUI)
{
if(m_bShowMenuItem1) {
pCmdUI->Enable(TRUE);

[Code]....

View 14 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

C++ :: Enable / Disable Menu Item

Nov 19, 2013

I have ploughed through the exchanges in all the forums, yet I still cannot make it work. The following is a tiny Code::Blocks program, written to isolate the problem:

// resource.h
#define IDR_MYMENU101
#define ID_FILE 102
#define ID_DISABLE103
#define ID_ENABLE 104
#define ID_MESSAGE105
#define ID_EXIT106

[code].....

case ID_ENABLE is similar to case ID_DISABLE above, and neither works. case ID_MESSAGE and case ID_EXIT both works as expected.I have tinkered with EnableMenuItem(), but without success.

View 8 Replies View Related

C# :: How To Get The Selected Context Menu Item

Sep 7, 2014

how to create a context menu but none of them discuss how to actually fetch the selected menu item?

if (e.Button == MouseButtons.Right)
{
ContextMenu m = new ContextMenu();
m.MenuItems.Add(new MenuItem("Font Size 8"));
m.MenuItems.Add(new MenuItem("Font Size 9"));
m.MenuItems.Add(new MenuItem("Font Size 10"));
m.Show(listBoxChecklist, new Point(e.X, e.Y));
//tempString = m.?????
}

View 3 Replies View Related

Visual C++ :: Menu Item Separator

Aug 6, 2014

I'm using this tutorial for making an owner draw menu. [URL] ...

When I go into the .rc file and remove all of the MENUITEM SEPARATORs all the menu options are squished to the left of the menu as in the screenshot. As long as there is just one MENU SEPARATOR anywhere the menu is fine. If I could make the application without MENU SEPARATORs that would be awesome.

View 7 Replies View Related

C# :: Add New Item To A Folder Right Click Menu Using Registry

Feb 25, 2015

I know how to add a new item to a folder right-click menu, using the registry, but it won't show up on file right-click menu. give me a link to how this is done? I want this new menu appear on every file R-C menu, file registered with the system or not. Is there a simple way to do this as adding a item to folder R-C menu, or will i have to iterate all the registered file types in registry to do it. I tried google with many search terms, but i can't find a source for this.

View 8 Replies View Related

Visual C++ :: Menu Item To Explore Current Path

Feb 21, 2015

I quite often use an ide written in assembler: RadAsm3[URL] .....

It has a menu item to explore current path. I have used other ide's that have a similar feature but:

The one in RadAsm3 will activate a current Explorer window if the current path is the same as the one requested.
All others open a new Explorer window.

I would like to implement the RadAsm3 approach using Visual Studio 2013 Community c++ as my host compiler for testing.

I tried to get the title of current windows but it appears ShellExecute "explore" does not produce a conventional window???

View 1 Replies View Related

C++ :: Menu Program Broken Down Into Series Of Calls To Function For Each Of Menu Items

Aug 19, 2013

I am trying to write a menu program that will be broken down into a series of calls to function for each of the menu items. Two of the menu items will be simple programs which I wrote.

I want two of the functions to run one of the two programs I am trying to include as items in the menu.

So far I am only familiar with variables, loops, if statements, and I just learned how to write functions.

The problem I am have is that I don't quite understand how to write a function that will run one of the two programs. Also I am having a hard time writing the program in away that would allow the user to select the menu items.

View 2 Replies View Related

C :: Program Based On Menu System - Option To Go Back To A Previous Menu

Apr 7, 2014

I'm creating a program that is based on a menu system. Basically each menu is its own user-defined function. The problem is at each menu you can input 'b' to go to the previous menu. I just have it call the function of that menu.

However, do the functions need to complete themselves eventually? If I just keep calling functions will I just keep going further and further deeper into ever running functions?

If so how do I avoid this and yet keep the option to go back to a previous menu/function?

View 2 Replies View Related

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++ :: 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 View Related

C/C++ :: Creating A Menu That Will Return The Menu After A Selection

Apr 7, 2014

This is what I have so far, it gives me a nice menu to select from and it all works but after I make a selection it closes the program. I tried to return to it but it won't work for me

#include <stdio.h>
int main() {
int choice;
int deposit;
int balance = 500; {
printf(" CHOOSE FROM THE FOLLOWING

[code]....

View 14 Replies View Related

C# :: (Grid) Stop User From Clicking Past A Certain Amount Of Block

May 21, 2014

0
down vote
favorite

So, I'm attempting to create a grid on the screen, and to do so, I've implemented a multidimensional array of Rectangles. When the program starts, I use a for loop to increase the x and y coordinates to form the grid.

public Form1() {
InitializeComponent();
for (int x = 0; x < 12; x++) {
for (int y = 0; y < 12; y++) {

[Code] ....

My issue is trying to figure out when the user has clicked on a rectangle, and furthermore, which rectangle in the array that he/she has clicked on. As I will change the border to red when given the correct rectangle.

I'm using Visual Studio 2008, and here is my code so far.

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;

[Code] .....

I'm making this into a real game, with classes and all.

View 7 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 :: Returning Value For Item To Variables?

Mar 4, 2014

What the code below is not doing is returning a value for item to my variables (item1, item2, etc..) I'm not sure how I can make a function prototype that will ask for input and basically recycle after going through the program to a new value for each item. I also need to input individual tax for each item. I will also post it in this message:

double tax, item,salesTax;
double cost(double);
double CalcSalesTax(double);
main(){
double total,item1, item2, item3, item4, item5, tax1, tax2, tax3,tax4,tax5;

[Code].....

View 13 Replies View Related

C :: Removing Item From A Queue

Aug 17, 2014

I'm having a problem with removing an item from a queue. At first in the debugger I got SIGTRAP but I don't get it anymore but the problem still exists. When you try to remove an item from the queue the first nothing happens. Here's the code below compile it and you see what I'm talking about.

Code:

#include <stdio.h>
#include <stdlib.h>
struct Node {
char let;
struct Node *nextNode;
};

[code]....

View 12 Replies View Related

C++ :: How To Search For An Item In The Array

Jun 29, 2014

If the item is in the array. Count how many times it is stored in the array and what are their respective array locations.

How can I add this output in my program.

Here's my code...

int array[15]={28,3,16,4,3,16,5,8,4,12,5,4,8,21,40};
int x=0;
int done=0;
int item;

cout<<"Input an item to be searched:";
cin>>item;

[Code] ....

This should be the output:

Item to be searched: 4
number of occurence : 3
array locations : 3 8 11

View 3 Replies View Related

C# :: Get Item From List In Another Class

Jan 15, 2014

How can I get the items from a list into textboxes. I am doing an windows form application in visual studio.

I have the first form with a couple of textboxes.

I want the inputs be saved in a list. And then displayed in another form. How to move on. The class with the list looks like this:

public class Casecs {
public List<caseInformation> fallInformation = new List<caseInformation>();
public class caseInformation {
public string caseId { get; set; }
public string phoneNumber { get; set; }
public string description { get; set; }
}

Then the form with the inputs in textboxes looks like this:

Casecs Casecs = new Casecs();
Casecs.fallInformation.Add(new ERIS.Casecs.caseInformation {
caseId = txtCaseId.Text,
phoneNumber = txtPhonenumber.Text,
message = txtMessage.Text
});

Then where I am stuck a form with some textboxes where I want the list items to be displayed:

public partial class btnDispatch : Form {
public btnDispatch() { }
public btnDispatch(List<Casecs.caseInformation> fallInformation) {
InitializeComponent();

View 7 Replies View Related

C# :: Run SQL Query For Each Item In Listbox?

Aug 2, 2014

I have a C# WPF program that takes a SQL query and populates a column from an Oracle database into a listbox on the form. I would like to be able to compare all items populated in the listbox, and run a SQL query for each item, populating those values into a different listbox.

So far, I have this code:

string sql2 = "select unique apps.fnd_application_all_view.application_name, fnd_responsibility_vl.responsibility_name, fnd_form_functions_tl.user_function_name, fnd_form_functions.function_name, fnd_form_functions_tl.description, fnd_form_functions.type FROM fnd_compiled_menu_functions, fnd_form_functions, fnd_form_functions_tl, fnd_responsibility, fnd responsibility_vl, apps.fnd_application_all_view WHERE

[code]....

I would like to be able to basically take the "Responsibility_Name" value from the first listbox (lstResponsibilities), which is already populated, and use those values to in the "sql2" query to find the "Function_Name" and populate "Function_Name" in the second listbox (lstFunctions).

View 5 Replies View Related

C++ :: Erasing Item From A Vector

Oct 28, 2014

Here is the code,

vector<int> v;
v.push_back(4);
v.push_back(11);
v.push_back(34);
v.push_back(5);
v.push_back(14);
v.push_back(32);
vector<int>::iterator next;

[Code] ....

I got a debug assertion error. What might be wrong?

View 8 Replies View Related

C++ :: How To Display Item At Specific Tab Position

Nov 23, 2013

I used VB6 before to output file.

I set my output to file to tab(20) or tab(45) respectively.

In C++, how do I do this?

View 4 Replies View Related

C++ :: How To Insert Item Into Binary Tree

Jun 30, 2013

I am trying to write a function that inserts an item into this binary tree in C++.

template <typename T>
struct BTree {
T val;
BTree<T>* left;
BTree<T>* right;
BTree(T v, BTree<T>* l=nullptr, BTree<T>* r=nullptr) :
val(v), left(l), right(r) {}
};

Here's my attempt.

template <typename T>
void insert(BTree<T>* tree, T item) {
if (tree == nullptr) {
tree = new BTree<T>(item);
} else if (item < tree->val) {
insert(tree->left, item);
} else {
insert(tree->right, item);
} }

I think this function may not be working because I am modifying `tree`, which is a local variable. How do I actually modify the current pointer that `tree` represents, not just `nullptr`?

View 2 Replies View Related

C++ :: Rogue Like Item Creationg And Optimization

Mar 8, 2013

I'm creating a roguelike/ cave exploration game, and I've created a lot of it, but I am having problems with item creation. The item is supposed to be the '*'. I know what the problem is (I'm setting Dmap to map after creating the item, but before outputting Dmap), but I don't know how to fix it.Also, I don't really know how code optimization works.I'll split my code between this post and the comments:

#include <cstdlib>
#include <iostream>
#include <conio.h>
#include <windows.h>
#include <stdio.h> /* printf, NULL */
#include <stdlib.h> /* srand, rand */
#include <time.h> /* time *

[code].....

View 1 Replies View Related

C/C++ :: Program Crashes When Try To Remove Item?

Sep 28, 2014

In my program, I am trying to implement a set in which I can add/remove and print, it doesn't have to be a specific value removed just that it removes an item from the list. When I call the removeItem function it crashes, saying my iterator is out of range. I don't understand what is wrong. Here is my code:

#include "stdafx.h"
#include <iostream>
#include <set>

[Code].....

View 4 Replies View Related

C/C++ :: Random Item Selection From Array?

Sep 6, 2014

I need to select a random item from an array but I am going to have more than 1 such array so I created the random value selector as different function. Right now I am getting a correct value for random function but when I try to access the array value associated with that index I get 2 digits which does not make any sense.

#include <iostream>
#include <cmath>
#include <ctime>
using namespace std;
int randFunction(int size);
int main() {
int heapsize;

[code]....

View 3 Replies View Related







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