SetForegroundWindow(IntPtr hWnd) not working when application in notification area.

Hi All,
I create a singleton WPF application, when the application is minimize in the notification area. I double click the application's shortcut to call the application. The application cannot show the Main Window in Screen.
Here is the code:
App.cs
public partial class App : Application
[DllImport("user32.dll")]
private static extern bool ShowWindow(IntPtr hwnd, int nCmdShow);
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool SetForegroundWindow(IntPtr hWnd);
private bool _isNewInstance;
public App()
string appName = System.Reflection.Assembly.GetExecutingAssembly().GetName().Name;
Mutex mutex = new Mutex(true, appName, out _isNewInstance);
if (!_isNewInstance)
Application.Current.Shutdown();
Process process = Process.GetProcessesByName(appName).FirstOrDefault();
if (process != null)
ShowWindow(process.MainWindowHandle, 1);
SetForegroundWindow(process.MainWindowHandle);
MainWindow.cs:
private WinForms.NotifyIcon _notifyIcon;
private WinForms.ContextMenu _contextMenu;
private WinForms.MenuItem _openWindow;
private WinForms.MenuItem _closeApp;
private System.ComponentModel.IContainer _iContainer;
private bool _internalClosing;
public MainWindow()
_contextMenu = new WinForms.ContextMenu();
_openWindow = new WinForms.MenuItem() { Text = "Hiden" };
_closeApp = new WinForms.MenuItem() { Text = "Exit"};
_iContainer = new System.ComponentModel.Container();
WinForms.MenuItem[] menuItems = new WinForms.MenuItem[] { _openWindow, _closeApp };
_contextMenu.MenuItems.AddRange(menuItems);
_openWindow.Click += _openWindow_Click;
_closeApp.Click += _closeApp_Click;
_notifyIcon = new WinForms.NotifyIcon(_iContainer);
_notifyIcon.Icon = new System.Drawing.Icon("Todolist.ico");
_notifyIcon.Text = "Todolist";
_notifyIcon.Visible = true;
_notifyIcon.MouseDoubleClick += _notifyIcon_MouseDoubleClick;
_notifyIcon.ContextMenu = _contextMenu;
InitializeComponent();
private void _notifyIcon_MouseDoubleClick(object sender, WinForms.MouseEventArgs e)
this.Show();
ChangeMenuText(false);
private void _openWindow_Click(object sender, EventArgs e)
this.Show();
ChangeMenuText(false);
private void _closeApp_Click(object sender, EventArgs e)
_internalClosing = true;
this.Close();
_internalClosing = false;
private void Window_Closing(object sender, System.ComponentModel.CancelEventArgs e)
if(!_internalClosing)
this.Hide();
e.Cancel = true;
ChangeMenuText(true);
private void ChangeMenuText(bool flag)
_openWindow.Text = flag ? "Show" : "Hiden";
The Screenshot:
Thanks,
The future belongs to those who believe in the beauty of their dreams.

The FindWindow method should get you the handle to the main window. Try to add the following Startup class to your project and set it as Startup object under Project->Properties:
public partial class App : Application
class Startup
[DllImport("user32.dll", EntryPoint = "FindWindow")]
private static extern IntPtr FindWindow(string lp1, string lp2);
[DllImport("user32.dll")]
private static extern bool ShowWindow(IntPtr hwnd, int nCmdShow);
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool SetForegroundWindow(IntPtr hWnd);
[STAThread]
static void Main()
string appName = System.Reflection.Assembly.GetExecutingAssembly().GetName().Name;
using (var mutex = new Mutex(false, appName + "xyz"))
if (!mutex.WaitOne(TimeSpan.FromSeconds(2), false))
IntPtr handle = FindWindow(null, "MainWindow");
if (handle != IntPtr.Zero)
const int SW_SHOW = 5;
const int SW_RESTORE = 9;
ShowWindow(handle, SW_RESTORE);
ShowWindow(handle, SW_SHOW);
SetForegroundWindow(handle);
return;
App app = new App();
app.MainWindow = new MainWindow();
app.MainWindow.Show();
app.Run();
Please remember to close your threads by marking helpful posts as answer.

