Click here to Skip to main content
15,890,690 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: HELP !!! Radio button font size change Pin
Anurag Gandhi17-Feb-09 23:02
professionalAnurag Gandhi17-Feb-09 23:02 
QuestionHow Store video and picture file using sql2000 with a unique user Pin
ali2k617-Feb-09 20:33
ali2k617-Feb-09 20:33 
Questionhow to filter distinct row from DataView Pin
krishnaveer17-Feb-09 20:32
krishnaveer17-Feb-09 20:32 
AnswerRe: how to filter distinct row from DataView Pin
Abhishek Sur17-Feb-09 20:42
professionalAbhishek Sur17-Feb-09 20:42 
AnswerRe: how to filter distinct row from DataView Pin
Satish Mahapatra17-Feb-09 20:42
Satish Mahapatra17-Feb-09 20:42 
GeneralRe: how to filter distinct row from DataView Pin
krishnaveer17-Feb-09 20:47
krishnaveer17-Feb-09 20:47 
AnswerRe: how to filter distinct row from DataView Pin
N a v a n e e t h17-Feb-09 21:53
N a v a n e e t h17-Feb-09 21:53 
QuestionThe Application relative Virtual path '~' is not allowed here Pin
Vimalsoft(Pty) Ltd17-Feb-09 20:15
professionalVimalsoft(Pty) Ltd17-Feb-09 20:15 
Good Morning All

Am working on a Setup Project. I have an Installer that write on the Web.config file like this

public override void Install(System.Collections.IDictionary stateSaver)
        {
            base.Install(stateSaver);

            String MyServer = Context.Parameters["MyServer"];
                        
            String server = "Username=sa;Password=wow;Database=OBooking_Master;Server=" + MyServer;

            String Key = "TESTY";

            UpdateConfig(Key, server);


        }


        public void UpdateConfig(string strKey, string strValue)
        {

            Configuration objConfig = WebConfigurationManager.OpenWebConfiguration("~");

            AppSettingsSection objAppsettings = (AppSettingsSection)objConfig.GetSection("appSettings");

            if (objAppsettings != null)
            {

                objAppsettings.Settings[strKey].Value = strValue;

                objConfig.Save();

            }
        }



Cool , now after i compile everything, testing my setup, i get an Error that says

The Application relative Virtual path '~' is not allowed here 


i have tried the Following

Configuration objConfig = WebConfigurationManager.OpenWebConfiguration(HttpRuntime.AppDomainAppVirtualPath);



An i got an Error

Object reference not set to an instance of an object 


And when i do it like this

Configuration objConfig = WebConfigurationManager.OpenWebConfiguration(@"~\Install_Helloworld\Web.Config");


and i got the Error Below on the Picture below.

In the CustomActionData Property i have this

/MyServer="[EDITA1]\"



Does it look ok for you?

Thanks

Vuyiswa Maseko,

Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."

C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
www.ITS.co.za

QuestionCalendar? Pin
Karthick_gc17-Feb-09 20:14
Karthick_gc17-Feb-09 20:14 
Questionopening excel document Pin
vedharadha17-Feb-09 20:12
vedharadha17-Feb-09 20:12 
AnswerRe: opening excel document Pin
Abhishek Sur17-Feb-09 20:35
professionalAbhishek Sur17-Feb-09 20:35 
GeneralRe: opening excel document Pin
vedharadha17-Feb-09 21:44
vedharadha17-Feb-09 21:44 
GeneralRe: opening excel document Pin
keyur satyadev18-Feb-09 0:23
keyur satyadev18-Feb-09 0:23 
QuestionButton on AJAXModalPopup not firing the event Pin
anada888617-Feb-09 19:48
anada888617-Feb-09 19:48 
QuestionForms Authentication Pin
Robymon17-Feb-09 18:48
Robymon17-Feb-09 18:48 
AnswerRe: Forms Authentication Pin
anujbanka178417-Feb-09 19:32
anujbanka178417-Feb-09 19:32 
GeneralRe: Forms Authentication Pin
Robymon17-Feb-09 19:45
Robymon17-Feb-09 19:45 
QuestionConfigure IIS7 in Vista to Run .aspx files Pin
Abdul Rahman Hamidy17-Feb-09 18:27
Abdul Rahman Hamidy17-Feb-09 18:27 
AnswerRe: Configure IIS7 in Vista to Run .aspx files Pin
Satish Mahapatra17-Feb-09 18:51
Satish Mahapatra17-Feb-09 18:51 
AnswerRe: Configure IIS7 in Vista to Run .aspx files Pin
Abhijit Jana18-Feb-09 4:22
professionalAbhijit Jana18-Feb-09 4:22 
QuestionCrystal Reports 9 error in ASP.NET Pin
NewbieDave17-Feb-09 11:26
NewbieDave17-Feb-09 11:26 
QuestionURL Path... Pin
Member 47085017-Feb-09 10:45
Member 47085017-Feb-09 10:45 
AnswerRe: URL Path... Pin
vaghelabhavesh17-Feb-09 10:58
vaghelabhavesh17-Feb-09 10:58 
QuestionDataGrid to DataBase Pin
Terick17-Feb-09 8:49
Terick17-Feb-09 8:49 
AnswerRe: DataGrid to DataBase Pin
N a v a n e e t h17-Feb-09 14:48
N a v a n e e t h17-Feb-09 14:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.