NOTES C API encoding language problem

I use NIFFindDesignNote to retrieve the id of a notes design element from the title ($title of type String).

method works only if title of design element is english character only.

problem is we have some french name: some design elements title are written in french : got characters like é or ê in the title ($title).

That causes a problem, and the method NIFFindDesignNote fails.

Is there a way to encode and what charset should we use???

thanks all, my first post… heheh

Subject: NOTES C API encoding language problem

Could you show your code? Are you using it from C or From LS? If form LotusScript i’d bet you use a wrong declaration.

Subject: RE: NOTES C API encoding language problem

I double posted… see prvious!

Subject: RE: NOTES C API encoding language problem

I use LostusScript code declaration :

-Byval forms As String is the parameter containing special characters

code:

Function NIFFindDesignNote(Byval hDBDst As Long, Byval forms As String, Byval ClassForm As Integer, hNote As Long) As Integer

Dim s As New NotesSession

Dim current_Platform As Variant

Select Case s.Platform

Case "Windows/32"

	NIFFindDesignNote =  NIFFindDesignNoteW32(hDBDst, forms, ClassForm, hNote)          

Case "UNIX"

	current_Platform = Evaluate("@Platform([Specific])")

	If current_Platform(0) <> "IBM OS/390" Then

		NIFFindDesignNote =  NIFFindDesignNoteUNIX(hDBDst, forms, ClassForm, hNote)

	Else

		NIFFindDesignNote =  NIFFindDesignNoteOS390(hDBDst, forms, ClassForm, hNote)

	End If

Case "OS/400"

	NIFFindDesignNote =  NIFFindDesignNote400(hDBDst, forms, ClassForm, hNote)

End Select

End Function

Subject: RE: NOTES C API encoding language problem

well, you do not specify which branch you do execute. And you do not show the declarations. I assume you run it on Win32 as your post specifies XP. The rest of the code is quite suspicious – it looks like a borrowed sample that never has worked.

Oh well – I understand – you showed your plain LS code not your declarations that are the ones that matter. So as I said - I’d bet that your declarations are wrong - you should use “Byval forms As Lmbcs String”; also “Unix” is a no go, meaning that different Unix platforms need different declarations and finally the OS/400 branch/declaration do not have a chance to work (well I don’t know – may be you use a wrapper library to call C API on OS/400)

If your branch for OS/390 is real, i.e. you have a goal to make it running on OS/390, could you drop me a line to the email in my profile? I’d be interested in your experiences and could help if necessary.

If you are serious about making your code work (meaning more than this one call); and making it work on more than one platform you may want to check out my book: http://www.ls2capi.com

Subject: NOTES C API encoding language problem

Hi,

I am facing a similar problem when I try to use NifFindDesignNote API to find french calendar entry form.

I am trying to insert some design elements in the calendar entry form which is named as “_Entrée d’agenda” in French 7.X and 8.X install.

However, we found that the following API is failing and returning "Entry not found in index " for the same. Below is the code snippet

NIFFindDesignNote(hMailFile, "_Entree d’agenda ", NOTE_CLASS_FORM,

&FormNoteID)

It would be great if you could provide us some pointers to resolve the above issue?

Thanks,

Shweta