Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

pdf prints differently on web than desktop

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    pdf prints differently on web than desktop

    Withi the pdf option for the WAS, a report I created ends up with a blank 2nd page, and if I choose multiple workorders, the report shifts down for some reason. It looks okay in the preview under desktop but does the same thing when I click on the Adobe conversion icon.

    It also prints in the same page and my client wants it to open in a new window. It is a dialog that I print from on this.

    It's set up as a portrait letter size...

    Here is the login information for the site. If someone could please have a look. You would click on 'Print Production Workorders' to find the above. There are a few other things to look at but not much will be available with this username.

    user: alphauser
    pass: temp123
    Up and coming Alphaholic ;)

    #2
    Re: pdf prints differently on web than desktop

    ?
    Peter
    AlphaBase Solutions, LLC

    [email protected]
    https://www.alphabasesolutions.com


    Comment


      #3
      Re: pdf prints differently on web than desktop

      right. I guess it would help to give you the web address eh?

      www.mailtimenet.com

      user: alphauser
      pass: temp123
      Up and coming Alphaholic ;)

      Comment


        #4
        Re: pdf prints differently on web than desktop

        If you preview your reports w/o converting to PDF, do you get the same effect?
        Peter
        AlphaBase Solutions, LLC

        [email protected]
        https://www.alphabasesolutions.com


        Comment


          #5
          Re: pdf prints differently on web than desktop

          They look fine if I print straight to the printer. It's something about the PDF setup I believe. I take that back. The single ones print on one page. The multiple workorders still move.
          Up and coming Alphaholic ;)

          Comment


            #6
            Re: pdf prints differently on web than desktop

            I think you need to configure the printer on the WAS, if the web server app runs as the system user then the print settings and default printer may be different than on your development PC or even (if you develop on the server) than in the Windows profile you publish from.

            Comment


              #7
              Re: pdf prints differently on web than desktop

              Note - you have the logout.a5w as a requires login. So whenever someone logs out, the login page goes instantly restricted, kicking the user to the login page but also causing the URL to look like this:

              http://www.mailtimenet.com/index.a5w?np=%2Flogout%2Ea5w

              That means as soon as someone logs back in, they will be redirected to the LOGOUT page and be logged out in a never ending cycle.

              The logout page should be always available.

              Very attractive, easy to navigate website!
              Steve Wood
              See my profile on IADN

              Comment


                #8
                Re: pdf prints differently on web than desktop

                Originally posted by Steve Wood View Post
                Very attractive, easy to navigate website!
                Yeah, I agree. Very nice report formats, as well.
                Peter
                AlphaBase Solutions, LLC

                [email protected]
                https://www.alphabasesolutions.com


                Comment


                  #9
                  Re: pdf prints differently on web than desktop

                  Nice reports.


                  Got this error on the spread sheet option.
                  Error in event handler code for OnClick event for 'Excel_Export': Error loading [PathAlias.ADB_Name]\workorder: The system cannot find the path specified.
                  [PathAlias.ADB_Name]\workorder.DBF


                  Out of interest -what is the server configuration.

                  Also you do need to set the server (WAS) printer settings, there are also several settings you can force the pdf to do like embed fonts, watermark etc. I put them on this board some time ago, take a search and the will pop up.

                  Cheers,

                  Peter
                  Insanity: doing the same thing over and over again and expecting different results.
                  Albert Einstein, (attributed)
                  US (German-born) physicist (1879 - 1955)

                  Comment


                    #10
                    Re: pdf prints differently on web than desktop

                    Here you go.

                    Code:
                    delete PrintOptions
                    DIM PrintOptions as P
                    With PrintOptions
                             .Concatenate = .f.
                             .HasWatermark = .t.
                             .MultilingualSupport = .f.
                             .EmbedFonts = .t.
                             .LinearizeForWeb = .f.
                             .Colors2GrayScale = .f.
                             .ConvertHyperlinks = .f.
                             .WatermarkType = "Text"
                             .WatermarkText = "i G r o u p"
                             .WatermarkFontName = "Times New Roman"
                             .WatermarkFontSize = 200
                             .WatermarkRotation = 450
                             .WatermarkColorHex = "E8FED2"
                             .WatermarkHorizPos = 120
                             .WatermarkVertPos = +40
                             .WatermarkOnTop = .f.
                             .WatermarkPDF = ""
                            .Encrypt = .f.
                             .OwnerPassword = ""
                             .UserPassword = ""
                            .CanPrint = .t.
                             .CanModifyDocument = .t.
                            .CanCopy = .t.
                             .CanAddNotes = .t.
                             .Use128BitKey = .f.
                             .JpegQuality = "Low"
                    
                    End with
                    'query.filter = ""
                    'query.order = ""
                    
                    
                    
                    
                    Dim filename as c 
                    filename = session.session_folder + "tempreport.pdf"
                    filename = report.saveas("JobBagBasicA4-4@[PathAlias.ADB_Path]\jobregister.ddd","pdf",filter,order,filename,.f.,PrintOptions)
                    if file.exists(filename) 
                    	currentform.RedirectTarget = session.session_url + "tempreport.pdf?" +  time("hms3")
                    end if 	
                    skipreport:
                    Insanity: doing the same thing over and over again and expecting different results.
                    Albert Einstein, (attributed)
                    US (German-born) physicist (1879 - 1955)

                    Comment


                      #11
                      Re: pdf prints differently on web than desktop

                      Thanks for all the great feedback. I've worked pretty hard trying to make it easy to navigate and use. I know the excel doesn't work yet. I haven't fixed it, just moved it out there.

                      I'm just using an old computer that was laying around doing nothing and added the application server software on it. I have 5 ip addresses from my isp and plugged it right into the cable modem. I was going to try and set up a virtual server, but alas, it is a pain in the butt to mix Apache and Alpha Application Server on one computer and I don't really need it yet.

                      I did add your code in but nothing happened Pete. Maybe I didn't do it right. I put it in the aftervalidate before all of the code where it pulls the report.

                      Here's the code I need to use it with:

                      (Multiple Work Order Creation)

                      aftervalidate

                      dim filter as C
                      dim order as C
                      dim jobnum as C
                      dim filename as C
                      'since JobNumber is a multi-select DropDownBox, it is actually an array that contains the selected values.
                      jobnum = JobNumber.dump()
                      jobnum = remove_blank_lines(jobnum)
                      jobnum = *for_each(x,"clientjobn = " + quote(x),jobnum)
                      filter = stritran(alltrim(jobnum), crlf()," .or. ")
                      Order = "invert(Newjobno)"
                      filename = session.session_folder + chr(92) + "tempreport.pdf"
                      filename = report.saveas("production-wo@[PathAlias.ADB_Path]\workorder.set.set","pdf",filter,order,filename,.f.)
                      if file.exists(filename)
                      currentform.RedirectTarget = session.session_url + "tempreport.pdf?" + rand_string(5)
                      end if
                      skipreport:

                      (Weekly Schedule or Production Work Order)

                      activate:
                      dim report as c
                      report = <<%text%
                      weeklyschedule|weeklyschedule@[PathAlias.ADB_Path]\workorder set.set
                      production-wo|production-wo@[PathAlias.ADB_Path]\workorder set.set
                      %text%

                      aftervalidate

                      delete PrintOptions
                      DIM PrintOptions as P
                      With PrintOptions
                      .Concatenate = .f.
                      .HasWatermark = .t.
                      .MultilingualSupport = .f.
                      .EmbedFonts = .t.
                      .LinearizeForWeb = .f.
                      .Colors2GrayScale = .f.
                      .ConvertHyperlinks = .f.
                      .WatermarkType = "Text"
                      .WatermarkText = "i G r o u p"
                      .WatermarkFontName = "Times New Roman"
                      .WatermarkFontSize = 200
                      .WatermarkRotation = 450
                      .WatermarkColorHex = "E8FED2"
                      .WatermarkHorizPos = 120
                      .WatermarkVertPos = +40
                      .WatermarkOnTop = .f.
                      .WatermarkPDF = ""
                      .Encrypt = .f.
                      .OwnerPassword = ""
                      .UserPassword = ""
                      .CanPrint = .t.
                      .CanModifyDocument = .t.
                      .CanCopy = .t.
                      .CanAddNotes = .t.
                      .Use128BitKey = .f.
                      .JpegQuality = "Low"

                      End with
                      'query.filter = ""
                      'query.order = ""


                      jobno = alltrim(CurrentForm.Controls.ContactList)
                      report = alltrim(CurrentForm.Controls.ReportList)

                      if CurrentForm.Controls.ContactType = "1" then
                      dim filter as c
                      dim order as c
                      Filter = ".T."
                      Order = ""
                      Dim filename as c
                      filename = session.session_folder + "tempreport.pdf"
                      filename = report.saveas(report,"pdf",filter,order,filename,.f.)
                      if file.exists(filename)
                      currentform.RedirectTarget = session.session_url + "tempreport.pdf?" + time("hms3")
                      end if
                      else
                      IF eval_valid("jobno") = .f. Then
                      goto skipreport
                      end if
                      dim filter as c
                      dim order as c
                      Filter = "Clientjobn = \""+jobno+"\""
                      Order = ""
                      Dim filename as c
                      filename = session.session_folder + "tempreport.pdf"
                      filename = report.saveas(report,"pdf",filter,order,filename,.f.)
                      if file.exists(filename)
                      currentform.RedirectTarget = session.session_url + "tempreport.pdf?" + time("hms3")
                      end if
                      skipreport:
                      end if
                      Last edited by eboughey1; 12-18-2008, 03:37 AM.
                      Up and coming Alphaholic ;)

                      Comment


                        #12
                        Re: pdf prints differently on web than desktop

                        I'll look at it again tomorrow.

                        Don't get confused the "the application server" needs to have the alpha printer RUNNING

                        Look Under File in you main menu. Is there a "printer setup" - it might not be, as alpha does not do this when you install. if it's not there...

                        look in your windows programs folder
                        look for your alphafive it may be a5v9 folder
                        look for a file called "InstallAmyuniPrinters"
                        click it and install.
                        now when you go back to the file on the main menu it will be there.

                        now try your code.

                        remember to work the system printer must be set in alpha.

                        Code:
                        jobno = alltrim(CurrentForm.Controls.ContactList)
                        report = alltrim(CurrentForm.Controls.ReportList)
                        
                        delete PrintOptions
                        DIM PrintOptions as P
                        With PrintOptions
                        .Concatenate = .f.
                        .HasWatermark = .t.
                        .MultilingualSupport = .f.
                        .EmbedFonts = .t.
                        .LinearizeForWeb = .f.
                        .Colors2GrayScale = .f.
                        .ConvertHyperlinks = .f.
                        .WatermarkType = "Text"
                        .WatermarkText = "My WaterMark"
                        .WatermarkFontName = "Times New Roman"
                        .WatermarkFontSize = 200
                        .WatermarkRotation = 450
                        .WatermarkColorHex = "E8FED2"
                        .WatermarkHorizPos = 120
                        .WatermarkVertPos = +40
                        .WatermarkOnTop = .f.
                        .WatermarkPDF = ""
                        .Encrypt = .f.
                        .OwnerPassword = ""
                        .UserPassword = ""
                        .CanPrint = .t.
                        .CanModifyDocument = .t.
                        .CanCopy = .t.
                        .CanAddNotes = .t.
                        .Use128BitKey = .f.
                        .JpegQuality = "Low"
                        End with
                        
                        
                        if CurrentForm.Controls.ContactType = "1" then
                        dim filter as c 
                        dim order as c 
                        Filter = ".T."
                        Order = ""
                        Dim filename as c 
                        filename = session.session_folder + "tempreport.pdf"
                        filename = report.saveas(report,"pdf",filter,order,filename,.f.)
                        if file.exists(filename) 
                        currentform.RedirectTarget = session.session_url + "tempreport.pdf?" + time("hms3")
                        end if 
                        else
                        IF eval_valid("jobno") = .f. Then
                        goto skipreport
                        end if 
                        dim filter as c 
                        dim order as c 
                        Filter = "Clientjobn = \""+jobno+"\""
                        Order = ""
                        Dim filename as c 
                        filename = session.session_folder + "tempreport.pdf"
                        filename = report.saveas(report,"pdf",filter,order,filename,.f.)
                        if file.exists(filename) 
                        currentform.RedirectTarget = session.session_url + "tempreport.pdf?" + time("hms3")
                        end if 
                        skipreport:
                        end if
                        Insanity: doing the same thing over and over again and expecting different results.
                        Albert Einstein, (attributed)
                        US (German-born) physicist (1879 - 1955)

                        Comment


                          #13
                          Re: pdf prints differently on web than desktop

                          Well I figured out what caused the issue.

                          It was the printer, but it was something I haven't seen before and it was in the report band properties.

                          Under Report/Properties/Band/Report Properties/Page

                          I looked again at the page layout settings to make sure it was set to letter. It was empty and nothing showed up on the drop down. I couldn't fix it as long as I had the alpha five printer selected. I changed it to my local printer and it let me change the settings to letter. I saved the report then went back in and changed the printer back to Alpha Five. After that it showed the page layout properly.

                          Also, I had to set the report to use a Page header instead of a report header since they can choose multiple workorders to print.

                          So now that all works. Guess what? All of my boxes are gone that frame the fields for the winning # and instruction memo fields (unless they are populated). I haven't changed any of them but something I did obviously made it change. Has anyone seen that happen?
                          Up and coming Alphaholic ;)

                          Comment

                          Working...
                          X