Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Loading swfs in QAxWidget only full paths load
Forum Updated to NodeBB v4.3 + New Features

Loading swfs in QAxWidget only full paths load

Scheduled Pinned Locked Moved General and Desktop
4 Posts 2 Posters 3.8k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    azkay
    wrote on last edited by
    #1

    For example:
    [code]
    QAxWidget *flash = new QAxWidget(ui->widget);
    flash->resize(740, 580);
    flash->setControl(QString::fromUtf8("{d27cdb6e-ae6d-11cf-96b8-444553540000}"));
    flash->dynamicCall("LoadMovie(long,string)", 0, QDir::currentPath()+"/file.swf");
    [/code]
    ^ works

    [code]
    QAxWidget *flash = new QAxWidget(ui->widget);
    flash->resize(740, 580);
    flash->setControl(QString::fromUtf8("{d27cdb6e-ae6d-11cf-96b8-444553540000}"));
    flash->dynamicCall("LoadMovie(long,string)", 0, "file.swf");
    [/code]
    ^ doesn't work

    I run the untitled1.exe from the same folder as the file.swf but the swf never loads.
    Does it look somewhere else for file.swf other than the working directory?

    1 Reply Last reply
    0
    • G Offline
      G Offline
      goetz
      wrote on last edited by
      #2

      Not really Qt related, I'd say, but more a topic for a Flash forum, isn't it?

      Qt/QAxWidget is just a container/proxy for the underlying native classes, the actual work is done by the latter.

      http://www.catb.org/~esr/faqs/smart-questions.html

      1 Reply Last reply
      0
      • A Offline
        A Offline
        azkay
        wrote on last edited by
        #3

        It seemed like a Qt problem, any other time I've used the flash object in other languages it would check the working directory for the file.

        If I posted this in a flash forum, they would tell me to post it in a Qt forum.

        1 Reply Last reply
        0
        • G Offline
          G Offline
          goetz
          wrote on last edited by
          #4

          In this case I would suspect that the current environment (especially current directory) is not passed to the native control - for whatever reason.

          http://www.catb.org/~esr/faqs/smart-questions.html

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved