Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
A

Artem Moroz

@Artem Moroz
About
Posts
31
Topics
19
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • C++
    A Artem Moroz

    Hi there! I have started this Tax software program for you:

    #include

    using namespace std;

    int main()
    {
    cout<< "Tax software developed by https://iq.direct" << endl;
    cout<< "Enter Salary:";

    double s = 0, t = 0;
    cin >> s;
    
    cout<<"you entered: " << s << endl;
    
    if (s < 600)
    {
        t = 0;
    }
    if (s >= 600 && s < 800 )
    {
        t = s \* 0.1;
    }
    if (s >= 800 && s < 1000 )
    {
        t = s \* 0.13;
    }
    
    cout<< "The tax will be :" << t;
    
    
    return 0;
    

    }

    C / C++ / MFC c++ css career

  • How to add Outlook toolbar under the subject line in C# add-in?
    A Artem Moroz

    I belive yes because I saw other plugins doing such integration.

    C# csharp question asp-net linq com

  • How to add Outlook toolbar under the subject line in C# add-in?
    A Artem Moroz

    I need to write an Outlook 2003-2010 plugin using C# that adds two buttons to the Message Ribbon Bar (#1 on the picture) and a several buttons toolbar or a Form Region under the "Subject" line (#2 on the picture). See image here: http://i.piccy.info/i9/8ccdf69246fbcd9171d488747c6ea189/1398291704/206810/736482/editmessage.png[^] Currently I managed to add a button to the Ribbon toolbar, but it appears in the "Add-ins" Ribbon Bar. How do I add buttons to the "Message" Ribbon Bar? And how do I add the Toolbar #2 ? I currently have no clue about how to add it. Please help me! I now have the following code:

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Xml.Linq;
    using Outlook = Microsoft.Office.Interop.Outlook;
    using Office = Microsoft.Office.Core;
    using System.Windows.Forms;

    namespace SendLaterToolbar
    {
    public partial class ThisAddIn
    {
    Office.CommandBar newToolBar;
    Office.CommandBarButton firstButton;
    Office.CommandBarButton secondButton;
    Outlook.Explorers selectExplorers;
    Outlook.Inspectors inspectors;
    Office.CommandBarButton _objEmailToolBarButton;

        private void ThisAddIn\_Startup(object sender, System.EventArgs e)
        {
            selectExplorers = this.Application.Explorers;
            inspectors = this.Application.Inspectors;
            selectExplorers.NewExplorer += new Outlook.ExplorersEvents\_NewExplorerEventHandler(newExplorer\_Event);
            inspectors.NewInspector += new Microsoft.Office.Interop.Outlook.InspectorsEvents\_NewInspectorEventHandler(AddToEmail);
            AddToolbar();
        }
    
        private void newExplorer\_Event(Outlook.Explorer new\_Explorer)
        {
            ((Outlook.\_Explorer)new\_Explorer).Activate();
            newToolBar = null;
            AddToolbar();
        }
    
        private void ThisAddIn\_Shutdown(object sender, System.EventArgs e)
        {
    
        }
    
        private void AddToolbar()
        {
    
            if (newToolBar == null)
            {
                Office.CommandBars cmdBars =
                    this.Application.ActiveExplorer().CommandBars;
                newToolBar = cmdBars.Add(
    
    C# csharp question asp-net linq com

  • Keyboard navigation
    A Artem Moroz

    Hi I'm trying to design a control, derrived from CStatic with keyboard navigation support. When user press the Tab button I call GetNextDlgTabItem and then SetFocus, but, for example, if the next control in tab order is button it draws inproperly - the focus rect is drawn, but the button does not look as default.

    C / C++ / MFC design tutorial

  • Destructing an exception
    A Artem Moroz

    call pExc->Delete() inside catch block

    C / C++ / MFC help com tools question

  • How to determine whether master volume is enabled?
    A Artem Moroz

    I'm using class CVolumeOutMaster - it sets and gets master volume. The class could be found here: http://www.codeproject.com/audio/volumeclasses.asp It determines the volume like this:

    DWORD CVolumeOutMaster::GetCurrentVolume()
    {
    if ( !m_bAvailable )
    return BAD_DWORD;
    MIXERCONTROLDETAILS_UNSIGNED* aDetails = (MIXERCONTROLDETAILS_UNSIGNED*)malloc(m_nChannelCount*sizeof(MIXERCONTROLDETAILS_UNSIGNED));
    if ( !aDetails )
    return BAD_DWORD;
    MIXERCONTROLDETAILS ControlDetails;
    memset( &ControlDetails, 0, sizeof(MIXERCONTROLDETAILS) );
    ControlDetails.cbStruct = sizeof(MIXERCONTROLDETAILS);
    ControlDetails.dwControlID = m_dwVolumeControlID;
    ControlDetails.cChannels = m_nChannelCount;
    ControlDetails.cMultipleItems = 0;
    ControlDetails.cbDetails = sizeof(MIXERCONTROLDETAILS_UNSIGNED);
    ControlDetails.paDetails = &aDetails[0];
    MMRESULT mmResult = mixerGetControlDetails( (HMIXEROBJ)m_dwMixerHandle, &ControlDetails, MIXER_GETCONTROLDETAILSF_VALUE );
    DWORD dw = aDetails[0].dwValue;
    free( aDetails );
    if ( mmResult != MMSYSERR_NOERROR )
    {
    TRACE(".MasterOutputVolume: FAILURE: Could not get volume. mmResult=%d\n", mmResult );
    return BAD_DWORD;
    }
    return dw;
    }

    How to determine whether master volume is enabled or disabled?

    C / C++ / MFC com debugging tutorial question

  • Strange file corruption
    A Artem Moroz

    I already did. The problem Is that when the program is terminated incorrectly, the garbage appears inside a file sometimes.... You see, the Close() is not called in such a case :(

    C / C++ / MFC help tutorial question

  • Strange file corruption
    A Artem Moroz

    I have a class that represents a log file. This class has two functions and a member variable CFile m_file First is StartLog conains code m_file.Open(.....); Second StopLog contanis code m_file.Close(); And also there is a function AddEvent like this: m_file.Write(.....); m_file.Flush(); I call StartLog when my program starts, and StopLog when it exits. AddEvent is called several times while program runs; It works fine mostly, but there is a problem: File gets corrupted (it contains junk) when the program gets terminated incorrectly. For example when somebody has rebooted computer or terminates it via task manger. (Close() is not get called in this case) Should I reopen and close file every time I need to write to it to ensure safety of the data??? :confused:

    C / C++ / MFC help tutorial question

  • How to get icon given a file extension?
    A Artem Moroz

    How to get icon that corresponds to given file extension ? I can't use SHGetFileInfo because file may be not on my hard drive but on FTP server.

    C / C++ / MFC sysadmin tutorial question

  • visual assist .net
    A Artem Moroz

    try to search at astalavista.box.sk

    C / C++ / MFC csharp help question

  • capture packets at the device
    A Artem Moroz

    Use PCAP library

    C / C++ / MFC c++ sysadmin linux data-structures help

  • I need help about how to use OpenSSL library.
    A Artem Moroz

    I need help about how to use OpenSSL library. Is there any sample on the Web I can use ?

    C / C++ / MFC help tutorial question

  • How to fix compiler warning ?
    A Artem Moroz

    I have reduced warning level to 3, and this warning does not appear. Thanks for help!

    C / C++ / MFC help tutorial question

  • How to fix compiler warning ?
    A Artem Moroz

    I have the following code: void* fixaddr; DWORD delta . . . *((WORD *)fixaddr) += HIWORD(delta); . . . During compilation I get the following error: warning C4244: '+=' : conversion from 'int' to 'unsigned short', possible loss of data Since I don't want any warnings appear in my code I wonder how to fix this ?

    C / C++ / MFC help tutorial question

  • Problem with a property sheet
    A Artem Moroz

    I have a problem with a property sheet I am creating property sheet insde a dialog this way: BOOL CMyDlg::OnInitDialog() { CDialog::OnInitDialog(); m_propsheet.Create(this, WS_CHILD | WS_VISIBLE, 0); m_propsheet.ModifyStyleEx (0, WS_EX_CONTROLPARENT); m_propsheet.ModifyStyle(0, WS_TABSTOP); m_propsheet.GetTabControl()->ModifyStyle(TCS_MULTILINE,0); CRect rcSheet; GetDlgItem(IDC_PROPSHEET)->GetWindowRect( &rcSheet ); ScreenToClient( &rcSheet ); m_propsheet.SetWindowPos( NULL, rcSheet.left-7, rcSheet.top-7, 0, 0, SWP_NOZORDER | SWP_NOSIZE | SWP_NOACTIVATE ); . . . } In this code I tried to change the style of tab control inside a property sheet, so it would display one row of tabs. It works, but the size of property sheet retains bigger, just like with two rows of tabs, How to fix this ?

    C / C++ / MFC help tutorial question

  • Problem with mutex
    A Artem Moroz

    It works! Thank you for help ! ;)

    C / C++ / MFC help question

  • Problem with mutex
    A Artem Moroz

    I have a problem with named mutex. In my 1st process I am creating mutex CreateMutex(NULL,TRUE,"Process_Running"); // mutex will be automatically deleted when process ends. if(GetLastError() == ERROR_ALREADY_EXISTS) { AfxMessageBox(IDS_ALREADYRUN); } Then, in 2nd process I am try to determine, whether 1st process is running: HANDLE hMutex = OpenMutex(0,FALSE,"Process_Running"); if (hMutex != NULL) { CloseHandle(hMutex); // Do something... } But in this code hMutex is always NULL ! Even if 1st process is running! What am I doing wrong ?

    C / C++ / MFC help question

  • How to put background image into CListCtrl.
    A Artem Moroz

    I've tried to put background image into CListCtrl, but i completely ran out of ideas how to do this!!! I cannot use owner drawn control because I need big icons. I cannot use CListCtrl::SetBkImage() because it cannot stretch bitmap; Maybe this is done somehow by using custom draw, but I failed. Can somebody give me link to working sample with background image? Give me any suggestions!

    C / C++ / MFC graphics tutorial question

  • Keyboard indicator problems
    A Artem Moroz

    I am working now on my own shell wich substitutes explorer.exe. Why do I need ths? - For security reasons :) I am having problems with language switching in WinXP. When I press Ctrl+Shift, the keyborad language supposed to change, but It does not. In Win9x/2000 there is no such problems since keyboard indicator is placed automatically into systray, But this does not work in WinXP! Where can I get info about how to write own keyboard indicator or (even better) find the source code of working sample? :confused: Thanks.

    C / C++ / MFC linux security tutorial question

  • WHY I AM NOT RECEIVING NEWSLETTER?
    A Artem Moroz

    I am not receiving weekly newsletter. Why? I have double-checked "My Settings"! Maybe site admins would answer me?

    The Lounge question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups