Quantcast
Channel: Chilkat Forum - latest questions
Viewing all 1061 articles
Browse latest View live

unable to open .MSG file after creation

$
0
0

Hello,

I have installed Chilkat api using nuget package manager in visual studio and, I have created .msg file using the below code:

Chilkat.Email email = new Chilkat.Email();
            //email.LoadEml(@"E:\MailTest\Untitled.msg");
            email.Subject = "This is a test";
            email.Body = "Hello Message .... mail... Mail.. MAil....";
            email.From = "support@chilkatsoft.com";
            email.AddTo("Matt", "matt@chilkatsoft.com");
            email.SaveEml(@"E:\MailTest\Testmail.msg");

.MSG file is being created at the specified location but, it throwing the below error when I am trying to open the file :

ERROR: We can't open 'file_location.msg'. It's possible the file is already open, or you don't have permission to open it.

I am opening the file from super admin account only and all permissions are allowed.


Memory Usage PHP7

$
0
0

Hey there!

thanks for bringing these libs to so many languages!

I noticed by just including the "chilkat_9_5_0.php" file, my memory usage increased

running(without include and nothing else):

echo memory_get_peak_usage(); exit;

result: 407056

running(with chilkat include):

require_once 'chilkat_9_5_0.php'; echo memory_get_peak_usage(); exit;

result: 15452752

My chilkat version: DllDate: May 26 2017 ChilkatVersion: 9.5.0.68 UnlockPrefix: Anything for 30-day trial Architecture: Little Endian; 64-bit Language: Linux PHP

This seems pretty heavy.. adding roughly 15MB(the numbers should be bytes) on every request or am i wrong?

Or is this the price of using swig as a wrapper?

Also here is a php blackfire profile which shows this: https://blackfire.io/profiles/042db896-1e1a-4e26-a470-1b9c18dfe173/graph

Cheers Max

imap.GetMailAttachFilename returns filename ?=

$
0
0

Hello,

I recieve bad attachment filenames with the imap.GetMailAttachFilename method in VB6 when the attached filenames contain german Umlaut (äöü etc.)

example:

Dim numAttach As Long, nameAttach As String 
Dim filetype As String, Filename As String 
nameAttach = "" 
numAttach = imap.GetMailNumAttach(email)
If numAttach > 0 Then
    For J = 0 To numAttach - 1
        Filename = imap.GetMailAttachFilename(email, J)
        ...

the variable Filename contains ?=DCbungsseite.docx?=

Is this a known problem? How can I solve it?

Best regards, J.S.

force quoted text in csv

$
0
0

Is there a way in the csv module to force a string to be quoted even though the text is valid? I have an issue where the system that I am sending data to is dropping the leading 0. If I send 01234 in the csv file, they see 1234.

compile for iOS, unknown type name class; did you mean Class

$
0
0

I had for a while no issue to compile for iOS with Chilkat lib. Right now I use Xcode Version 8.3.3 (8E3004b) and latest Chilkat version (May 2017).

Didn't touched the code for 3 month or so and now get error "Unknown type name 'class'; did you mea 'Class' ? e.g. when importing #import "CkGlobal.h" I have a empty .cpp and .hpp file included in the project as described in the readme.

What else can go wrong ?

correct way to compile and deploy java app to multiple OS

$
0
0

We are using the chilkat libraries in a java app that will be deployed to Windows, Linux and Mac. We have downloaded the libraries for Java for all 3 platforms. From a deployment perspective, it seems clear to simply include chilkat.dll for Windows, libchilkat.so for Linux and libchilkat.jnilib for Mac. However, the chilkat.jar file appears to be different for each platform, so I am unsure of how to compile and deploy that dependency. Is the jar file platform dependent as well?

OAuth process

$
0
0

Hi,

this is more of a process question. After getting some more grey hairs after figuring out how to setup the secret IDs at the Google website the code for connecting with OAuth to Gmail actually works.

But what comes then? Please correct me if I misunderstand something:

  • I get an access token back which I stash the access token somewhere. Should this be encrypted?
  • And then I pass the access token instead of a password in Chilkat.Imap.LoginAsync(UserName, Password)

Mit freundlichen Grüßen/Regards

Beatrix Willius

http://www.mothsoftware.com Mail Archiver X: The email archiving solution for professionals

C++ Builder Fatal Error in Linking

$
0
0

we have the problem, under 64 bit in one of your large projects, the 64 bit linker get a „fatal error“.

We don’t get a feedback from Embarcadero.

When we delete chilkatxe4.a from project and comment out the code, using chilkat, it works.

We only use the Zip components and crypt komponents from chilkat lib.

The chilkatxe4.a has a size of 36 MB.

