CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: pdk5

Page 1 of 19 1 2 3 4

Search: Search took 0.02 seconds; generated 28 minute(s) ago.

  1. Replies
    3
    Views
    98

    Re: casting pointer to template type

    Thankyou very much kaud !!!. Yes it compiled like magic :)

    I was some short break and now back to work and i feel like i have forgotten little bit c++ i knew..

    thanks a lot again.. i am sorry...
  2. Replies
    3
    Views
    98

    casting pointer to template type

    Hello.

    I have another circular dependency issue, so was trying to handle by changing the variable access, to pointer type.

    But the pointer is for templated class.

    Basically i had

    ...
  3. Replies
    14
    Views
    861

    Re: New file inclusion problem on legacy code

    Thankyou very much kaud. As per your advice i have used optional now
    (sorry for the delay response,)
  4. Replies
    14
    Views
    861

    Re: New file inclusion problem on legacy code

    May be otherway is pass it function param as reference and return a bool (to tell if its valid )!!!
  5. Replies
    14
    Views
    861

    Re: New file inclusion problem on legacy code

    @Victor thanks a lot for the response.
    Yes, i.e what was discussed during design. It makes it easier, to check if it is valid, by checking if its null_ptr !
    Also makes it consistent with the...
  6. Replies
    14
    Views
    861

    Re: New file inclusion problem on legacy code

    Thanks a lot kaud. I think most probably this issue is now resolved :) . I had included "simulator.h" in the FWAInfo.h. As I had moved all function definitions, into the .cpp, I could remove that .h....
  7. Replies
    14
    Views
    861

    Re: New file inclusion problem on legacy code

    Hi Kaud,

    Sorry i didnot have time to look further into this issue. Just to simplify the issue

    I have added a new file called FWAInfo.h which has two classes: FWAPoint and CFWAInfo

    Now in the...
  8. Replies
    14
    Views
    861

    Re: New file inclusion problem on legacy code

    Thanks a lot kaud. Btw, I created the FWA.cpp and moved most of functions there. Now this issue is resolved.

    But it would be helpful, if we have any tools to show the inclusion order .. (when the...
  9. Replies
    14
    Views
    861

    Re: New file inclusion problem on legacy code

    Thanks a lot Victor and kaud.

    Actually, that function i was adding was not used as of now (so commented out) and moved on. But now facing similar issue.

    I never had this kind of file inclusion...
  10. Replies
    14
    Views
    861

    New file inclusion problem on legacy code

    Hello,

    I added a new class in the c++ header file and included in existing file. And it works ok, as expected :).

    I also have #pragma once in the new header file.

    Now I want to include in...
  11. Replies
    4
    Views
    1,978

    Re: Help in understanding the legacy code

    I dont have any documents regarding this, so need to go through this and find out whats happening.
    and i was thinking, if they had used vectors it would have been implemented.
  12. Replies
    4
    Views
    1,978

    Help in understanding the legacy code

    Hello,

    Im trying to understand the following legacy code:

    Not sure why the following array indexing is made so complicated.
    Could some experts explain help me understand the logic behind


    ...
  13. Replies
    6
    Views
    2,268

    Re: Display python script output into MFC window

    Just to add some more inputs, when googling i found the following articles: (Not explored them yet). May be if anybody knows about these articles, will be helpful to post here:...
  14. Replies
    6
    Views
    2,268

    Re: Display python script output into MFC window

    Thankyou Victor for looking into this. As of now I have not tried to redirect. But i can try and update.
  15. Replies
    6
    Views
    2,268

    Display python script output into MFC window

    Hello,

    As you already helped me to plot a chart in python calling it in c++.
    the current output is into the console.

    Now I want to explore the option of moving the output plot into MFC window...
  16. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Hello,
    First of all thanks a lot for this forum, for helping me . Very helpful and much appreciated.

    Just to keep my progress updated, now I can pass the array from c++ to python and plot.


    ...
  17. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Thanks Arjay, yes I remember i had to debug one module in our project sometime back due to historical reasons. It can still be debugged, except some variables maynot be visible being optimised.
    ...
  18. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    One more good news



    #include <iostream>
    #include "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python37_64\include\Python.h"

    using namespace std;

    int main(int)
  19. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Thankyou very much. Your suggestion was very helpful indeed. Eventhough it is still not working, but is better now. The earlier error is gone.

    The script had to have some indent issues:


    from...
  20. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Thanks a lot Arjay for the help.

    Actually when i changed the contents of Sample.py to:


    import matplotlib.pyplot as plt

    def fun(): print("Hello from a function")
  21. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Just to update, I upgraded to python3 and above error is not seen


    #include <iostream>
    #include "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python37_64\include\Python.h"

    int main()...
  22. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Thankyou very much kaud. Im sorry, im asking too many things. I was hoping to finish this today, but it looks like taking more time..


    Actually the issue is resolved when i changed to following
    ...
  23. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Actually , i want to call the function from a python file.
    By googling, it looks like I need to use the following function.
    I added a "Sample.py" in the same place where the exe is stored for the...
  24. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Sorry kaud, yes it was my mistake, i had changed to "Python 2"
  25. Replies
    19
    Views
    5,747

    Re: Calling python from c++ in visual studio

    Thankyou very much kaud.

    Now finally it works !!!
    I was using old VS. google told me to install later versions and we can download python with it. So I upgraded to VS2019, and ticked the python 2...
Results 1 to 25 of 461
Page 1 of 19 1 2 3 4





Click Here to Expand Forum to Full Width

Featured