דילוג לתוכן
  • דף הבית
  • קטגוריות
  • פוסטים אחרונים
  • משתמשים
  • חיפוש
  • חוקי הפורום
כיווץ
תחומים

תחומים - פורום חרדי מקצועי

💡 רוצה לזכור קריאת שמע בזמן? לחץ כאן!
  1. דף הבית
  2. תכנות
  3. pdfium viewer ב- עבור C# wpf

pdfium viewer ב- עבור C# wpf

מתוזמן נעוץ נעול הועבר תכנות
5 פוסטים 2 כותבים 305 צפיות
  • מהישן לחדש
  • מהחדש לישן
  • הכי הרבה הצבעות
התחברו כדי לפרסם תגובה
נושא זה נמחק. רק משתמשים עם הרשאות מתאימות יוכלו לצפות בו.
  • pcinfogmachP מנותק
    pcinfogmachP מנותק
    pcinfogmach
    כתב ב נערך לאחרונה על ידי pcinfogmach
    #1

    עריכה: אני משאיר את השאלה על מקומה בכל אופן התשובה הקצרה נמצאת בפוסט של @חגי האחרון.

    מישהו יודע איך להשתמש בpdfium viewer ב- wpf
    החבילות בנוגט עושות לי שגיאות בהתקנה
    כגון

    Severity	Code	Description	Project	File	Line	Suppression State
    Error		Could not install package 'PDFiumCore 123.0.6309'. You are trying to install this package into a project that targets '.NETFramework,Version=v4.8', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.				
    

    מצאתי בגיט משהו מוכן אבל גם זה לא עובד עושה שגיאות

    System.DllNotFoundException
      HResult=0x80131524
      Message=אין אפשרות לטעון את קובץ ה-DLL 'pdfium.dll'. The specified module could not be found. (חריג מ-  HRESULT: 0x8007007E)
      Source=PdfiumViewer
      StackTrace:
       at PdfiumViewer.NativeMethods.Imports.FPDF_AddRef()
       at PdfiumViewer.NativeMethods.FPDF_AddRef() in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\NativeMethods.Pdfium.cs:line 25
       at PdfiumViewer.PdfLibrary..ctor() in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\PdfLibrary.cs:line 26
       at PdfiumViewer.PdfLibrary.EnsureLoaded() in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\PdfLibrary.cs:line 18
       at PdfiumViewer.PdfFile..ctor(Stream stream, String password) in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\PdfFile.cs:line 29
       at PdfiumViewer.PdfDocument..ctor(Stream stream, String password) in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\PdfDocument.cs:line 155
       at PdfiumViewer.PdfDocument.Load(Stream stream, String password) in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\PdfDocument.cs:line 129
       at PdfiumViewer.PdfDocument.Load(String path, String password) in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\PdfDocument.cs:line 42
       at PdfiumViewer.PdfDocument.Load(String path) in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer\PdfDocument.cs:line 29
       at PdfiumViewer.WPFDemo.MainWindow.LoadPDFButton_Click(Object sender, RoutedEventArgs e) in C:\Users\0533105132\Downloads\PdfiumViewer-master(1)\PdfiumViewer-master\PdfiumViewer.WPFDemo\MainWindow.xaml.cs:line 91
       at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
       at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
       at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
       at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e)
       at System.Windows.Controls.Primitives.ButtonBase.OnClick()
       at System.Windows.Controls.Button.OnClick()
       at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
       at System.Windows.UIElement.OnMouseLeftButtonUpThunk(Object sender, MouseButtonEventArgs e)
       at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
       at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
       at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
       at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
       at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
       at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
       at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
       at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
       at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
       at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
       at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
       at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
       at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
       at System.Windows.Input.InputManager.ProcessStagingArea()
       at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
       at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
       at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
       at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
       at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
       at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
       at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
       at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
       at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
       at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
       at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)
       at System.Windows.Application.RunDispatcher(Object ignore)
       at System.Windows.Application.RunInternal(Window window)
       at System.Windows.Application.Run(Window window)
       at System.Windows.Application.Run()
       at PdfiumViewer.WPFDemo.App.Main()
    
    

    אין לי מספיק ניסיון כדי לדעת ולהבין מה בדיוק הבעיה קראתי שצריך להוסיף את ה-dll של pdfium אבל לא הבנתי בדיוק איך
    אשמח לקבל עזרה

    מצו"ב הלינק לגיט
    https://github.com/pvginkel
    https://github.com/bezzad/PdfiumViewer

    תודה מראש

    גמ"ח מידע מחשבים ואופיס

    תגובה 1 תגובה אחרונה
    0
    • חגיח מנותק
      חגיח מנותק
      חגי
      כתב ב נערך לאחרונה על ידי
      #2

      אתה צריך את זה:
      https://github.com/pvginkel/PdfiumViewer
      https://www.nuget.org/packages/PdfiumViewer

      במה שאתה שלחת אין תמיכה בגירסת דוטנט שאתה משתמש
      https://www.nuget.org/packages/PdfiumViewer.WPF#supportedframeworks-body-tab

      pcinfogmachP תגובה 1 תגובה אחרונה
      0
      • pcinfogmachP מנותק
        pcinfogmachP מנותק
        pcinfogmach
        השיב לחגי ב נערך לאחרונה על ידי
        #3

        @חגי
        תודה
        גם זה לא עובד לי עדכנתי את הפוסט למעלה עם מה שקרה

        גמ"ח מידע מחשבים ואופיס

        תגובה 1 תגובה אחרונה
        1
        • חגיח מנותק
          חגיח מנותק
          חגי
          כתב ב נערך לאחרונה על ידי
          #4

          אולי זה יעזור לך
          https://stackoverflow.com/questions/55646556/adding-pdfium-dll-to-visual-studio

          pcinfogmachP תגובה 1 תגובה אחרונה
          1
          • pcinfogmachP מנותק
            pcinfogmachP מנותק
            pcinfogmach
            השיב לחגי ב נערך לאחרונה על ידי
            #5

            @חגי
            אין כמוך!
            אני מצרף לינק לתשובה המדוייקת שם שעזרה לי
            https://stackoverflow.com/a/67373337/23343154

            גמ"ח מידע מחשבים ואופיס

            תגובה 1 תגובה אחרונה
            1

            בא תתחבר לדף היומי!
            • התחברות

            • אין לך חשבון עדיין? הרשמה

            • התחברו או הירשמו כדי לחפש.
            • פוסט ראשון
              פוסט אחרון
            0
            • דף הבית
            • קטגוריות
            • פוסטים אחרונים
            • משתמשים
            • חיפוש
            • חוקי הפורום