See
Data structures - C++ Tutorials[
^] about structure type names and object names.
In you case
WorkerThreadStr
is the type and
workerthreadstr
is an object (here a member of
WorkerThreadClass
).
So you have to use the object name if you want to assign a value from a class function:
void WorkerThreadClass::SomeFunc()
{
workerthreadstr.SyncTimeMilliSec=14989897.1005;
}
When using the type outside the class you must declare a variable of the type:
WorkerThreadClass::WorkerThreadStr workerthreadstrVal;
workerthreadstrVal.SyncTimeMilliSec=14989897.1005;
[EDIT]
If you have an instance of your class, access the member via that:
WorkerThreadClass threadClass;
threadClass.workerthreadstr.SyncTimeMilliSec=14989897.1005;
std::cout << threadClass.workerthreadstr.SyncTimeMilliSec << "\n";
[/EDIT]