0

I am using Oracle managed driver and Entity 5x. I have a winforms VB project and am seeing the strangest thing. When the data source of the Binding Source is filled, then the form shrinks about 50%, on a 4K monitor. Any thoughts?

Here is the code:


            db = New RadsEntityConnStr4() ' entity context
            db.SetDatabase()

            If (mViewAddEdit = ViewAddEditEnum.Add) Then
                Me.bsPhantom.AddNew()
                Return
            End If
        Dim query = From ps In db.PHANTOM_SESSION Where (ps.PHNTM_SESSION_NO = CDbl(mPhntmSessionNum))
        bsPhantom.DataSource = query.ToList() ' resize occurs here
Rob
  • 2,363
  • 7
  • 36
  • 54
  • 1
    Is the WinForm app declared DPI Aware? May be issue similar to [When clicking “btnLogin”, my forms decrease in size](https://stackoverflow.com/q/48272782/2592875). – TnTinMn Jul 11 '19 at 15:24
  • 1
    See also the notes here: [DPI Awareness - Unaware in one Release, System Aware in the Other](https://stackoverflow.com/a/50276714/7444103). – Jimi Jul 11 '19 at 15:59
  • Yes, this one solved it. Turning the app to DPI aware fixed it. https://stackoverflow.com/questions/48272782/when-clicking-btnlogin-my-forms-decrease-in-size – Rob Jul 11 '19 at 22:54

0 Answers0