Results 1 to 5 of 5

Thread: Unable to set report orientation in code

  1. #1

    Thread Starter
    Member
    Join Date
    Jul 2005
    Posts
    36

    Post Unable to set report orientation in code

    Hey All,
    Once again I am back to the forums with a question.

    I have created a report in vb designer, called rptDailySummaryLandscape.
    I am trying to set its orientation to LandScape by using following code:
    VB Code:
    1. rptDailySummaryLandscape.Orientation = rptOrientLandscape
    It works fine on one server. When I moved that to a different server, the compiler does not recognize .Orientation. I have exact same references as the working version - matched from Project --> References and Project --> Components.

    Is there some thing else that I am missing? If you know that i need a different dll, please let me know.

    Thanks!
    Ankeet.

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Unable to set report orientation in code

    What is the difference between the two servers?

  3. #3

    Thread Starter
    Member
    Join Date
    Jul 2005
    Posts
    36

    Re: Unable to set report orientation in code

    One is running Windows 2000 Server (where the app works fine) and the other one runs Windows 2003 Server (where the app does NOT work fine).

    Apps on Windows 2000:
    VB6
    Microsoft Office
    BarTender


    Apps on Windows 2003
    VB6 (!)
    VB.NET (!)
    MicrosoftOffice
    BarTender
    COGNOS etc etc

  4. #4
    Addicted Member
    Join Date
    Apr 2003
    Posts
    193

    Re: Unable to set report orientation in code

    I am getting the same issue now with code copied to another laptop and it won't compile either for the .orientation = rptlandscape. It is give "variable not found" error? Both systems are Windows XP. I have checked for all the MSS dll's and they are registered, any ideas?
    Thanks

  5. #5
    New Member
    Join Date
    Jan 2009
    Posts
    5

    Re: Unable to set report orientation in code

    Although this problem has not been solved in a few years, I currently have basically the same issue:

    I've got a VB6 application that uses the .Orientation = rptOrientLandscape in order to display my data report with the landscape orientation. When I run it, it results in "Compile error: Method or data member not found". This is a bug that was supposedly fixed with Microsoft VB6's Service Pack 6. I've been able to get it to work using VB6 sp6 on my windows XP machine using all the tips I got through googling.

    But it does not work on my Vista 64 machine, so I'm suspecting that is a cause. I'm not sure if it's b/c of different locations for the dlls on with Vista x64. I've copied a couple of dlls from my XP machine onto my Vista machine and registered them (see below). The whole dll/ocx business is Greek to me, and I really can't figure out what else to do. I've tried reinstalling Service Pack 6 a couple of times.

    regsvr32 "C:\Windows\System32\MSDBRPT.dll"
    regsvr32 "C:\Windows\System32\MSDBRPTR.dll"
    regsvr32 "C:\Windows\SysWOW64\MSDBRPT.dll"
    regsvr32 "C:\Windows\SysWOW64\MSDBRPT.dll"


    I realize this is a pretty challenging question. I'm not expecting anyone to have the answer offhand. Anyone willing to help me troubleshoot it? I'm not sure where to begin, other than what I've already tried. OR, any workarounds could be just as good. Thanks.

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