15,885,093 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by merh (Top 26 by date)
merh
8-Sep-21 4:04am
View
Thanks Richard!
merh
12-Mar-21 12:22pm
View
Hi!My code crashes at return await browser.PrintToPdfAsync(path);
using System;
using System.Windows.Forms;
using CefSharp;
using CefSharp.WinForms;
using System.Threading.Tasks;
using System.Threading;
namespace CefTest
{
public class Program
{
private static ChromiumWebBrowser browser;
[STAThread]
public static async Task Main(string[] args)
{
await HtmlToPdfHeadless();
}
private static async Task HtmlToPdfHeadless()
{
const string testUrl = "https://www.google.com/";
var settings = new CefSettings();
Cef.Initialize(settings);
browser = new ChromiumWebBrowser(testUrl);
string path = "Test.pdf";
Task<bool> printToPdfAsync = PrintToPdfAsync(path);
var result = await printToPdfAsync;
}
public static async Task<bool> PrintToPdfAsync(string path)
{
return await browser.PrintToPdfAsync(path);
}
}
}
merh
12-Mar-21 9:54am
View
Sorry I have changed to the following and it still dosent work.
Task<int> printToPdfAsync = PrintToPdfAsync(path);
int result = await printToPdfAsync;
merh
12-Mar-21 9:24am
View
Deleted
Hi!
There is await before PrintToPdfAsync method. I have also changed the the invoked method to the following but it still dosent work.
await PrintToPdfAsync(path);
public static async Task PrintToPdfAsync(string path)
{
await browser.PrintToPdfAsync(path);
}
merh
8-Jun-20 10:18am
View
Yes, thanks!
merh
16-Oct-18 11:44am
View
Thanks!
merh
15-Aug-18 17:07pm
View
Deleted
Thanks for your answer. But how can I use the path with RootFolder? Because with RootFolder I jump into the folder.
merh
22-Dec-15 6:40am
View
Thanks a lot!
merh
7-May-15 7:26am
View
Thanks, but I get the problem when I include C++ header file in the header file for C.
merh
2-Apr-14 4:49am
View
I found the problem in "Regional and language Options" under Standards and Formats. I has to be changed to Russian and the question marks are removed. The string loads correctly the string from the resorce file but when the string is added to the tab, it shows strange characters which are not Russians.
str.LoadString(REQSETTINGS);
nTab = m_tabWnd.AddViewTab(RUNTIME_CLASS(CRequiredSettingsView), str, pContext);
m_ptrRequiredSettingsView = (CRequiredSettingsView*) m_tabWnd.GetTabClient(nTab);
m_tabWnd.SetTabIcon(nTab, IDI_Page);
m_ptrRequiredSettingsView->SetFileControler(m_pFileControler);
Thanks for any Help
merh
merh
18-Jun-12 13:25pm
View
Thanks for your answer.
I working with Swedish language. I would like to find the abbreviations and replace them with real words.
I have already a limited dictionary of abbreviations.
how can I recognize an abbreviation?
you says words which cannot be recognized should make the whole text invalid.
How can I find out words which make the whole text invalid?
Thanks
Merh
merh
11-Nov-11 17:18pm
View
Hi, yes. It was from me. I try to point to that Im searching for something like that but in this case for starting of application.
merh
10-Nov-11 17:29pm
View
It works, Thanks a lot
M.H
merh
18-Oct-11 15:38pm
View
Thanks for an Excellent explanation.
merh
18-Oct-11 14:48pm
View
Windows XP
merh
27-Oct-10 10:38am
View
Thanks a lot
M.H
merh
30-Sep-10 3:29am
View
Thanks a lot.
merh
28-Sep-10 11:13am
View
The "text box" is in both English and Russian resource files. Because Im beginner in this case´, how can I code the "text box" in cp1251?
merh
28-Sep-10 9:57am
View
Deleted
The "text box" is in both English and Russian resource files. Because Im beginner in this case´, how can I code the "text box" in cp1251?
merh
28-Sep-10 9:03am
View
Its placed with SetWindowText(m_strDisplay) and CString m_strDisplay; // Holds the string that gets displayed.
merh
2-Sep-10 15:31pm
View
I have windows XP. I restart the computer but the changing dosent take effect.
merh
24-Aug-10 3:54am
View
Thanks a lot for your help and it works as I have expected.
/M.H
merh
23-Aug-10 9:48am
View
Could you please give me a example how to change Default input language to English by the function SystemparameterInfo?
merh
20-Aug-10 15:44pm
View
It works fine and thanks a lot for your help
Best Regards
M.H
merh
20-Aug-10 8:33am
View
It seems that I can load "ntdll" and seems also GetProcAddres works but
LCID lcId(0); NtQueryDefaultLocale(FALSE, &lcId); dosent work.
HINSTANCE hInstLibrary = LoadLibrary("ntdll.dll");
if (hInstLibrary)
{
FARPROC farproc = GetProcAddres(hInstLibrary, "NtQueryDefaultLocale");
LCID lcId(0);
NtQueryDefaultLocale(FALSE, &lcId);
FreeLibrary(hInstLibrary)
}
merh
19-Aug-10 15:53pm
View
thanks, could you please tell me what I need to use "NtQueryDefaultLocale"? Because I get error message.
Show More