In general, PlotY is used when you want to specify custom y data vs. continuous and increasing x data and PlotXvsY is used when you want to specify custom y data vs. custom x data. As long as your x data can be specified by a starting value and a constant increment, PlotY should do the right thing and would be easier. Otherwise, you should use PlotXvsY. To make PlotXvsY work in your case, make both parameters CNiReal64Vector (or another Measurement Studio vector type if that's more appropriate) and it should work.
Regarding converting CNiString/CString into a character array, CString (and hence CNiString) defines an operator LPCTSTR member which will return a character pointer that lets you directly access the characters stored in the object as a C-style st
ring, so the answer is casting. If you need a non-constant pointer, use the GetBuffer method (don't forget to call ReleaseBuffer after you're finished making modifications to the string - see the docs for more info).
- Elton