Hi--
Others have already given you good solutions, but I thought you might like to
see another one. (Same principle as others; different packaging)
I wrote LstCh() which returns a pointer to the last (rightmost) character in a
given string. I then wrote macro FNAM which uses LstCh()
On Jan 29, 2008 10:46 PM, Luc Le Blanc [EMAIL PROTECTED] wrote:
On Jan 29, 2008 6:00 PM, Luc Le Blanc [EMAIL PROTECTED] wrote:
Is there an API to extract the VFS filename from a fully
qualified name that includes the path?
filename = StrRChr(path, '/');
if (filename != NULL)
FYI: here are my routines; (try to re-use what i can) :P
// look for a specific character in the memory buffer, starting at end
char *
_MemRChr(void *p, char chr, uint32 count)
{
char *pos;
char *x;
int i;
// default return value
pos = NULL;
// pre-condition (cannot have
Is there an API to extract the VFS filename from a fully qualified name that
includes the path?
Luc Le Blanc
--
For information on using the ACCESS Developer Forums, or to unsubscribe, please
see http://www.access-company.com/developers/forums/
On Jan 29, 2008 6:00 PM, Luc Le Blanc [EMAIL PROTECTED] wrote:
Is there an API to extract the VFS filename from a fully qualified name that
includes the path?
filename = StrRChr(path, '/');
if (filename != NULL) filename++;
basic string routines? not sure if thats what your looking for; but
Aaron Ardiri wrote:
On Jan 29, 2008 6:00 PM, Luc Le Blanc [EMAIL PROTECTED] wrote:
Is there an API to extract the VFS filename from a fully
qualified name that includes the path?
filename = StrRChr(path, '/');
if (filename != NULL) filename++;
basic string routines? not sure if thats
Luc Le Blanc wrote:
BTW, StrRchr doesn't exist. I have to write it too ;)
should be StrChr, such exists
--
For information on using the ACCESS Developer Forums, or to unsubscribe, please
see http://www.access-company.com/developers/forums/
Michal Seliga wrote:
Luc Le Blanc wrote:
BTW, StrRchr doesn't exist. I have to write it too ;)
should be StrChr, such exists
No because you have to find the last / in the pathname, so you need to start
from the end, hence StrRChr. Here's my (yet) untested code:
Char *StrRChr( Char
[Charset UTF-8 unsupported, filtering to ASCII...]
Luc Le Blanc wrote:
BTW, StrRchr doesn't exist. I have to write it too ;)
should be StrChr, such exists
It should *not* be StrChr; Aaron's initial suggestion was to do
StrRChr(path, '/')
to get the last '/' character. Using StrChr would
Dean Gahlon wrote:
[Charset UTF-8 unsupported, filtering to ASCII...]
Luc Le Blanc wrote:
BTW, StrRchr doesn't exist. I have to write it too ;)
should be StrChr, such exists
It should *not* be StrChr; Aaron's initial suggestion was to do
StrRChr(path, '/')
to get the last '/' character.
10 matches
Mail list logo