Hi all, I coul use a little help. I'm trying to transfer a GUI application I wrote from linux to windows. It all seems ok except that I can't get the MainFrame class instantiated because I get a null pointer from the global gClient pointer. I'm running on windows w/ MSVS6.0 and lot's of service packs. I've listed the skeleton of the program below. Any help would be greatly appreciated. Thanks! Mike // JetDisplay.cpp : Defines the entry point for the console application.// #include "stdafx.h" #include <iostream.h> #include "TCanvas.h" #include "TApplication.h" #include "TLine.h" #include "TPaveLabel.h" //local //#include "MainFrame.h" int main(int argc, char* argv[]) { cout <<"Hello World!"<<endl; TApplication* theApp = new TApplication("App", &argc, argv); cout <<"get client"<<endl; TGClient* client = gClient; //this gives me a null pointer?! cout <<"get window"<<endl; const TGWindow* window = client->GetRoot(); //this crashes, of course cout <<"Call theApp->Run()"<<endl; theApp->Run(); return 1; } Michael L. Miller (Yale Physics) michael.miller@yale.edu Seattle: 206.543.2908 EPE group, 2nd floor physics. BNL: 631.344.8342 Building 118 Yale Software Yale: 203.432.6615 Room 301 WNSL
This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:50:59 MET