Is it possible, that you compile us a "small" version of chilkatxe4.a? (only with Zip and Crpyt components?

Perhaps it is a linker memory size problem.

We use Tokyo.


Reverse SSH Tunnel Implementation?

$
0
0

I see over the past few years there have been questions regarding Reverse SSH Tunnels and from their answers, it sounded like it was on the roadmap. Is this still the case?

SWIFT - CkoCert error use of unresolved identifier

$
0
0

func chilkatTest() {

let cert = CkoCert()

var success: Bool

//  LoadFromFile will load virtually any certificate format file.
//  It will auto-recognize the format and load appropiately.
//  A base64-encoded DER X.509 certificate file
//  contains the binary DER in base64 encoded form.
//  Therefore, it is a text file that will begin like this:
//  -----BEGIN CERTIFICATE-----
//  MIIFbjCCBFagAwIBAgIGdDPNv/L0MA0GCSqGSIb3DQEBBQUAMIHKMQswCQYDVQQG
//  EwJVUzEQMA4GA1UECBMHQXJpem9uYTETMBEGA1UEBxMKU2NvdHRzZGFsZTEaMBgG
//  ...

success = cert.LoadFromFile("/Users/chilkat/testData/cer/chilkat_base64.cer")
if success != true {
    print("\(cert.LastErrorText)")
    return
}

//  DN = "Distinguished Name"
print("SubjectDN:\(cert.SubjectDN)")

print("Common Name:\(cert.SubjectCN)")
print("Issuer Common Name:\(cert.IssuerCN)")

print("Serial Number:\(cert.SerialNumber)")

}

referred from - https://www.example-code.com/swift/cert_load_base64.asp

let cert = CkoCert() gives me error Use of unresolved identifier 'CkoCert'

Internal Imap folders

$
0
0

Hi,

how can I recognize internal folders like

dovecot.svbin dovecot.sieve

? The flags of both mailboxes is HasNoChildren. Of course, I can exclude the 2 mailboxes but I would prefer to recognize the internal mailboxes somehow.

Mit freundlichen Grüßen/Regards

Beatrix Willius

http://www.mothsoftware.com Mail Archiver X: The email archiving solution for professionals

Chilkat Imap .Net and Apple Mail email's with attachments not recognized

$
0
0

I am evaluating Chilkat's .NET Imap component (ChilkatDotNet45.dll) in PowerShell. It works well. But if you receive an email made in Apple's Mail app, the attachments aren't recognized.

I use this to check if there are attachments : $num_att = $email.NumAttachments

The mail part itself is handled okay.

Is this a known problem or is there a trick to make it work ?

Mail with attachments from other program's (Outlook, Thunderbird, Android device etc) work fine and the attachments are recognized.

Regards, Herman.

Unable to establish a connection

Winsock between two processes on same machine (ip)

$
0
0

Hello, We just built a proof of concept app that interfaces our PowerBuilder client application using your ActiveX Socket to another PB winsock application. We connect / send and receiveBytes and close. This works just great, when the applications are on different machines with different ip addresses. But when both processes are on the same machine, the communication hangs. Is it possible to use Sockets to communicate between two applications on the same machine with the same ip address.

Thanks

Access is denied on GetFile

$
0
0

"Access is Denied" error occurs when attempting to download a file from a FTP site. Connection to the site is successful. What is denied? The file on the ftp or the folder where the file is to be downloaded?

If it's a permissions issue, then why is connecting to the site successful?

Code: Dim extractPath As String = "xxx"

    If Not Directory.Exists(extractPath) Then
        Directory.CreateDirectory(extractPath)
    End If

    Dim ftp As New Chilkat.Ftp2

    Dim success As Boolean
    success = ftp.UnlockComponent("cccc")

    If (success <> True) Then
        FTPFailure(ftp.LastErrorText, String.Empty)
    Else
        ftp.Hostname = "xxx"
        ftp.Username = "yyy"
        ftp.Password = "zzz"

        '  Connect and login to the FTP server.
        success = ftp.Connect()
        If (success <> True) Then
            FTPFailure(ftp.LastErrorText, String.Empty)
            Exit Sub
        End If

        '  Change to the remote directory where the file will be uploaded.
        success = ftp.ChangeRemoteDir("/")
        If (success <> True) Then
            FTPFailure(ftp.LastErrorText, String.Empty)
            Exit Sub
        End If

        '  Download file to extractPath
        'SUCCESS RETURNS FALSE HERE.
        success = ftp.GetFile("aaa-bbb.png", extractPath)
        If (success <> True) Then
            FTPFailure(ftp.LastErrorText, String.Empty)
            Exit Sub
        End If
    End If

The folder is accessible on this computer thru windows explorer. Thanks for any help or advice.


How to get a receipt of sent mail when using pop3 accounts

$
0
0

When sending E-mails, you need some kind of receipt on what you have sent. If SMTP accounts are used it is possible to put a copy of the mail in the sent box according to the example Send Email and Put Copy in "Sent" Folder . But can be done when pop3 account are used?

It is, of course, possible to send a copy of the mail to own Email account and then maybe manually copy the to the sent box. But are there better solutions?

Bengt

Memory Leak in Chilkat C++?

$
0
0

See code below. If run it like this, 10 leaks. If I comment out the entire IF section, 0 leaks. Ideas?

CkCrypt2 crypt;
if (!crypt.UnlockComponent("hello"))
{
  m_dwErrorCode = -1;
  m_strErrorText = A2T(crypt.lastErrorText());
  return _T("");
}

>VBA CHILKAT< How to 'press' JSON button

$
0
0

Hello everyone,

I have a annoying problem.

The site is: http://kody.poczta-polska.pl/

What I basically need to do is to fill search box (rounded with red color - http://imgur.com/a/IC1qz ) with some 5 digit number, and press "Szukaj" button (what means in polish 'search').

Here I have fiddler log - https://pastebin.com/J21eXcTc after doing this request manually.

I got from fiddler log two parameters called "kod" = 20-610 and "page" = "kod". I made httprequest and send these parameters, but what I got back is still http://kody.poczta-polska.pl/. So it looks like sending parameters does nothing.

I think there is something with JSON, but I don't know how to make it working. The code I wrote is here: https://pastebin.com/Y5XGnNes

Thank you for any help.

Storing a mail in the sent folder of gmail

$
0
0

I can send an E-mail using smtp.gmail.com according to the example https://www.example-code.com/dataflex/smtp_gmailSsl.asp

Then I tried to save this mail in the sent folder of my own gmail account, with the code below, but that didn't work.

Get ComSelectMailbox of hoImap "Sent" to iSuccess returns False.

However, Get ComSelectMailbox of hoImap "Inbox" to iSuccess returns True and the mail can be saved in the inbox.

Shall it be so or do I make anything wrong? IMAP is activated on my gmail account.

Code

//Save the mail on the own gmail account

//  The mail has been sent.  Now save the email to the "Sent" folder
//  on your mail server.  (Your "Sent" folder could be named something else,
//  or you may store the email in any folder of your choosing.)
Get Create (RefClass(cComChilkatImap)) to hoImap
If (not(IsComObjectCreated(hoImap))) Begin
    Send CreateComObject of hoImap
End

//  Anything unlocks the component and begins a fully-functional 30-day trial.
Get ComUnlockComponent of hoMailman "XXXXXXXXXXXXXXXXXXXX" to iSuccess
If (iSuccess <> True) Begin
    Get ComLastErrorText of hoImap to sTemp1
    Showln sTemp1
    Procedure_Return
End

//  Connect to an IMAP server.
//  Use TLS
Set ComSsl of hoImap to True
Set ComPort of hoImap to 993
Get ComConnect of hoImap "imap.gmail.com" to iSuccess
If (iSuccess <> True) Begin
    Get ComLastErrorText of hoImap to sTemp1
    Showln sTemp1
    Procedure_Return
End

//  Login
Get ComLogin of hoImap "XXXXXX@gmail.com" "xyzabcde" to iSuccess
If (iSuccess <> True) Begin
    Get ComLastErrorText of hoImap to sTemp1
    Showln sTemp1
    Procedure_Return
End

//  Upload (save) the email to the "Sent" mailbox.
Get pvComObject of hoEmail to vEmail               
Get ComSelectMailbox of hoImap "Inbox" to iSuccess   //this work
//   Get ComSelectMailbox of hoImap "Sent" to iSuccess  //this doesn't work
If (iSuccess <> True) Begin
    Get ComLastErrorText of hoImap to sTemp1
    Showln sTemp1
    Procedure_Return
End

Get ComUidNext of hoImap to iUidNext

Get pvComObject of hoEmail to vEmail
Get ComAppendMail of hoImap "Inbox" vEmail to iSuccess
//   Get ComAppendMail of hoImap "Sent" vEmail to iSuccess
If (iSuccess <> True) Begin
    Get ComLastErrorText of hoImap to sTemp1
    Showln sTemp1
    Procedure_Return
End

Showln "Email saved to the Inbox folder."
//  Showln "Email saved to the Sent folder."

//  Disconnect from the IMAP server.
Get ComDisconnect of hoImap to iSuccess

Duplicate OpenSSL Connection Command In C#

$
0
0

I've been given a key file (.key), a certificate (.crt), and a chain file (.pem) along with a server application I'm supposed to connect to. The following openssl command works...

openssl s_client -key provided.key -cert provided.crt -CAfile provided.pem -connect 127.0.0.1:port

I'm asked for a pass phrase for the key and then I connect. I'm trying to duplicate this in a C# application. I've used TcpClient with an SslStream but that requires a .pfx file. I've created the file using openssl but that didn't work (used the key and certificate file).

Is there a way to simulate the openssl s_client command using C#? And can I register a callback for the entry of a pass phrase?

Viewing all 1061 articles
Browse latest View live