Windows resource files do not understand the concatenation of C-style literal strings for most elements. The only exception may be the row table.
The trick when working with preprocessor macros is to not use strings as the starting point of input, the preprocessor does not know how to remove quotes.
It would be useful to concatenate only once - consider adding search paths "-I../icons/" instead of adding paths to resource names.
Called the following from boost, for example, using Windows msvc, which uses an additional level of indirection than what I saw in most places.
# define BOOST_PP_CAT(a, b) BOOST_PP_CAT_OO((a, b)) # define BOOST_PP_CAT_OO(par) BOOST_PP_CAT_I ## par # define BOOST_PP_CAT_I(a, b) a ## b # define BOOST_PP_STRINGIZE(text) BOOST_PP_STRINGIZE_A((text)) # define BOOST_PP_STRINGIZE_A(arg) BOOST_PP_STRINGIZE_I arg # define BOOST_PP_STRINGIZE_I(text) #text
In the examples, you can simply do BOOST_PP_CAT(../icons/, BOOST_PP_CAT(num,.ico))
There is a problem with the string only the external CAT is applied (at least in windows). So BOOST_PP_STRINGIZE(BOOST_PP_CAT(../icons/, BOOST_PP_CAT(num,.ico))) does not work.
3 Concatenation Supplement
In my testing VS2013 input
.. converted to "..." , which makes working with a relative path difficult\ must be escaped \\ to work in args macros, but converted to "\\" - using / for the path works better
Working with a row table may be easier to see the output than working with icons
STRINGTABLE BEGIN 123 BOOST_PP_STRINGIZE(BOOST_PP_CAT(APP_NUMBER, .ico)) 124 BOOST_PP_STRINGIZE(BOOST_PP_CAT2(../icons/, APP_NUMBER,.ico))) END
I have not yet developed permission ... to convert to ... I had the following work using an additional search path,
1000 ICON BOOST_PP_STRINGIZE(BOOST_PP_CAT(APP_NUMBER, .ico)) 1001 ICON BOOST_PP_STRINGIZE(BOOST_PP_CAT2(icons/, APP_NUMBER, .ico))