Results 1 to 9 of 9

Thread: How to resolve the run-time error '380' Invalid property value?

  1. #1

    Thread Starter
    New Member
    Join Date
    Mar 2017
    Posts
    4

    How to resolve the run-time error '380' Invalid property value?

    When I want to set the value as below:
    picDrawing.ScaleWidth = OverallWidth
    where OverallWidth > 40000 then I get the run-time error '380'.

    Any idea how I could solve this problem? Thanks.

  2. #2
    PowerPoster SamOscarBrown's Avatar
    Join Date
    Aug 2012
    Location
    NC, USA
    Posts
    9,143

    Re: How to resolve the run-time error '380' Invalid property value?

    Well, 40000 is a lot less than the maximum (245685) of a picturebox. What is your scalemode set to?

  3. #3

    Thread Starter
    New Member
    Join Date
    Mar 2017
    Posts
    4

    Re: How to resolve the run-time error '380' Invalid property value?

    Thanks for coming back. There is no scalemode property in my vb6?

  4. #4
    PowerPoster Arnoutdv's Avatar
    Join Date
    Oct 2013
    Posts
    5,872

    Re: How to resolve the run-time error '380' Invalid property value?

    Sam refers to the ScaleMode property of the PictureBox

  5. #5

    Thread Starter
    New Member
    Join Date
    Mar 2017
    Posts
    4

    Re: How to resolve the run-time error '380' Invalid property value?

    It's not a pictureBox but a VSDraw and there is no property in VSDraw for scalemode.

  6. #6
    PowerPoster Arnoutdv's Avatar
    Join Date
    Oct 2013
    Posts
    5,872

    Re: How to resolve the run-time error '380' Invalid property value?

    You should have mentioned that before.

    If you check the documentation of the vsDraw control (by ComponentOne) then you will find that the range for the .ScaleWidth property is -32,768 to 32,767.

    Note: All scaling properties must be in the range from -32,768 to 32,767. This is a limitation imposed by Windows metafiles.

  7. #7

    Thread Starter
    New Member
    Join Date
    Mar 2017
    Posts
    4

    Re: How to resolve the run-time error '380' Invalid property value?

    Thanks a lot. Sorry for not being clear. Is there a way around it? My drawing moves outside the VSDraw canvas. I mean, is there a way to add scrollbars when the drawings goes outside vsDraw?

  8. #8
    PowerPoster Arnoutdv's Avatar
    Join Date
    Oct 2013
    Posts
    5,872

    Re: How to resolve the run-time error '380' Invalid property value?

    I don't know. I've never used the control myself.

  9. #9
    PowerPoster SamOscarBrown's Avatar
    Join Date
    Aug 2012
    Location
    NC, USA
    Posts
    9,143

    Re: How to resolve the run-time error '380' Invalid property value?

    Me neither, sorry.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width