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. QDateTimeEdit and CalendarPopup.
Qt 6.11 is out! See what's new in the release blog

QDateTimeEdit and CalendarPopup.

Scheduled Pinned Locked Moved General and Desktop
5 Posts 4 Posters 5.5k 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.
  • K Offline
    K Offline
    kibsoft
    wrote on last edited by
    #1

    Hi! I have an QDateTimeEdit with calendarPopup=true. How can I open this calendar programmatically (without clicking the arrow button)?

    1 Reply Last reply
    0
    • L Offline
      L Offline
      lyuts
      wrote on last edited by
      #2

      Maybe emulating a keypress event manually for the will do the trick (DateTimeEdit should get the focus first). I mean Alt + ArrowDown.

      I'm a rebel in the S.D.G.

      1 Reply Last reply
      0
      • T Offline
        T Offline
        tobias.hunger
        wrote on last edited by
        #3

        I have not tried this, but maybe it is enough to call show() on the calendarwidget?

        1 Reply Last reply
        0
        • S Offline
          S Offline
          sabrog
          wrote on last edited by
          #4

          [quote author="Tobias Hunger" date="1279811974"]I have not tried this, but maybe it is enough to call show() on the calendarwidget?[/quote]

          I think no. May be this can show calendar widget, but with old position. Here 3 calls:

          @ d->initCalendarPopup();
          d->positionCalendarPopup();
          d->monthCalendar->show();@

          QT - Apple QuickTime
          Qt - Nokia's Qt Development Frameworks
          Apple is a competitor of Nokia, so QT != Qt

          1 Reply Last reply
          0
          • K Offline
            K Offline
            kibsoft
            wrote on last edited by
            #5

            bq. I have not tried this, but maybe it is enough to call show() on the calendarwidget?

            I tried it, but it hasn't given any results.

            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