Similar Messages

  • Breadcrumb in BSP is not working when application is called inside Portal.

    Dear All,
                We have implemented SAP Learning Solution by integrating it with SAP EP 7.0.
    We called the BSP Application HCM_LEARNING inside portal  using BSP iView template.
    The problem we are facing is, the breadcrumbs in the BSP application "HCM_LEARNING"  is working fine when it is called as a standalone application. But the same is not working when it is called inside portal framework page.
    Enterprise Portal breadcrumbs are working fine.
    How could we resolve this.?
    Regards,
    Eben Joyson.

    this is the radio button
    <af:selectOneRadio value="#{bindings.Gender1.inputValue}"
                                                     label="#{bindings.Gender1.label}"
                                                     required="#{bindings.Gender1.hints.mandatory}"
                                                     shortDesc="#{bindings.Gender1.hints.tooltip}"
                                                     id="sor5">
                <f:selectItems value="#{bindings.Gender1.items}" id="si7"/>
              </af:selectOneRadio>
    i use this sample
    http://download.oracle.com/otn_hosted_doc/jdeveloper/11gdemos/ADF_Insider_Essentials/ADF_Insider_Essential_YesNoRadio/ADF_Insider_Essential_YesNoRadio.html

  • Validation not working when application is in portal

    hi i have a stuation where my unique validation are working when i run application as standalone but when i put application in portal is working ,am adding my application in portal by creating ADF JAR and aadd the jar in my portal,am in jdeveloper 11.1.1.6.0

    am doing validation in entity level
    <validation:UniqueKeyValidationBean
        Name="UamOrganisations_Rule_0"
        ResId=".model.entities.UamOrganisations_Rule_0"
        KeyName="AltKey">
        <validation:OnAttributes>
          <validation:Item
            Value="Organisationname"/>
        </validation:OnAttributes>
      </validation:UniqueKeyValidationBean>
    is still not working even if i set immediate=true
    <af:inputText value="#{bindings.Organisationname.inputValue}"
                                      simple="true"
                                      columns="20"
                                      maximumLength="#{bindings.Organisationname.hints.precision}"
                                      shortDesc="#{bindings.Organisationname.hints.tooltip}"
                                      id="it1" autoSubmit="true" required="true"
                                      immediate="true">
                          <f:validator binding="#{bindings.Organisationname.validator}"/>
                        </af:inputText>

  • MS office report not working when application is compiled (application builder)

    I'm finishing up an application that includes several MS office reports (opens a MS Word template). The template is opened, the bookmarks are filled, then the file is saved (to our internal network) as a .doc file. The New Report.vi is used to open the .doc file, the Print Report.vi is used to print the file, then the SMTP send file.vi is used to email the file.
    Everything has been working fine then I decided to build the application for distribution. Big mistake! An installer is made. When I install the application I get "File not found" (error 7) errors each time I attempt to run this section of code. Incidentally, This app. also uses the SQL database toolset to read and write to a database. No problems with the database.
    I thought it might have something to do with the Word templates being on the network. I copied everything to my local PC and built another application. Same problems.
    I suspect I'm doing something wrong in the Source Files tab of the Build Application or Shared library window.
    I'd really appreciate your help.
    thanks,
    todd

    Most likely, you're looking at a path problem to the template file from the applicaiton.
    When you build a VI into an applicaiton, the path to that applicaiton changes. If originally the VI that calls the template file was located "c:\app\caller.vi", after you build the executable, that same VI will now be located at "c:\app\toplevelVI.exe\caller.vi".
    The executables name will now actually be a part of the path. So you may need to add an extra "Strip Path" function somewhere to get you to the real path to the Excel file. Of course this is just a guess without seeing your code. You could try going back to the LabVIEW code and add a path indicator where you are building the path, then re-build the application and run it so you can see what the path is after it's built.
    Ed
    Ed Dickens - Certified LabVIEW Architect - DISTek Integration, Inc. - NI Certified Alliance Partner
    Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.

  • Development buttons not working when application running

    Hi,
    I am using Apex 4.1. For a new application that i created the buttons which come in the bottom of page (Edit Page1, Application 1, debug etc) are not clickable. They workked for another app in the same workspace.
    Any idea what could be the issue and how to fix it?

    PoojaC wrote:
    Hi,
    I am using Apex 4.1. For a new application that i created the buttons which come in the bottom of page (Edit Page1, Application 1, debug etc) are not clickable. They workked for another app in the same workspace.
    Any idea what could be the issue and how to fix it?It seems you have those buttons but they were not clickable? This suggests that some of your custom JavaScript broke them.
    Do you have any custom js code in your app? try disabling that code and see if the buttons work

  • New Mac: Why are CC and Photoshop Elements not working when Lightroom and Reader are fine

    Last week I changed computers (swapping an old Mac for a 13-in MacBook Pro Retina running OSX Yosemite 10.10.3. I copied all my data over to the new machine using Migration Assistant.
    All programs work fine (including my copy of Lightroom 3 and Reader XI). But my CC and Photoshop Elements 10 do not. I have tried uninstalling both, but whenever I try to reinstall PE10 from its disk or download it just stops almost at the end. I then I get an "initiation failed" message, along with a request to download the now defunct "Support Advisor" app!
    I cannot download Adobe Application Manager, or the CC desktop app either - for the former I get an "initiation failed" message, along with the "download Support Advisor" app" message again! For the latter I get a message saying "Adobe Creative Cloud Is Needed to Resolve this problem - however it is missing or damaged." Then I get a message and a link to download Creative Cloud. Then when I've downloaded it and I click on the installer... it runs for a bit and then I get the message again: "Adobe Creative Cloud Is Needed to Resolve this problem - however it is missing or damaged." And I get a prompt and link to download the CC app. Guess what happens next? And so it goes on. And on and on, in a tedious circle.
    This is incredibly annoying and frustrating as I have work to do! Anyone have any ideas what's happening?
    Cheers
    K

    do not use migration to install adobe programs.
    you should uninstall and clean whatever you've done, Use the CC Cleaner Tool to solve installation problems | CC, CS3-CS6
    then dl the cc desktop app to your new computer and use it to install your adobe cc programs, Download Adobe Creative Cloud apps | Free Adobe CC trial
    if you have non-subscription adobe programs, use the installation files for them:
    Downloadable installation files available:
    Suites and Programs:  CC 2014 | CC | CS6 | CS5.5 | CS5 | CS4, CS4 Web Standard | CS3
    Acrobat:  XI, X | 9,8 | 9 standard
    Premiere Elements:  13 | 12 | 11, 10 | 9, 8, 7 win | 8 mac | 7 mac
    Photoshop Elements:  13 |12 | 11, 10 | 9,8,7 win | 8 mac | 7 mac
    Lightroom:  5.7.1| 5 | 4 | 3
    Captivate:  8 | 7 | 6 | 5.5, 5 | 1
    Contribute:  CS5 | CS4, CS3 | 3,2
    FrameMaker:  12, 11, 10, 9, 8, 7.2
    Download and installation help for Adobe links
    Download and installation help for Prodesigntools links are listed on most linked pages.  They are critical; especially steps 1, 2 and 3.  If you click a link that does not have those steps listed, open a second window using the Lightroom 3 link to see those 'Important Instructions'.

  • My App Store does not work when trying to update applications

    My Apo store does not work when I try to update applications that need to be updated

    There are a number of other threads from people reporting a problem with a blank Updates tab in the App Store app - it looks like there is a problem at Apple's end which they need to fix.
    Some posts are suggesting that you if you go into the Purchased tab in the App Store app you might be able to update the apps from there, though you will need to scroll through the list to find those with updates and individually update them.

  • Application is not working when changing of oracle server domain name

    Hi friends
    We decided to change oracle server domain name due to some reason .. we changed the domain name but application running on the other server cannot connect to this domain i don't know whats the problem . I change the enterprise manager ( emca -config dbcontrol db -repos recreate_) according to the new domain but some of the future not working like date,etc. can anyone help me how to rectify it plz.

    Mohd khalid wrote:
    Hi friends
    We decided to change oracle server domain name due to some reason .. we changed the domain name but application running on the other server cannot connect to this domain i don't know whats the problem . I change the enterprise manager ( emca -config dbcontrol db -repos recreate_) according to the new domain but some of the future not working like date,etc. can anyone help me how to rectify it plz.I am really confused that what's not working? What I have understood is that you recreated the EM repository. So where does "some of the future not working like date,etc." come into it? Are you checking date from EM ? Which application is not working, your application or EM or both or somethingn else? Tell us the complete version, error information and also post the output of
    emctl status dbconsoleHTH
    Aman....

  • ExternalInterface not working when swf file is embed inside a dynamically cloned DIV element.

    ExternalInterface not working when swf file is embed inside a dynamically cloned DIV element.
    It seems that flash movie is identifed as 'undefined' inside document.
    //a statically placed div
    var staticdiv=document.getElementById('PropDiv');
    //dynamically placed div with object tag
    var dynDiv =staticdiv.cloneNode( true );
    var xD=50;
    var yD=50;
    if(dynDiv)
    dynDiv.style.display  = "block";
    dynDiv.innerHTML="<object classid=" + "\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\"" + "codebase=" +
    "\"http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0\"" + "width=" + xD + "height=" + yD +
    "id=" + "\"external\"" + "align=" + "\"middle\"" + ">" +
                    "<param name=" + "\"allowScriptAccess\"" + "value=" + "\"sameDomain\"" + "/>" +
                    "<param name=" + "\"movie\"" + "value=" + "\"external.swf\"" + "/>" +
                    "<param name=" + "\"quality\"" + "value=" + "\"high\"" + "/>" +
                    "<param name=" + "\"wmode\"" + "value=" + "\"transparent\"" + "/>" +
                    "<param name=" + "\"bgcolor\"" + "value=" + "\"#ffffff\"" + "/>" +
                    "<embed src=" + "\"external.swf\"" + "quality=" + "\"high\"" + "wmode=" + "\"transparent\"" +"bgcolor=" + "\"#ffffff\""
    + "width=" + xD + "height=" + yD + "name=" + "\"external\"" + "align=" + "\"middle\"" + "allowScriptAccess=" + "\"sameDomain\"" +
    "type=" + "\"application/x-shockwave-flash\"" + "pluginspage=" + "\"http://www.macromedia.com/go/getflashplayer\"" + "/>" +
                    "</object>";
       dynDiv.style.top=50;
       dynDiv.style.left=100;
    document.body.appendChild(dynDiv);
    In above situation communication is not establised when a  funtion which is retruning boolean is called from flash using
    ExternalInterfcae.call.The return value of this function is getting as false inside flash.But the value is true in javascript.
    if (navigator.appName.indexOf("Microsoft") != -1) {
       return window[movieName];
      } else {
       return document[movieName];
    window["external"] is returning as 'undefined'.
    Please give a  solution to solve this.

    Note that you have different file names for the object (images/banner.swf) and the embed (images/banner1.swf)
    You also placed the embed in the middle of a param tag and nested all param tags.
    Because you didn't include a MIME type and the object doesn't have a classid for an ActiveX control for IE, I'm not sure what Firefox will be using.<br />
    The object doesn't have a data attribute to specify the file.<br />
    A separate embed is only needed when you specify a classid in the object.
    <pre><nowiki><div class="bannercontainer">
    <object width="940" height="445" type="application/x-shockwave-flash" data="images/banner.swf" >
    <param name="wmode" value="transparent" />
    <param name="movie" value="images/banner.swf" />
    </object>
    </div></nowiki></pre>

  • HT203254 my desktop is not working when i open it all it does is show the color weal and it never gos away on my mac book pro how do i fix it?

    my desktop is not working when i open it all it does is show the color weal and it never gos away on my mac book pro how do i fix it?

    It means, tentatively, that system files are missing or damaged and you will have to reinstall Snow Leopard. See the following:
    Reinstall OS X without erasing the drive
    Do the following:
    1. Repair the Hard Drive and Permissions
    Boot from your Snow Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Utilities menu. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list.  In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive.  If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.
    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.
    2. Reinstall Snow Leopard
    If the drive is OK then quit DU and return to the installer.  Proceed with reinstalling OS X.  Note that the Snow Leopard installer will not erase your drive or disturb your files.  After installing a fresh copy of OS X the installer will move your Home folder, third-party applications, support items, and network preferences into the newly installed system.
    Download and install the Combo Updater for the version you prefer from support.apple.com/downloads/.

  • Jsp:useBean  not work when I install aplication!!

    Hi
    I developing an application with UIX JSP on Jdeveloper 9.0.2 and i using something like this:
    <jsp:useBean id="cbean" class="oracle.jsp.dbutil.ConnBean" scope="session" />
    <jsp:setProperty name="cbean" property="dataSource" value="jdbc/BiblosConnectionCoreDS" />
    </jsp:useBean>
    <%
    try{
    cbean.connect();
    This code work fine in standalone mode, but when i install this application on 9IAS, with an archive War, the code <jsp:useBean, not work.
    What is missing for? o What is the reason for this situation
    Thanks for some help?

    many thanks for your reply, and I have download new updates driver from your website (http://consumersupport.lenovo.com/en/DriversDownloads/drivers_show_890.html) and Installer it on my Y410 but it still does not work!!!
    the firstly: when I star up with win7, I can see a speaker icon right down near the clock, when I click mouse on it, I can see: Volume Mixer - Speaker with Device(Speaker Hight definition Audio Device, Digital Audio(S/PDIF) ( Hight definition Audio Device) ).
    Look in devicemanger I can see "Sound , video and game controll " has already installer with 'Hight definition Audio Device ' & 'Unimodem Hafl-Duplex Audio Device' below... but I cannot hear the sound when I play music, video, games...etc...
    the second: when laptop wakeup after 'sleep' mode, I can hear sound on speaker! but headphone jack does not work when I plug my headphone jack into it (I cannot hear sound with headphone), however I still hear sound from speaker, in this case!  
    Can you help me or tell me how I can do ?!
    Thanks and Best Regards,
    jupitervn

  • [Bug?] Defer Panel Update not working when changing scale property

    Hi,
    I found that Defer Panel Update [when True] does not work properly when changing the scale fit property of an intensity graph.
    Try the VI.
    When Defer Panel Update is True, and you change the Numeric controls, the Intensity graph is not updated (as expected).
    But now change the "Z Scale.Scale Fit" button and.... the Intensity graph is updated (only the Z-color, not the axis).
    This looks to be a bug to me!
    Nicolas
    Attachments:
    [Bug] Defer Panel Update not working when changing scale property.vi ‏27 KB

    Hi Nicolas,
    This indeed looks like a bug. I will do more research on it and file a bug report if it's not already filed.  Thank you for posting this information!
    Yi Y.
    Applications Engineer
    National Instruments
    http://www.ni.com/support

  • Dbx does not work when debugging g++ exes.

    Hi,
    We are just getting started building our application on redhat el5 with sunstudio 12.
    We are compiling and linking our app with gcc 4.1 as we need to be able to link against some 3rd party libraries build on rhel4 that we do not have source for.
    We now can compile and link fine but dbx does not work when it is fed the executable.
    We get the error
    dbx: warning: Bad transition in runtime linker interface. CONSISTENT->CONSISTENT[
    and dbx freezes.
    Note : This is built with -m32 on a 64bit kernel. Also we have not yet rebuilt all the opensource libs used on gcc 4.1 as we have a large number of them.
    Any ideas ?
    The complete output of running dbx :
    Output from dbx :
    debug /ps_rels/Dev/linux_rhel5/exe/sx
    Reading sx
    Reading ld-linux.so.2
    Reading libz.so.1
    Reading libxerces-c.so.27
    Reading libxalan-c.so.110
    Reading libxalanMsg.so.110
    Reading libsde.so
    Reading libsg.so
    Reading libpe.so
    Reading libsqlite.so.0
    Reading libsqlite3.so.0
    Reading libgeos.so.2
    Reading libpng12.so.0
    Reading libX11.so.6
    Reading libXm.so.4
    Reading libXt.so.6
    Reading libXi.so.6
    Reading libXext.so.6
    Reading libXrender.so.1
    Reading libfreetype.so.6
    Reading libexpat.so.0
    Reading libfontconfig.so.1
    Reading libcairo.so.2
    Reading libglib-2.0.so.0
    Reading libgmodule-2.0.so.0
    Reading libgobject-2.0.so.0
    Reading libgthread-2.0.so.0
    Reading libpango-1.0.so.0
    Reading libpangocairo-1.0.so.0
    Reading libpangoft2-1.0.so.0
    Reading libatk-1.0.so.0
    Reading libgtk-x11-2.0.so.0
    Reading libgdk-x11-2.0.so.0
    Reading libgdk_pixbuf-2.0.so.0
    Reading libtiff.so.3
    Reading librt.so.1
    Reading libwx_gtk2_xrc-2.8.so.0
    Reading libwx_gtk2_qa-2.8.so.0
    Reading libwx_gtk2_html-2.8.so.0
    Reading libwx_gtk2_adv-2.8.so.0
    Reading libwx_gtk2_core-2.8.so.0
    Reading libwx_base_xml-2.8.so.0
    Reading libwx_base_net-2.8.so.0
    Reading libwx_base-2.8.so.0
    Reading libboost_thread-gcc-mt-1_33_1.so.1.33.1
    Reading libboost_filesystem-gcc-mt-1_33_1.so.1.33.1
    Reading libncurses.so.5
    Reading libnsl.so.1
    Reading libdl.so.2
    Reading libACE.so.5.5.1
    Reading libpthread.so.0
    Reading libpam.so.0
    Reading libm.so.6
    Reading libc.so.6
    Reading libstdc++.so.6
    Reading libgcc_s.so.1
    Reading libicuuc.so.34
    Reading libicui18n.so.34
    Reading libstdc++.so.5
    Reading libXau.so.6
    Reading libXdmcp.so.6
    Reading libXmu.so.6
    Reading libXp.so.6
    Reading libXft.so.2
    Reading libjpeg.so.62
    Reading libSM.so.6
    Reading libICE.so.6
    Reading libexpat.so.1
    Reading libXfixes.so.3
    Reading libXrandr.so.2
    Reading libXinerama.so.1
    Reading libXcursor.so.1
    Reading libXxf86vm.so.1
    Reading libaudit.so.0
    Reading libicudata.so.34
    Reading libnss_files.so.2
    Reading libnss_dns.so.2
    Reading libresolv.so.2
    dbx: warning: Bad transition in runtime linker interface. CONSISTENT->CONSISTENT
    Reading libnss_ldap.so.2
    Reading libcom_err.so.2

    Well, this message is just a warning and should not prevent dbx from working. What exactly happens to dbx? Does it hang? Does it crash? Or it doesn't allow to run the app?
    A side note: this message says that runtime linker debugging interface reported "consistent" event w/o any "add" or "delete" events, which is at least redundant and may indicate a bug. It is possible though that the bug is in dbx as well as in ld-linux.so, but its impossible to tell without live test case.

  • Crystal reports not working when integrated security is set to true

    Hello Everybody,
    I have developed 20 crystal reports. When i deploy in my development environment(asp.net) these reports are working fine.My UAT environment is using application pool connection instead of database connection.
    My .net developer has written a code and he set integrated security to true for reports. My problem is reports which are having parameters not working correctly. Reports which are not having any parameters, it is working fine. If i enter parameters in asp .net page, the report is running for all the values. It is not considering the parameter values.
    Thanks
    Ram

    Hi Ram,
    Need more info, what version of CR assemblies, which OS is hosting the app and what patches, CR and OS are installed?
    Have you discussed this issue with your developer? Possibly all of the runtime is not on the app server?
    Thank you
    Don

  • Automatic hierarchie aggregation not working when dimension formula is used

    Hey folks,
    i'm facing the following issue. currently i'm setting up an application to plan sales quantities, prices and manufacturing costs.
    subsequently i want to calculate following values for members of account dimension:
    - turnover (price * sales)
          -> implemented as dimension formula
          -> in the account hierarchie it's a child of net revenue
          -> account type: inc
          => calculation work fine in the reports
    - manufacturing cost (manufacturing cost * sales)
          -> implemented as dimension formula
          -> in the account hierarchie it's a child of net revenue
          -> account type: exp
          => calculation work fine in the reports
    - net revenue (turnover - manufacturing cost)
          -> in the account hierarchie it's the parent of turnover, manufacturing cost
          -> account type: inc
          => key figure is empty !!
    As far as i understood BPC is aggregating automatically along the hierarchie. That means to me that net revenue should be automatically calculated due to the hierarchical relation in account dimension.
    Did anyone ever face same issue ? probably the hierachical aggregation is not working when key figures based on dimension formula is used !? Do i really have to implement script logic to solve this issue ?
    Looking forward to interesting approaches to solve this issue !
    Best regards,
    Moritz

    Hey,
    sorry my description was misleading at this point. i don't have a formula define for net revenue dimension member. i expected the system to automatically calculate it by aggregation along the account dimension hierarchy where net revenue is parent to the turnover and manufacturing costs which are calculated by dimension formula.
    Best regards,
    Moritz

Maybe you are looking for